winrm 1.1.2 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (7) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +4 -0
  3. data/README.md +55 -49
  4. data/Rakefile +8 -36
  5. data/VERSION +1 -1
  6. data/winrm.gemspec +6 -6
  7. metadata +74 -40
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 6f98c1cfc63e401f92df6150d7c21a7855e4479b
4
+ data.tar.gz: 9ead6674acfe95b0164408814c4649b0142d312f
5
+ SHA512:
6
+ metadata.gz: 4a0b02e78d87600396e91e50c685fd928643c2cce6ef43d92fc835d89aa7e614fec5d924ee87837b5795b1cb3cc986ff3807c5a13b6a3391730aaf1e536ffc06
7
+ data.tar.gz: 9aafc7838af16d9b216a44a407326a1acbbe4c55287ff54b6ddcdf04ae5f521cf3f146ce918af94186f1419e02a620a0cf5cf5ec47b43673aa2f0ccfa532ff7e
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+ gemspec
3
+
4
+ gem 'rspec'
data/README.md CHANGED
@@ -6,46 +6,10 @@ not limitted to, running batch scripts, powershell scripts and fetching WMI
6
6
  variables. For more information on WinRM, please visit Microsoft's WinRM
7
7
  site: http://msdn.microsoft.com/en-us/library/aa384426(v=VS.85).aspx
8
8
 
