webmoney 0.0.15.pre → 0.0.15

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: e9b21228168a0b9e8b5c734195c90e2e3ddcd7f1
4
+ data.tar.gz: bf338aca8108418a0664f8d5b58f73571e9d2d29
5
+ SHA512:
6
+ metadata.gz: 573b298a5663b6d1960bfe9afcca76274405ce2ea287599fec7fb87713194452be8623a2ba979e3d9910728008103b3d6b8cf162388dc27a7c852794e91dab5c
7
+ data.tar.gz: f226cc062ba9500b4213e4f9229d638585dba6a18b6bf1789c1fc19d87bcf757cd742e8d20b5c70a53091de07b71d659e608e0250f492595394cefaa4d8b576a
data/ChangeLog CHANGED
@@ -1,5 +1,14 @@
1
1
  ChangeLog
2
2
 
3
+ Tue Mar 17 18:00:00 2015 +0300
4
+ ----------------------------
5
+ V 0.0.15
6
+ * Added X purse type
7
+ * Fixed url for X19 on X.509 certs
8
+ * Backward compatibility to ruby 1.8, thanks to
9
+ * Avoid excess validation on encoded key length, thanks to
10
+ Phuong Nguyen <phuongnd08@gmail.com>
11
+
3
12
  Thu Nov 22 13:07:47 2012 +0400
4
13
  ----------------------------
5
14
  V 0.0.15.pre
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.15.pre
1
+ 0.0.15
@@ -25,7 +25,7 @@ module Webmoney
25
25
  :get_contract_info => { :url => 'https://arbitrage.webmoney.ru/xml/X17_GetContractInfo.aspx' }, # x17
26
26
  :transaction_get => { :url => 'https://merchant.webmoney.ru/conf/xml/XMLTransGet.asp' }, # x18
27
27
  :check_user => { :url => 'https://apipassport.webmoney.ru/XMLCheckUser.aspx', # x19
28
- :x509 => lambda {|url| url.sub(/\.aspx$/, 'Cert.aspx')} },
28
+ :x509 => lambda {|url| 'https://apipassportcrt.webmoney.ru/XMLCheckUserCert.aspx' } },
29
29
  :bussines_level => { :url => 'https://stats.wmtransfer.com/levels/XMLWMIDLevel.aspx' },
30
30
  :login => { :url => 'https://login.wmtransfer.com/ws/authorize.xiface' }, # login
31
31
  }
@@ -7,7 +7,7 @@ module Webmoney
7
7
 
8
8
  def initialize(str)
9
9
  str = str.to_s unless str.kind_of?(String)
10
- raise IncorrectPurseError, str unless str =~ /^[BCDEGRUYZ]\d{12}$/
10
+ raise IncorrectPurseError, str unless str =~ /^[BCDEGRUYXZ]\d{12}$/
11
11
  super(str)
12
12
  end
13
13
 
@@ -40,7 +40,7 @@ class Signer
40
40
  e = read_bn_from data_io
41
41
  n = read_bn_from data_io
42
42
 
43
- { e: e, n: n }
43
+ { :e => e, :n => n }
44
44
  end
45
45
 
46
46
  def self.try_read_encrypted(wmid, password, header, data)
@@ -84,10 +84,8 @@ class Signer
84
84
  raise ArgumentError, "Incorrect WMID" unless is_wmid wmid
85
85
  raise ArgumentError, "nil password" if password.nil?
86
86
  raise ArgumentError, "nil key" if key.nil?
87
- raise ArgumentError, "Illegal size for base64 keydata" unless key.length == 220
88
87
 
89
88
  key = Base64.decode64 key
90
-
91
89
  raise ArgumentError, "Illegal size for keydata" if key.length != 164
92
90
 
93
91
  io = StringIO.open key.force_encoding('BINARY'), 'rb'
metadata CHANGED
@@ -1,94 +1,83 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: webmoney
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.15.pre
5
- prerelease: 7
4
+ version: 0.0.15
6
5
  platform: ruby
7
6
  authors:
8
7
  - Alexander Oryol
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2012-11-22 00:00:00.000000000 Z
11
+ date: 2015-03-17 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: nokogiri
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
- - - ! '>='
17
+ - - ">="
20
18
  - !ruby/object:Gem::Version
21
19
  version: '0'
22
20
  type: :runtime
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
- - - ! '>='
24
+ - - ">="
28
25
  - !ruby/object:Gem::Version
29
26
  version: '0'
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: rspec
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
- - - ! '>='
31
+ - - ">="
36
32
  - !ruby/object:Gem::Version
