net-ssh 5.0.2 → 6.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (76) hide show
  1. checksums.yaml +4 -4
  2. checksums.yaml.gz.sig +0 -0
  3. data.tar.gz.sig +0 -0
  4. data/.gitignore +1 -0
  5. data/.rubocop.yml +8 -2
  6. data/.rubocop_todo.yml +392 -379
  7. data/.travis.yml +22 -22
  8. data/CHANGES.txt +63 -0
  9. data/Manifest +0 -1
  10. data/README.md +287 -0
  11. data/Rakefile +1 -2
  12. data/appveyor.yml +4 -2
  13. data/lib/net/ssh.rb +13 -4
  14. data/lib/net/ssh/authentication/agent.rb +9 -3
  15. data/lib/net/ssh/authentication/certificate.rb +10 -1
  16. data/lib/net/ssh/authentication/ed25519.rb +75 -46
  17. data/lib/net/ssh/authentication/ed25519_loader.rb +1 -1
  18. data/lib/net/ssh/authentication/key_manager.rb +35 -6
  19. data/lib/net/ssh/authentication/methods/keyboard_interactive.rb +3 -1
  20. data/lib/net/ssh/authentication/methods/publickey.rb +2 -0
  21. data/lib/net/ssh/authentication/pub_key_fingerprint.rb +0 -1
  22. data/lib/net/ssh/authentication/session.rb +9 -6
  23. data/lib/net/ssh/buffer.rb +41 -10
  24. data/lib/net/ssh/buffered_io.rb +0 -1
  25. data/lib/net/ssh/config.rb +68 -35
  26. data/lib/net/ssh/connection/channel.rb +17 -5
  27. data/lib/net/ssh/connection/event_loop.rb +0 -1
  28. data/lib/net/ssh/connection/session.rb +7 -4
  29. data/lib/net/ssh/key_factory.rb +104 -17
  30. data/lib/net/ssh/known_hosts.rb +41 -26
  31. data/lib/net/ssh/loggable.rb +2 -2
  32. data/lib/net/ssh/proxy/command.rb +0 -1
  33. data/lib/net/ssh/proxy/socks5.rb +0 -1
  34. data/lib/net/ssh/service/forward.rb +2 -1
  35. data/lib/net/ssh/test.rb +8 -7
  36. data/lib/net/ssh/test/extensions.rb +2 -0
  37. data/lib/net/ssh/transport/algorithms.rb +161 -105
  38. data/lib/net/ssh/transport/cipher_factory.rb +11 -27
  39. data/lib/net/ssh/transport/constants.rb +10 -6
  40. data/lib/net/ssh/transport/ctr.rb +1 -7
  41. data/lib/net/ssh/transport/hmac.rb +15 -13
  42. data/lib/net/ssh/transport/hmac/abstract.rb +16 -0
  43. data/lib/net/ssh/transport/hmac/sha2_256.rb +7 -11
  44. data/lib/net/ssh/transport/hmac/sha2_256_96.rb +4 -8
  45. data/lib/net/ssh/transport/hmac/sha2_256_etm.rb +12 -0
  46. data/lib/net/ssh/transport/hmac/sha2_512.rb +6 -9
  47. data/lib/net/ssh/transport/hmac/sha2_512_96.rb +4 -8
  48. data/lib/net/ssh/transport/hmac/sha2_512_etm.rb +12 -0
  49. data/lib/net/ssh/transport/kex.rb +14 -11
  50. data/lib/net/ssh/transport/kex/abstract.rb +123 -0
  51. data/lib/net/ssh/transport/kex/abstract5656.rb +72 -0
  52. data/lib/net/ssh/transport/kex/curve25519_sha256.rb +38 -0
  53. data/lib/net/ssh/transport/kex/curve25519_sha256_loader.rb +30 -0
  54. data/lib/net/ssh/transport/kex/diffie_hellman_group14_sha1.rb +1 -15
  55. data/lib/net/ssh/transport/kex/diffie_hellman_group1_sha1.rb +9 -118
  56. data/lib/net/ssh/transport/kex/diffie_hellman_group_exchange_sha1.rb +0 -6
  57. data/lib/net/ssh/transport/kex/diffie_hellman_group_exchange_sha256.rb +5 -9
  58. data/lib/net/ssh/transport/kex/ecdh_sha2_nistp256.rb +18 -79
  59. data/lib/net/ssh/transport/kex/ecdh_sha2_nistp384.rb +5 -4
  60. data/lib/net/ssh/transport/kex/ecdh_sha2_nistp521.rb +5 -4
  61. data/lib/net/ssh/transport/openssl.rb +106 -93
  62. data/lib/net/ssh/transport/packet_stream.rb +52 -20
  63. data/lib/net/ssh/transport/session.rb +26 -4
  64. data/lib/net/ssh/transport/state.rb +1 -1
  65. data/lib/net/ssh/verifiers/accept_new.rb +7 -0
  66. data/lib/net/ssh/verifiers/always.rb +4 -0
  67. data/lib/net/ssh/verifiers/never.rb +4 -0
  68. data/lib/net/ssh/version.rb +3 -3
  69. data/net-ssh-public_cert.pem +18 -19
  70. data/net-ssh.gemspec +9 -7
  71. metadata +56 -40
  72. metadata.gz.sig +0 -0
  73. data/Gemfile.noed25519.lock +0 -41
  74. data/README.rdoc +0 -169
  75. data/lib/net/ssh/ruby_compat.rb +0 -13
  76. data/support/arcfour_check.rb +0 -20