9
- ## My Info
10
- * Twitter: [@zentourist](https://twitter.com/zentourist)
11
- * BLOG: [http://distributed-frostbite.blogspot.com/](http://distributed-frostbite.blogspot.com/)
12
- * Add me in LinkedIn: [http://www.linkedin.com/in/danwanek](http://www.linkedin.com/in/danwanek)
13
- * Find me on irc.freenode.net in #ruby-lang (zenChild)
14
-
15
- ## Current features
16
-
17
- 1. GSSAPI support: This is the default way that Windows authenticates and
18
- secures WinRM messages. In order for this to work the computer you are
19
- connecting to must be a part of an Active Directory domain and you must
20
- have local credentials via kinit. GSSAPI support is dependent on the
21
- gssapi gem which only supports the MIT Kerberos libraries at this time.
22
-
23
- If you are using this method there is no longer a need to change the
24
- WinRM service authentication settings. You can simply do a
25
- 'winrm quickconfig' on your server or enable WinRM via group policy and
26
- everything should be working.
27
-
28
- 2. Multi-Instance support: The SOAP back-end has been completely gutted
29
- and is now using some of the Savon core libraries for parsing and
30
- building packets. Moving away from Handsoap allows multiple instances
31
- to be created because the SOAP backend is no longer a Singleton type
32
- class.
33
-
34
-
35
- ## !!!SHOUTS OUT!!!
36
- Many thanks to the following for their many patches....
37
- * Seth Chisamore (https://github.com/schisamo)
38
- * Paul Morton (https://github.com/pmorton)
39
-
40
-
41
-
42
- ## INSTALL:
9
+ ## Install
43
10
  `gem install -r winrm` then on the server `winrm quickconfig` as admin
44
11
 
45
- ## USE:
46
- `require 'winrm'`
47
-
48
- ## EXAMPLE:
12
+ ## Example
49
13
  ```ruby
50
14
  require 'winrm'
51
15
  endpoint = http://mywinrmhost:5985/wsman
@@ -59,32 +23,74 @@ end
59
23
 
60
24
  There are various connection types you can specify upon initialization:
61
25
 
62
- #### PLAINTEXT
26
+ It is recommended that you <code>:disable_sspi => true</code> if you are using the plaintext or ssl transport.
27
+
28
+ #### Plaintext
63
29
  ```ruby
64
- WinRM::WinRMWebService.new(endpoint, :plaintext, :user => myuser, :pass => mypass)
30
+ WinRM::WinRMWebService.new(endpoint, :plaintext, :user => myuser, :pass => mypass, :disable_sspi => true)
65
31
 
66
- # Same but force basic authentication:
32
+ ## Same but force basic authentication:
67
33
  WinRM::WinRMWebService.new(endpoint, :plaintext, :user => myuser, :pass => mypass, :basic_auth_only => true)
68
34
  ```
69
35
 
70
36
  #### SSL
71
37
  ```ruby
72
- WinRM::WinRMWebService.new(endpoint, :ssl, :user => myuser, :pass => mypass)
38
+ WinRM::WinRMWebService.new(endpoint, :ssl, :user => myuser, :pass => mypass, :disable_sspi => true)
73
39
 
74
- # Same but force basic authentication:
40
+ ## Specifying CA path
41
+ WinRM::WinRMWebService.new(endpoint, :ssl, :user => myuser, :pass => mypass, :ca_trust_path => '/etc/ssl/certs/cert.pem', :basic_auth_only => true)
42
+
43
+ ## Same but force basic authentication:
75
44
  WinRM::WinRMWebService.new(endpoint, :ssl, :user => myuser, :pass => mypass, :basic_auth_only => true)
76
45
  ```
77
46
 
78
- #### KERBEROS
47
+ #### Kerberos
79
48
  ```ruby
80
49
  WinRM::WinRMWebService.new(endpoint, :kerberos, :realm => 'MYREALM.COM')
81
50
  ```
82
51
 
83
- ## DISCLAIMER
84
- If you see something that could be done better or would like to help out in the development of this code please feel free to clone the repository and send me patches.
52
+ ## Troubleshooting
53
+ You may have some errors like ```WinRM::WinRMHTTPTransportError: Bad HTTP response returned from server (401).```.
54
+ You can run the following commands on the server to try to solve the problem:
55
+ ```
56
+ winrm set winrm/config/client/auth @{Basic="true"}
57
+ winrm set winrm/config/service/auth @{Basic="true"}
58
+ winrm set winrm/config/service @{AllowUnencrypted="true"}
59
+ ```
60
+ You can read more about that on issue [#29](https://github.com/WinRb/WinRM/issues/29)
61
+
62
+
63
+ ## Current features
64
+
65
+ 1. GSSAPI support: This is the default way that Windows authenticates and
66
+ secures WinRM messages. In order for this to work the computer you are
67
+ connecting to must be a part of an Active Directory domain and you must
68
+ have local credentials via kinit. GSSAPI support is dependent on the
69
+ gssapi gem which only supports the MIT Kerberos libraries at this time.
70
+
71
+ If you are using this method there is no longer a need to change the
72
+ WinRM service authentication settings. You can simply do a
73
+ 'winrm quickconfig' on your server or enable WinRM via group policy and
74
+ everything should be working.
85
75
 
86
- `git clone git://github.com/zenchild/WinRM.git` or add an [issue](https://github.com/zenchild/WinRM/issues) on GitHub:
76
+ 2. Multi-Instance support: The SOAP back-end has been completely gutted
77
+ and is now using some of the Savon core libraries for parsing and
78
+ building packets. Moving away from Handsoap allows multiple instances
79
+ to be created because the SOAP backend is no longer a Singleton type
80
+ class.
87
81
 
88
- - - -
82
+ ## My Info
83
+ * Twitter: [@zentourist](https://twitter.com/zentourist)
84
+ * BLOG: [http://distributed-frostbite.blogspot.com/](http://distributed-frostbite.blogspot.com/)
85
+ * Add me in LinkedIn: [http://www.linkedin.com/in/danwanek](http://www.linkedin.com/in/danwanek)
86
+ * Find me on irc.freenode.net in #ruby-lang (zenChild)
87
+
88
+ ## Contributors
89
+ Many thanks to the following for their many patches....
90
+ * Seth Chisamore (https://github.com/schisamo)
91
+ * Paul Morton (https://github.com/pmorton)
92
+
93
+ ## Disclaimer
94
+ If you see something that could be done better or would like to help out in the development of this code please feel free to clone the repository and send me patches.
89
95
 
90
- Cheers!
96
+ `git clone git://github.com/WinRb/WinRM.git` or add an [issue](https://github.com/WinRb/WinRM/issues) on GitHub
data/Rakefile CHANGED
@@ -1,40 +1,12 @@
1
- require 'rubygems'
2
- require 'rake/clean'
3
- require 'date'
1
+ require "bundler/gem_tasks"
2
+ require 'rspec/core/rake_task'
4
3
 
5
- CLEAN.include("pkg")
6
- CLEAN.include("doc")
7
- CLEAN.include("*.gem")
8
-
9
- task :default => [:gem]
10
-
11
- desc "Build the gem from the gemspec"
12
- task :repackage do
13
- system "gem build winrm.gemspec"
4
+ RSpec::Core::RakeTask.new(:spec) do |t|
5
+ t.pattern = "spec/unit/**/*_spec.rb"
6
+ t.rspec_opts = '--format documentation --color'
14
7
  end
15
8
 
16
- desc "Build the gem without a version change"
17
- task :gem => [:clean, :repackage]
18
-
19
- desc "Increment the version by 1 minor release"
20
- task :versionup do
21
- ver = up_min_version
22
- puts "New version: #{ver}"
23
- end
24
-
25
- desc "Build the gem, but increment the version first"
26
- task :newrelease => [:versionup, :clean, :repackage]
27
-
28
-
29
- def up_min_version
30
- f = File.open('VERSION', 'r+')
31
- ver = f.readline.chomp
32
- v_arr = ver.split(/\./).map do |v|
33
- v.to_i
34
- end
35
- v_arr[2] += 1
36
- ver = v_arr.join('.')
37
- f.rewind
38
- f.write(ver)
39
- ver
9
+ RSpec::Core::RakeTask.new(:spec_all) do |t|
10
+ t.pattern = "spec/**/*_spec.rb"
11
+ t.rspec_opts = '--format documentation --color'
40
12
  end
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.1.2
1
+ 1.1.3
data/winrm.gemspec CHANGED
@@ -9,9 +9,9 @@ Gem::Specification.new do |s|
9
9
  s.version = version
10
10
  s.date = Date.today.to_s
11
11
 
12
- s.author = 'Dan Wanek'
13
- s.email = 'dan.wanek@gmail.com'
14
- s.homepage = "http://github.com/zenchild/WinRM"
12
+ s.author = ['Dan Wanek','Paul Morton']
13
+ s.email = ['dan.wanek@gmail.com','paul@themortonsonline.com']
14
+ s.homepage = "http://github.com/WinRb/WinRM"
15
15
 
16
16
  s.summary = 'Ruby library for Windows Remote Management'
17
17
  s.description = <<-EOF
@@ -25,10 +25,10 @@ Gem::Specification.new do |s|
25
25
 
26
26
  s.required_ruby_version = '>= 1.9.0'
27
27
  s.add_runtime_dependency 'gssapi', '~> 1.0.0'
28
- s.add_runtime_dependency 'nokogiri', '~> 1.5.0'
29
- s.add_runtime_dependency 'httpclient', '~> 2.2.0.2'
28
+ s.add_runtime_dependency 'httpclient', '~> 2.2', '>= 2.2.0.2'
29
+ s.add_runtime_dependency 'nokogiri', '~> 1.5'
30
30
  s.add_runtime_dependency 'rubyntlm', '~> 0.1.1'
31
31
  s.add_runtime_dependency 'uuidtools', '~> 2.1.2'
32
32
  s.add_runtime_dependency 'savon', '= 0.9.5'
33
- s.add_runtime_dependency 'logging', '~> 1.6.1'
33
+ s.add_runtime_dependency 'logging', '~> 1.6', '>= 1.6.1'
34
34
  end
metadata CHANGED
@@ -1,97 +1,131 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: winrm
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2
5
- prerelease:
4
+ version: 1.1.3
6
5
  platform: ruby
7
6
  authors:
8
7
  - Dan Wanek
8
+ - Paul Morton
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-06-08 00:00:00.000000000 Z
12
+ date: 2013-10-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: gssapi
16
- requirement: &9359240 !ruby/object:Gem::Requirement
17
- none: false
16
+ requirement: !ruby/object:Gem::Requirement
18
17
  requirements:
19
18
  - - ~>
20
19
  - !ruby/object:Gem::Version
21
20
  version: 1.0.0
22
21
  type: :runtime
23
22
  prerelease: false
24
- version_requirements: *9359240
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - ~>
26
+ - !ruby/object:Gem::Version
27
+ version: 1.0.0
25
28
  - !ruby/object:Gem::Dependency
26
- name: nokogiri
27
- requirement: &9358240 !ruby/object:Gem::Requirement
28
- none: false
29
+ name: httpclient
30
+ requirement: !ruby/object:Gem::Requirement
29
31
  requirements:
30
32
  - - ~>
31
33
  - !ruby/object:Gem::Version
32
- version: 1.5.0
34
+ version: '2.2'
35
+ - - '>='
36
+ - !ruby/object:Gem::Version
37
+ version: 2.2.0.2
33
38
  type: :runtime
34
39
  prerelease: false
35
- version_requirements: *9358240
36
- - !ruby/object:Gem::Dependency
37
- name: httpclient
38
- requirement: &9356700 !ruby/object:Gem::Requirement
39
- none: false
40
+ version_requirements: !ruby/object:Gem::Requirement
40
41
  requirements:
41
42
  - - ~>
43
+ - !ruby/object:Gem::Version
44
+ version: '2.2'
45
+ - - '>='
42
46
  - !ruby/object:Gem::Version
43
47
  version: 2.2.0.2
48
+ - !ruby/object:Gem::Dependency
49
+ name: nokogiri
50
+ requirement: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ~>
53
+ - !ruby/object:Gem::Version
54
+ version: '1.5'
44
55
  type: :runtime
45
56
  prerelease: false
46
- version_requirements: *9356700
57
+ version_requirements: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ~>
60
+ - !ruby/object:Gem::Version
61
+ version: '1.5'
47
62
  - !ruby/object:Gem::Dependency
48
63
  name: rubyntlm
49
- requirement: &9355960 !ruby/object:Gem::Requirement
50
- none: false
64
+ requirement: !ruby/object:Gem::Requirement
51
65
  requirements:
52
66
  - - ~>
53
67
  - !ruby/object:Gem::Version
54
68
  version: 0.1.1
55
69
  type: :runtime
56
70
  prerelease: false
57
- version_requirements: *9355960
71
+ version_requirements: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ~>
74
+ - !ruby/object:Gem::Version
75
+ version: 0.1.1
58
76
  - !ruby/object:Gem::Dependency
59
77
  name: uuidtools
60
- requirement: &9354860 !ruby/object:Gem::Requirement
61
- none: false
78
+ requirement: !ruby/object:Gem::Requirement
62
79
  requirements:
63
80
  - - ~>
64
81
  - !ruby/object:Gem::Version
65
82
  version: 2.1.2
66
83
  type: :runtime
67
84
  prerelease: false
68
- version_requirements: *9354860
85
+ version_requirements: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ~>
88
+ - !ruby/object:Gem::Version
89
+ version: 2.1.2
69
90
  - !ruby/object:Gem::Dependency
70
91
  name: savon
71
- requirement: &9354080 !ruby/object:Gem::Requirement
72
- none: false
92
+ requirement: !ruby/object:Gem::Requirement
73
93
  requirements:
74
- - - =
94
+ - - '='
75
95
  - !ruby/object:Gem::Version
76
96
  version: 0.9.5
77
97
  type: :runtime
78
98
  prerelease: false
79
- version_requirements: *9354080
99
+ version_requirements: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - '='
102
+ - !ruby/object:Gem::Version
103
+ version: 0.9.5
80
104
  - !ruby/object:Gem::Dependency
81
105
  name: logging
82
- requirement: &9353360 !ruby/object:Gem::Requirement
83
- none: false
106
+ requirement: !ruby/object:Gem::Requirement
84
107
  requirements:
85
108
  - - ~>
109
+ - !ruby/object:Gem::Version
110
+ version: '1.6'
111
+ - - '>='
86
112
  - !ruby/object:Gem::Version
87
113
  version: 1.6.1
88
114
  type: :runtime
89
115
  prerelease: false
90
- version_requirements: *9353360
91
- description: ! ' Ruby library for Windows Remote Management
92
-
93
- '
94
- email: dan.wanek@gmail.com
116
+ version_requirements: !ruby/object:Gem::Requirement
117
+ requirements:
118
+ - - ~>
119
+ - !ruby/object:Gem::Version
120
+ version: '1.6'
121
+ - - '>='
122
+ - !ruby/object:Gem::Version
123
+ version: 1.6.1
124
+ description: |2
125
+ Ruby library for Windows Remote Management
126
+ email:
127
+ - dan.wanek@gmail.com
128
+ - paul@themortonsonline.com
95
129
  executables: []
96
130
  extensions: []
97
131
  extra_rdoc_files:
@@ -99,6 +133,7 @@ extra_rdoc_files:
99
133
  - LICENSE
100
134
  files:
101
135
  - .gitignore
136
+ - Gemfile
102
137
  - LICENSE
103
138
  - README.md
104
139
  - Rakefile
@@ -120,8 +155,9 @@ files:
120
155
  - test/spec/winrm_primitives_spec.rb
121
156
  - test/spec/wql_spec.rb
122
157
  - winrm.gemspec
123
- homepage: http://github.com/zenchild/WinRM
158
+ homepage: http://github.com/WinRb/WinRM
124
159
  licenses: []
160
+ metadata: {}
125
161
  post_install_message:
126
162
  rdoc_options:
127
163
  - -x
@@ -131,21 +167,19 @@ rdoc_options:
131
167
  require_paths:
132
168
  - lib
133
169
  required_ruby_version: !ruby/object:Gem::Requirement
134
- none: false
135
170
  requirements:
136
- - - ! '>='
171
+ - - '>='
137
172
  - !ruby/object:Gem::Version
138
173
  version: 1.9.0
139
174
  required_rubygems_version: !ruby/object:Gem::Requirement
140
- none: false
141
175
  requirements:
142
- - - ! '>='
176
+ - - '>='
143
177
  - !ruby/object:Gem::Version
144
178
  version: '0'
145
179
  requirements: []
146
180
  rubyforge_project:
147
- rubygems_version: 1.8.17
181
+ rubygems_version: 2.0.6
148
182
  signing_key:
149
- specification_version: 3
183
+ specification_version: 4
150
184
  summary: Ruby library for Windows Remote Management
151
185
  test_files: []