net-ssh 7.1.0.beta1 → 7.1.0.beta2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b8455b47f7ee1f86fdf471c0698d72400df29cf22f9dd91ee99b6d00c12220b0
4
- data.tar.gz: a735ad5416dab3d5b7517ceef2915c78a144a555140eede2c1a41187cd3038cb
3
+ metadata.gz: e4dc08515948324af346caddea61529c95353644dc99e709719f5e320775b7fc
4
+ data.tar.gz: 81dcce4739c85398d13a2f272bf49083cb3790d9b7e9faa3501f2cff792e2a8c
5
5
  SHA512:
6
- metadata.gz: 8fb0bb0ecb59dd39d87b4c08f40d5e87670e8a0888c817a947c86675f6542ebf8b15fa221b01f642457b1f75eb1c97526fb0022ee04dba204e630af80a0f3ce5
7
- data.tar.gz: 88996fe27056be54e5425a27caa973a5b487f7f9ff82b1cb77e02b5270141c076819545ffe9a127bb97abe0b4fd0d4a1f13ac2c27d0b8a2cc042c687e85b437e
6
+ metadata.gz: fbb1176178c014d7f8477d7c498151ce06d8858413bb5d145543e7be1a11fd8a37ff713e3bf3f4287f5999ccc29e92934d1da26c573dd8d0ef1c667633d5a696
7
+ data.tar.gz: e718b4989312a5d1c12c93ebcde7925a5e8609c8ac790f3dd23c2210d4d9ab40adefa73c6ba63c3d861e662827e7bf6df87d40a37c5edc326000e541bd273163
checksums.yaml.gz.sig CHANGED
Binary file
data/CHANGES.txt CHANGED
@@ -1,3 +1,23 @@
1
+
2
+ === 7.1.0 beta1
3
+
4
+ * Don't use the deprecated set_XXX methods on RSA keys. [#875]
5
+ * Raise error when BCryptPbkdf fails [#876]
6
+
7
+ === 7.0.1
8
+
9
+ * Drop leftover debug statement [#866]
10
+
11
+ === 7.0.0
12
+
13
+ * BREAKING: Drop support for Ruby 2.5
14
+ * Fix decoding of ecdsa-sha2-nistp256 private keys [#657, #854]
15
+ * Fix missing require [#855]
16
+ * Support `~` in the path to the SSH agent's unix socket [#850]
17
+ * Add support for RSA client authentication with SHA-2 [a45f54]
18
+ * openssl: DSA: don't hardcode expected signature size, see ruby/openssl#483 [23a15c]
19
+ * Internal housekeeping (rubocop, codecov, remove travis, adding/improving tests)
20
+
1
21
  === 6.3.0 beta1
2
22
 
3
23
  * Support cert based host key auth, fix asterisk in known_hosts [#833]
data/README.md CHANGED
@@ -5,7 +5,7 @@
5
5
  [![Backers on Open Collective](https://opencollective.com/net-ssh/backers/badge.svg)](#backers])
6
6
  [![Sponsors on Open Collective](https://opencollective.com/net-ssh/sponsors/badge.svg)](#sponsors)
7
7
 
8
- # Net::SSH 6.x
8
+ # Net::SSH 7.x
9
9
 
10
10
  * Docs: http://net-ssh.github.io/net-ssh
11
11
  * Issues: https://github.com/net-ssh/net-ssh/issues
@@ -247,6 +247,10 @@ mv gem-public_cert.pem net-ssh-public_cert.pem
247
247
  gem cert --add net-ssh-public_cert.pem
248
248
  ```
249
249
 
250
+ ## Security contact information
251
+
252
+ See [SECURITY.md](SECURITY.md)
253
+
250
254
  ## CREDITS
251
255
 
252
256
  ### Contributors
data/Rakefile CHANGED
@@ -55,6 +55,37 @@ namespace :cert do
55
55
  end
56
56
  end
57
57
 
58
+ namespace :vbump do
59
+ desc "Increment prerelease"
60
+ task :pre do
61
+ version_file = 'lib/net/ssh/version.rb'
62
+ require_relative version_file
63
+ pre = Net::SSH::Version::PRE
64
+ if pre =~ /^([a-z]+)(\d+)/
65
+ new_pre = "#{$1}#{$2.to_i+1}"
66
+ found = false
67
+
68
+ File.open("#{version_file}.new", "w") do |f|
69
+ File.readlines(version_file).each do |line|
70
+ if line =~ /^(\s+PRE\s+=\s+")#{pre}("\s*)$/
71
+ new_line = "#{$1}#{new_pre}#{$2}"
72
+ puts "Changing:\n - #{line} + #{new_line}"
73
+ line = new_line
74
+ found = true
75
+ end
76
+ f.write(line)
77
+ end
78
+ raise ArugmentError, 'Cound not find line: PRE = \"#{pre}\" in #{version_file}"' unless found
79
+ end
80
+
81
+ FileUtils.mv version_file, "#{version_file}.old"
82
+ FileUtils.mv "#{version_file}.new", version_file
83
+ else
84
+ raise ArgumentError, "Unepexeted pre string: #{pre}"
85
+ end
86
+ end
87
+ end
88
+
58
89
  namespace :rdoc do
59
90
  desc "Update gh-pages branch"
60
91
  task :publish do
data/SECURITY.md ADDED
@@ -0,0 +1,4 @@
1
+ ## Security contact information
2
+
3
+ To report a security vulnerability, please use the
4
+ [GitHub private vulnerability reporting feature](https://docs.github.com/en/code-security/security-advisories/guidance-on-reporting-and-writing/privately-reporting-a-security-vulnerability).
@@ -77,6 +77,7 @@ module Net
77
77
  raise "BCryptPbkdf is not implemented for jruby" if RUBY_PLATFORM == "java"
78
78
 
79
79
  key = BCryptPbkdf::key(password, salt, keylen + ivlen, rounds)
80
+ raise DecryptError.new("BCyryptPbkdf failed", encrypted_key: true) unless key
80
81
  else
81
82
  key = '\x00' * (keylen + ivlen)
82
83
  end
@@ -251,7 +251,6 @@ module Net
251
251
  def read_private_keyblob(type)
252
252
  case type
253
253
  when /^ssh-rsa$/
254
- key = OpenSSL::PKey::RSA.new
255
254
  n = read_bignum
256
255
  e = read_bignum
257
256
  d = read_bignum
@@ -262,27 +261,28 @@ module Net
262
261
  _unkown2 = read_bignum
263
262
  dmp1 = d % (p - 1)
264
263
  dmq1 = d % (q - 1)
265
- if key.respond_to?(:set_key)
266
- key.set_key(n, e, d)
267
- else
268
- key.e = e
269
- key.n = n
270
- key.d = d
271
- end
272
- if key.respond_to?(:set_factors)
273
- key.set_factors(p, q)
274
- else
275
- key.p = p
276
- key.q = q
264
+ # Public key
265
+ data_sequence = OpenSSL::ASN1::Sequence([
266
+ OpenSSL::ASN1::Integer(n),
267
+ OpenSSL::ASN1::Integer(e)
268
+ ])
269
+
270
+ if d && p && q && dmp1 && dmq1 && iqmp
271
+ data_sequence = OpenSSL::ASN1::Sequence([
272
+ OpenSSL::ASN1::Integer(0),
273
+ OpenSSL::ASN1::Integer(n),
274
+ OpenSSL::ASN1::Integer(e),
275
+ OpenSSL::ASN1::Integer(d),
276
+ OpenSSL::ASN1::Integer(p),
277
+ OpenSSL::ASN1::Integer(q),
278
+ OpenSSL::ASN1::Integer(dmp1),
279
+ OpenSSL::ASN1::Integer(dmq1),
280
+ OpenSSL::ASN1::Integer(iqmp)
281
+ ])
277
282
  end
278
- if key.respond_to?(:set_crt_params)
279
- key.set_crt_params(dmp1, dmq1, iqmp)
280
- else
281
- key.dmp1 = dmp1
282
- key.dmq1 = dmq1
283
- key.iqmp = iqmp
284
- end
285
- key
283
+
284
+ asn1 = OpenSSL::ASN1::Sequence(data_sequence)
285
+ OpenSSL::PKey::RSA.new(asn1.to_der)
286
286
  when /^ecdsa\-sha2\-(\w*)$/
287
287
  OpenSSL::PKey::EC.read_keyblob($1, self)
288
288
  else
@@ -56,7 +56,7 @@ module Net
56
56
 
57
57
  # The prerelease component of this version of the Net::SSH library
58
58
  # nil allowed
59
- PRE = "beta1"
59
+ PRE = "beta2"
60
60
 
61
61
  # The current version of the Net::SSH library as a Version instance
62
62
  CURRENT = new(*[MAJOR, MINOR, TINY, PRE].compact)
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: net-ssh
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.1.0.beta1
4
+ version: 7.1.0.beta2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jamis Buck
@@ -31,7 +31,7 @@ cert_chain:
31
31
  v84waVXQ2i5M7pJaHVBF7DxxeW/q8W3VCnsq8vmmvULSThD18QqYGaFDJeN8sTR4
32
32
  6tfjgZ6OvGSScvbCMHkCE9XjonE=
33
33
  -----END CERTIFICATE-----
34
- date: 2023-01-24 00:00:00.000000000 Z
34
+ date: 2023-02-27 00:00:00.000000000 Z
35
35
  dependencies:
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: bcrypt_pbkdf
@@ -174,6 +174,7 @@ files:
174
174
  - Manifest
175
175
  - README.md
176
176
  - Rakefile
177
+ - SECURITY.md
177
178
  - THANKS.txt
178
179
  - appveyor.yml
179
180
  - docker-compose.yml
@@ -291,7 +292,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
291
292
  - !ruby/object:Gem::Version
292
293
  version: 1.3.1
293
294
  requirements: []
294
- rubygems_version: 3.1.6
295
+ rubygems_version: 3.3.3
295
296
  signing_key:
296
297
  specification_version: 4
297
298
  summary: 'Net::SSH: a pure-Ruby implementation of the SSH2 client protocol.'
metadata.gz.sig CHANGED
Binary file