@@ -141,7 +141,7 @@ module Net
141
141
 
142
142
  @max_packets ||= 1 << 31
143
143
 
144
- @block_size = cipher.name == "RC4" ? 8 : cipher.block_size
144
+ @block_size = cipher.block_size
145
145
 
146
146
  if max_blocks.nil?
147
147
  # cargo-culted from openssh. the idea is that "the 2^(blocksize*2)
@@ -21,6 +21,13 @@ module Net
21
21
  return true
22
22
  end
23
23
  end
24
+
25
+ def verify_signature(&block)
26
+ yield
27
+ rescue HostKeyUnknown => err
28
+ err.remember_host!
29
+ return true
30
+ end
24
31
  end
25
32
 
26
33
  end
@@ -34,6 +34,10 @@ module Net
34
34
  found
35
35
  end
36
36
 
37
+ def verify_signature(&block)
38
+ yield
39
+ end
40
+
37
41
  private
38
42
 
39
43
  def process_cache_miss(host_keys, args, exc_class, message)
@@ -10,6 +10,10 @@ module Net
10
10
  def verify(arguments)
11
11
  true
12
12
  end
13
+
14
+ def verify_signature(&block)
15
+ true
16
+ end
13
17
  end
14
18
 
15
19
  end
@@ -46,13 +46,13 @@ module Net
46
46
  end
47
47
 
48
48
  # The major component of this version of the Net::SSH library
49
- MAJOR = 5
49
+ MAJOR = 6
50
50
 
51
51
  # The minor component of this version of the Net::SSH library
52
- MINOR = 0
52
+ MINOR = 1
53
53
 
54
54
  # The tiny component of this version of the Net::SSH library
55
- TINY = 2
55
+ TINY = 0
56
56
 
57
57
  # The prerelease component of this version of the Net::SSH library
58
58
  # nil allowed
@@ -1,21 +1,20 @@
1
1
  -----BEGIN CERTIFICATE-----
2
- MIIDeDCCAmCgAwIBAgIBATANBgkqhkiG9w0BAQsFADBBMQ8wDQYDVQQDDAZuZXRz
3
- c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YtQwTaQyVKmnllNI3kc0f4H6i7dpPd7eUAQ3/O2I
16
+ eWjDJlzu0zwqTa+N6vzS8Y3ypDSGgb1gJKzluOv7viVUAthmuuJws7XQq/qMMaNw
17
+ 3163oCKuJvMW1w8kdUMQqvlLJkVKaxz9K64r2+a04Ok1cKloTB3OSowfAYFoRlqP
18
+ voajiJNS75Pw/2j13WnPB4Q6w7dHSb57E/VluBpVKmcQZN0dGdAkEIVty3v7kw9g
19
+ y++VpCpWM/PstIFv4ApZMf501UY=
21
20
  -----END CERTIFICATE-----
@@ -1,4 +1,3 @@
1
-
2
1
  require_relative 'lib/net/ssh/version'
3
2
 
4
3
  Gem::Specification.new do |spec|
@@ -16,11 +15,14 @@ Gem::Specification.new do |spec|
16
15
  spec.description = %q{Net::SSH: a pure-Ruby implementation of the SSH2 client protocol. It allows you to write programs that invoke and interact with processes on remote servers, via SSH2.}