37
33
  version: '0'
38
34
  type: :development
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
- - - ! '>='
38
+ - - ">="
44
39
  - !ruby/object:Gem::Version
45
40
  version: '0'
46
41
  - !ruby/object:Gem::Dependency
47
42
  name: bundler
48
43
  requirement: !ruby/object:Gem::Requirement
49
- none: false
50
44
  requirements:
51
- - - ! '>='
45
+ - - ">="
52
46
  - !ruby/object:Gem::Version
53
47
  version: '0'
54
48
  type: :development
55
49
  prerelease: false
56
50
  version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
51
  requirements:
59
- - - ! '>='
52
+ - - ">="
60
53
  - !ruby/object:Gem::Version
61
54
  version: '0'
62
55
  - !ruby/object:Gem::Dependency
63
56
  name: jeweler
64
57
  requirement: !ruby/object:Gem::Requirement
65
- none: false
66
58
  requirements:
67
- - - ! '>='
59
+ - - ">="
68
60
  - !ruby/object:Gem::Version
69
61
  version: '0'
70
62
  type: :development
71
63
  prerelease: false
72
64
  version_requirements: !ruby/object:Gem::Requirement
73
- none: false
74
65
  requirements:
75
- - - ! '>='
66
+ - - ">="
76
67
  - !ruby/object:Gem::Version
77
68
  version: '0'
78
69
  - !ruby/object:Gem::Dependency
79
70
  name: rake-compiler
80
71
  requirement: !ruby/object:Gem::Requirement
81
- none: false
82
72
  requirements:
83
- - - ! '>='
73
+ - - ">="
84
74
  - !ruby/object:Gem::Version
85
75
  version: '0'
86
76
  type: :development
87
77
  prerelease: false
88
78
  version_requirements: !ruby/object:Gem::Requirement
89
- none: false
90
79
  requirements:
91
- - - ! '>='
80
+ - - ">="
92
81
  - !ruby/object:Gem::Version
93
82
  version: '0'
94
83
  description:
@@ -136,45 +125,41 @@ files:
136
125
  - webmoney.gemspec
137
126
  homepage:
138
127
  licenses: []
128
+ metadata: {}
139
129
  post_install_message:
140
130
  rdoc_options: []
141
131
  require_paths:
142
132
  - lib
143
133
  required_ruby_version: !ruby/object:Gem::Requirement
144
- none: false
145
134
  requirements:
146
- - - ! '>='
135
+ - - ">="
147
136
  - !ruby/object:Gem::Version
148
137
  version: '0'
149
- segments:
150
- - 0
151
- hash: 3598956069163173329
152
138
  required_rubygems_version: !ruby/object:Gem::Requirement
153
- none: false
154
139
  requirements:
155
- - - ! '>'
140
+ - - ">="
156
141
  - !ruby/object:Gem::Version
157
- version: 1.3.1
142
+ version: '0'
158
143
  requirements: []
159
144
  rubyforge_project: webmoney
160
- rubygems_version: 1.8.24
145
+ rubygems_version: 2.2.2
161
146
  signing_key:
162
- specification_version: 3
147
+ specification_version: 4
163
148
  summary: Webmoney interfaces and native wmsigner
164
149
  test_files:
165
150
  - Gemfile
166
151
  - spec/spec_helper.rb
167
152
  - spec/benchmark.rb
168
- - spec/unit/balance_spec.rb
169
- - spec/unit/purse_spec.rb
170
- - spec/unit/time_spec.rb
171
- - spec/unit/check_user.rb
172
153
  - spec/unit/interfaces_spec.rb
173
- - spec/unit/messenger_spec.rb
174
- - spec/unit/signer_spec.rb
154
+ - spec/unit/login_spec.rb
155
+ - spec/unit/wmid_spec.rb
175
156
  - spec/unit/passport_spec.rb
176
157
  - spec/unit/trust_spec.rb
177
- - spec/unit/wmid_spec.rb
178
- - spec/unit/login_spec.rb
179
- - spec/unit/webmoney_spec.rb
180
158
  - spec/unit/iconv_spec.rb
159
+ - spec/unit/check_user.rb
160
+ - spec/unit/time_spec.rb
161
+ - spec/unit/signer_spec.rb
162
+ - spec/unit/webmoney_spec.rb
163
+ - spec/unit/purse_spec.rb
164
+ - spec/unit/balance_spec.rb
165
+ - spec/unit/messenger_spec.rb