17
16
  spec.homepage = "https://github.com/net-ssh/net-ssh"
18
17
  spec.license = "MIT"
19
- spec.required_ruby_version = Gem::Requirement.new(">= 2.2.6")
18
+ spec.required_ruby_version = Gem::Requirement.new(">= 2.3")
19
+ spec.metadata = {
20
+ "changelog_uri" => "https://github.com/net-ssh/net-ssh/blob/master/CHANGES.txt"
21
+ }
20
22
 
21
23
  spec.extra_rdoc_files = [
22
24
  "LICENSE.txt",
23
- "README.rdoc"
25
+ "README.md"
24
26
  ]
25
27
 
26
28
  spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
@@ -31,12 +33,12 @@ Gem::Specification.new do |spec|
31
33
  unless ENV['NET_SSH_NO_ED25519']
32
34
  spec.add_development_dependency("bcrypt_pbkdf", "~> 1.0") unless RUBY_PLATFORM == "java"
33
35
  spec.add_development_dependency("ed25519", "~> 1.2")
36
+ spec.add_development_dependency('x25519') unless RUBY_PLATFORM == 'java'
34
37
  end
35
38
 
36
- spec.add_development_dependency "bundler", "~> 1.11"
37
-
39
+ spec.add_development_dependency "bundler", ">= 1.17"
38
40
  spec.add_development_dependency "minitest", "~> 5.10"
39
- spec.add_development_dependency "mocha", ">= 1.2.1"
41
+ spec.add_development_dependency "mocha", "~> 1.11.2"
40
42
  spec.add_development_dependency "rake", "~> 12.0"
41
- spec.add_development_dependency "rubocop", "~> 0.54.0"
43
+ spec.add_development_dependency "rubocop", "~> 0.74.0"
42
44
  end
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: 5.0.2
4
+ version: 6.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jamis Buck
@@ -12,27 +12,26 @@ bindir: exe
12
12
  cert_chain:
13
13
  - |
14
14
  -----BEGIN CERTIFICATE-----
15
- MIIDeDCCAmCgAwIBAgIBATANBgkqhkiG9w0BAQsFADBBMQ8wDQYDVQQDDAZuZXRz
16
- c2gxGTAXBgoJkiaJk/IsZAEZFglzb2x1dGlvdXMxEzARBgoJkiaJk/IsZAEZFgNj
17
- b20wHhcNMTgwMzExMDU0MzU1WhcNMTkwMzExMDU0MzU1WjBBMQ8wDQYDVQQDDAZu
18
- ZXRzc2gxGTAXBgoJkiaJk/IsZAEZFglzb2x1dGlvdXMxEzARBgoJkiaJk/IsZAEZ
19
- FgNjb20wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDGJ4TbZ9H+qZ08
20
- pQfJhPJTHaDCyQvCsKTFrL5O9z3tllQ7B/zksMMM+qFBpNYu9HCcg4yBATacE/PB
21
- qVVyUrpr6lbH/XwoN5ljXm+bdCfmnjZvTCL2FTE6o+bcnaF0IsJyC0Q2B1fbWdXN
22
- 6Off1ZWoUk6We2BIM1bn6QJLxBpGyYhvOPXsYoqSuzDf2SJDDsWFZ8kV5ON13Ohm
23
- JbBzn0oD8HF8FuYOewwsC0C1q4w7E5GtvHcQ5juweS7+RKsyDcVcVrLuNzoGRttS
24
- KP4yMn+TzaXijyjRg7gECfJr3TGASaA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17GKKkrsw39kiQw7FhWfJFeTjddzoZiWwc59KA/Bx
22
+ fBbmDnsMLAtAtauMOxORrbx3EOY7sHku/kSrMg3FXFay7jc6BkbbUij+MjJ/k82l
23
+ 4o8o0YO4BAnya90xgEmgOG0LCCxRhuXQFnMDuDjK2XnUe0h4/6NCn94C+z9GsQID
24
+ AQABo3sweTAJBgNVHRMEAjAAMAsGA1UdDwQEAwIEsDAdBgNVHQ4EFgQUBfKiwO2e
25
+ M4NEiRrVG793qEPLYyMwHwYDVR0RBBgwFoEUbmV0c3NoQHNvbHV0aW91cy5jb20w
26
+ HwYDVR0SBBgwFoEUbmV0c3NoQHNvbHV0aW91cy5jb20wDQYJKoZIhvcNAQELBQAD
27
+ ggEBAJTylLYXo5AybI+tLq79+OXQ8/nbGZ7iydU1uTHQud1JZQ1MRV5dRDjeBmCT
28
+ lRxaEZT4NopEzuHO0sm3nVpSYtQwTaQyVKmnllNI3kc0f4H6i7dpPd7eUAQ3/O2I
29
+ eWjDJlzu0zwqTa+N6vzS8Y3ypDSGgb1gJKzluOv7viVUAthmuuJws7XQq/qMMaNw
30
+ 3163oCKuJvMW1w8kdUMQqvlLJkVKaxz9K64r2+a04Ok1cKloTB3OSowfAYFoRlqP
31
+ voajiJNS75Pw/2j13WnPB4Q6w7dHSb57E/VluBpVKmcQZN0dGdAkEIVty3v7kw9g
32
+ y++VpCpWM/PstIFv4ApZMf501UY=
34
33
  -----END CERTIFICATE-----
35
- date: 2018-06-17 00:00:00.000000000 Z
34
+ date: 2020-06-09 00:00:00.000000000 Z
36
35
  dependencies:
37
36
  - !ruby/object:Gem::Dependency
38
37
  name: bcrypt_pbkdf
@@ -62,20 +61,34 @@ dependencies:
62
61
  - - "~>"
63
62
  - !ruby/object:Gem::Version
64
63
  version: '1.2'
64
+ - !ruby/object:Gem::Dependency
65
+ name: x25519
66
+ requirement: !ruby/object:Gem::Requirement
67
+ requirements:
68
+ - - ">="
69
+ - !ruby/object:Gem::Version
70
+ version: '0'
71
+ type: :development
72
+ prerelease: false
73
+ version_requirements: !ruby/object:Gem::Requirement
74
+ requirements:
75
+ - - ">="
76
+ - !ruby/object:Gem::Version
77
+ version: '0'
65
78
  - !ruby/object:Gem::Dependency
66
79
  name: bundler
67
80
  requirement: !ruby/object:Gem::Requirement
68
81
  requirements:
69
- - - "~>"
82
+ - - ">="
70
83
  - !ruby/object:Gem::Version
71
- version: '1.11'
84
+ version: '1.17'
72
85
  type: :development
73
86
  prerelease: false
74
87
  version_requirements: !ruby/object:Gem::Requirement
75
88
  requirements:
76
- - - "~>"
89
+ - - ">="
77
90
  - !ruby/object:Gem::Version
78
- version: '1.11'
91
+ version: '1.17'
79
92
  - !ruby/object:Gem::Dependency
80
93
  name: minitest
81
94
  requirement: !ruby/object:Gem::Requirement
@@ -94,16 +107,16 @@ dependencies:
94
107
  name: mocha
95
108
  requirement: !ruby/object:Gem::Requirement
96
109
  requirements:
97
- - - ">="
110
+ - - "~>"
98
111
  - !ruby/object:Gem::Version
99
- version: 1.2.1
112
+ version: 1.11.2
100
113
  type: :development
101
114
  prerelease: false
102
115
  version_requirements: !ruby/object:Gem::Requirement
103
116
  requirements:
104
- - - ">="
117
+ - - "~>"
105
118
  - !ruby/object:Gem::Version
106
- version: 1.2.1
119
+ version: 1.11.2
107
120
  - !ruby/object:Gem::Dependency
108
121
  name: rake
109
122
  requirement: !ruby/object:Gem::Requirement
@@ -124,14 +137,14 @@ dependencies:
124
137
  requirements:
125
138
  - - "~>"
126
139
  - !ruby/object:Gem::Version
127
- version: 0.54.0
140
+ version: 0.74.0
128
141
  type: :development
129
142
  prerelease: false
130
143
  version_requirements: !ruby/object:Gem::Requirement
131
144
  requirements:
132
145
  - - "~>"
133
146
  - !ruby/object:Gem::Version
134
- version: 0.54.0
147
+ version: 0.74.0
135
148
  description: 'Net::SSH: a pure-Ruby implementation of the SSH2 client protocol. It
136
149
  allows you to write programs that invoke and interact with processes on remote servers,
137
150
  via SSH2.'
@@ -141,7 +154,7 @@ executables: []
141
154
  extensions: []
142
155
  extra_rdoc_files:
143
156
  - LICENSE.txt
144
- - README.rdoc
157
+ - README.md
145
158
  files:
146
159
  - ".gitignore"
147
160
  - ".rubocop.yml"
@@ -150,11 +163,10 @@ files:
150
163
  - CHANGES.txt
151
164
  - Gemfile
152
165
  - Gemfile.noed25519
153
- - Gemfile.noed25519.lock
154
166
  - ISSUE_TEMPLATE.md
155
167
  - LICENSE.txt
156
168
  - Manifest
157
- - README.rdoc
169
+ - README.md
158
170
  - Rakefile
159
171
  - THANKS.txt
160
172
  - appveyor.yml
@@ -196,7 +208,6 @@ files:
196
208
  - lib/net/ssh/proxy/jump.rb
197
209
  - lib/net/ssh/proxy/socks4.rb
198
210
  - lib/net/ssh/proxy/socks5.rb
199
- - lib/net/ssh/ruby_compat.rb
200
211
  - lib/net/ssh/service/forward.rb
201
212
  - lib/net/ssh/test.rb
202
213
  - lib/net/ssh/test/channel.rb
@@ -221,10 +232,16 @@ files:
221
232
  - lib/net/ssh/transport/hmac/sha1_96.rb
222
233
  - lib/net/ssh/transport/hmac/sha2_256.rb
223
234
  - lib/net/ssh/transport/hmac/sha2_256_96.rb
235
+ - lib/net/ssh/transport/hmac/sha2_256_etm.rb
224
236
  - lib/net/ssh/transport/hmac/sha2_512.rb
225
237
  - lib/net/ssh/transport/hmac/sha2_512_96.rb
238
+ - lib/net/ssh/transport/hmac/sha2_512_etm.rb
226
239
  - lib/net/ssh/transport/identity_cipher.rb
227
240
  - lib/net/ssh/transport/kex.rb
241
+ - lib/net/ssh/transport/kex/abstract.rb
242
+ - lib/net/ssh/transport/kex/abstract5656.rb
243
+ - lib/net/ssh/transport/kex/curve25519_sha256.rb
244
+ - lib/net/ssh/transport/kex/curve25519_sha256_loader.rb
228
245
  - lib/net/ssh/transport/kex/diffie_hellman_group14_sha1.rb
229
246
  - lib/net/ssh/transport/kex/diffie_hellman_group1_sha1.rb
230
247
  - lib/net/ssh/transport/kex/diffie_hellman_group_exchange_sha1.rb
@@ -245,12 +262,12 @@ files:
245
262
  - lib/net/ssh/version.rb
246
263
  - net-ssh-public_cert.pem
247
264
  - net-ssh.gemspec
248
- - support/arcfour_check.rb
249
265
  - support/ssh_tunnel_bug.rb
250
266
  homepage: https://github.com/net-ssh/net-ssh
251
267
  licenses:
252
268
  - MIT
253
- metadata: {}
269
+ metadata:
270
+ changelog_uri: https://github.com/net-ssh/net-ssh/blob/master/CHANGES.txt
254
271
  post_install_message:
255
272
  rdoc_options: []
256
273
  require_paths:
@@ -259,15 +276,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
259
276
  requirements:
260
277
  - - ">="
261
278
  - !ruby/object:Gem::Version
262
- version: 2.2.6
279
+ version: '2.3'
263
280
  required_rubygems_version: !ruby/object:Gem::Requirement
264
281
  requirements:
265
282
  - - ">="
266
283
  - !ruby/object:Gem::Version
267
284
  version: '0'
268
285
  requirements: []
269
- rubyforge_project:
270
- rubygems_version: 2.7.6
286
+ rubygems_version: 3.0.3
271
287
  signing_key:
272
288
  specification_version: 4
273
289
  summary: 'Net::SSH: a pure-Ruby implementation of the SSH2 client protocol.'
metadata.gz.sig CHANGED
Binary file
@@ -1,41 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- net-ssh (4.2.0)
5
-
6
- GEM
7
- remote: https://rubygems.org/
8
- specs:
9
- ast (2.3.0)
10
- metaclass (0.0.4)
11
- minitest (5.10.3)
12
- mocha (1.3.0)
13
- metaclass (~> 0.0.1)
14
- parser (2.4.0.2)
15
- ast (~> 2.3)
16
- powerpack (0.1.1)
17
- rainbow (2.2.2)
18
- rake
19
- rake (12.3.0)
20
- rubocop (0.47.1)
21
- parser (>= 2.3.3.1, < 3.0)
22
- powerpack (~> 0.1)
23
- rainbow (>= 1.99.1, < 3.0)
24
- ruby-progressbar (~> 1.7)
25
- unicode-display_width (~> 1.0, >= 1.0.1)
26
- ruby-progressbar (1.9.0)
27
- unicode-display_width (1.3.0)
28
-
29
- PLATFORMS
30
- ruby
31
-
32
- DEPENDENCIES
33
- bundler (~> 1.11)
34
- minitest (~> 5.10)
35
- mocha (>= 1.2.1)
36
- net-ssh!
37
- rake (~> 12.0)
38
- rubocop (~> 0.47.0)
39
-
40
- BUNDLED WITH
41
- 1.14.6
@@ -1,169 +0,0 @@
1
- {<img src="https://badge.fury.io/rb/net-ssh.svg" alt="Gem Version" />}[https://badge.fury.io/rb/net-ssh]
2
- {<img src="https://badges.gitter.im/net-ssh/net-ssh.svg" alt="Join the chat at https://gitter.im/net-ssh/net-ssh">}[https://gitter.im/net-ssh/net-ssh?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge]
3
- {<img src="https://travis-ci.org/net-ssh/net-ssh.svg?branch=master" alt="Build Status" />}[https://travis-ci.org/net-ssh/net-ssh]
4
- {<img src="https://codecov.io/gh/net-ssh/net-ssh/branch/master/graph/badge.svg" alt="Coverage status" />}[https://codecov.io/gh/net-ssh/net-ssh]
5
-
6
- = Net::SSH 5.x
7
-
8
- * Docs: http://net-ssh.github.com/net-ssh
9
- * Issues: https://github.com/net-ssh/net-ssh/issues
10
- * Codes: https://github.com/net-ssh/net-ssh
11
- * Email: net-ssh@solutious.com
12
-
13
- <em>As of v2.6.4, all gem releases are signed. See INSTALL.</em>
14
-
15
- == DESCRIPTION:
16
-
17
- Net::SSH is a pure-Ruby implementation of the SSH2 client protocol. It allows you to write programs that invoke and interact with processes on remote servers, via SSH2.
18
-
19
- == FEATURES:
20
-
21
- * Execute processes on remote servers and capture their output
22
- * Run multiple processes in parallel over a single SSH connection
23
- * Support for SSH subsystems
24
- * Forward local and remote ports via an SSH connection
25
-
26
- == SYNOPSIS:
27
-
28
- In a nutshell:
29
-
30
- require 'net/ssh'
31
-
32
- Net::SSH.start('host', 'user', password: "password") do |ssh|
33
- # capture all stderr and stdout output from a remote process
34
- output = ssh.exec!("hostname")
35
- puts output
36
-
37
- # capture only stdout matching a particular pattern
38
- stdout = ""
39
- ssh.exec!("ls -l /home/jamis") do |channel, stream, data|
40
- stdout << data if stream == :stdout
41
- end
42
- puts stdout
43
-
44
- # run multiple processes in parallel to completion
45
- ssh.exec "sed ..."
46
- ssh.exec "awk ..."
47
- ssh.exec "rm -rf ..."
48
- ssh.loop
49
-
50
- # open a new channel and configure a minimal set of callbacks, then run
51
- # the event loop until the channel finishes (closes)
52
- channel = ssh.open_channel do |ch|
53
- ch.exec "/usr/local/bin/ruby /path/to/file.rb" do |ch, success|
54
- raise "could not execute command" unless success
55
-
56
- # "on_data" is called when the process writes something to stdout
57
- ch.on_data do |c, data|
58
- $stdout.print data
59
- end
60
-
61
- # "on_extended_data" is called when the process writes something to stderr
62
- ch.on_extended_data do |c, type, data|
63
- $stderr.print data
64
- end
65
-
66
- ch.on_close { puts "done!" }
67
- end
68
- end
69
-
70
- channel.wait
71
-
72
- # forward connections on local port 1234 to port 80 of www.capify.org
73
- ssh.forward.local(1234, "www.capify.org", 80)
74
- ssh.loop { true }
75
- end
76
-
77
- See Net::SSH for more documentation, and links to further information.
78
-
79
- == REQUIREMENTS:
80
-
81
- The only requirement you might be missing is the OpenSSL bindings for Ruby. These are built by default on most platforms, but you can verify that they're built and installed on your system by running the following command line:
82
-
83
- ruby -ropenssl -e 'puts OpenSSL::OPENSSL_VERSION'
84
-
85
- If that spits out something like "OpenSSL 0.9.8g 19 Oct 2007", then you're set. If you get an error, then you'll need to see about rebuilding ruby with OpenSSL support, or (if your platform supports it) installing the OpenSSL bindings separately.
86
-
87
- Lastly, if you want to run the tests or use any of the Rake tasks, you'll need Mocha and other dependencies listed in Gemfile
88
-
89
-
90
- == INSTALL:
91
-
92
- * gem install net-ssh (might need sudo privileges)
93
-
94
- NOTE: If you are running on jruby on windows you need to install jruby-pageant manually (gemspec doesn't allow for platform specific dependencies).
95
-
96
- However, in order to be sure the code you're installing hasn't been tampered with, it's recommended that you verify the signature[http://docs.rubygems.org/read/chapter/21]. To do this, you need to add my public key as a trusted certificate (you only need to do this once):
97
-
98
- # Add the public key as a trusted certificate
99
- # (You only need to do this once)
100
- $ curl -O https://raw.githubusercontent.com/net-ssh/net-ssh/master/net-ssh-public_cert.pem
101
- $ gem cert --add net-ssh-public_cert.pem
102
-
103
- Then, when install the gem, do so with high security:
104
-
105
- $ gem install net-ssh -P HighSecurity
106
-
107
- If you don't add the public key, you'll see an error like "Couldn't verify data signature". If you're still having trouble let me know and I'll give you a hand.
108
-
109
- For ed25519 public key auth support your bundle file should contain ```ed25519```, ```bcrypt_pbkdf``` dependencies.
110
-
111
- == RUBY SUPPORT
112
-
113
- * Ruby 1.8.x is supported up until the net-ssh 2.5.1 release.
114
- * Ruby 1.9.x is supported up until the net-ssh 2.9.x release.
115
- * See {net-ssh.gemspec}[https://github.com/net-ssh/net-ssh/blob/master/net-ssh.gemspec] for current versions ruby requirements
116
-
117
- == RUNNING TESTS
118
-
119
- Run the test suite from the net-ssh directory with the following command:
120
-
121
- bundle exec rake test
122
-
123
- Run a single test file like this:
124
-
125
- ruby -Ilib -Itest test/transport/test_server_version.rb
126
-
127
- To run integration tests see test/integration/README.txt
128
-
129
- === BUILDING GEM
130
-
131
- rake build
132
-
133
- === GEM SIGNING (for maintainers)
134
-
135
- If you have the net-ssh private signing key, you will be able to create signed release builds. Make sure the private key path matches the `signing_key` path set in `net-ssh.gemspec` and tell rake to sign the gem by setting the `NET_SSH_BUILDGEM_SIGNED` flag:
136
-
137
- NET_SSH_BUILDGEM_SIGNED=true rake build
138
-
139
- For time to time, the public certificate associated to the private key needs to be renewed. You can do this with the following command:
140
-
141
- gem cert --build netssh@solutious.com --private-key path/2/net-ssh-private_key.pem
142
- mv gem-public_cert.pem net-ssh-public_cert.pem
143
- gem cert --add net-ssh-public_cert.pem
144
-
145
-
146
- == LICENSE:
147
-
148
- (The MIT License)
149
-
150
- Copyright (c) 2008 Jamis Buck
151
-
152
- Permission is hereby granted, free of charge, to any person obtaining
153
- a copy of this software and associated documentation files (the
154
- 'Software'), to deal in the Software without restriction, including
155
- without limitation the rights to use, copy, modify, merge, publish,
156
- distribute, sublicense, and/or sell copies of the Software, and to
157
- permit persons to whom the Software is furnished to do so, subject to
158
- the following conditions:
159
-
160
- The above copyright notice and this permission notice shall be
161
- included in all copies or substantial portions of the Software.
162
-
163
- THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
164
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
165
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
166
- IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
167
- CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
168
- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
169
- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.