omniauth-saml 1.10.5 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of omniauth-saml might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c4976bd95b3ab1533410bfc3d03bc4f534a70d170f10a415e5078981fe3b828f
4
- data.tar.gz: 8feed5b83f10f107e1195e6cd15237f60a9b2d0877b0519459306967f6fd5eb4
3
+ metadata.gz: 36019dbb0985207e4a8e6faa24f50abed3f707d3d4c8ad1370403e658b708730
4
+ data.tar.gz: '042845e9351550c797149bfdba0f395059a0a8d590d70cdcec19828e9cc4a6c6'
5
5
  SHA512:
6
- metadata.gz: 0ecc46b169e31c23d8cc5a3b37bfddd854561355f70bf098cb9f2b7ab2f670f65929c598461b3f766335e3cdd6d2872574433bef4fe61e82ed344e1fc9d73eaf
7
- data.tar.gz: 3701fd3f185557bfa05f9dfbc9ff35cba663d3c25c346d602cee35b8576a87e52486bed0d00e44760a829c95f92788aac3b8e1eba97f0c73cfadd5feab757b34
6
+ metadata.gz: 5f8100b1f45f5e09e778bb6ccf96bffdf041b5dc7da72a67fe5063fe30eb01c7a61481c8b5c8e3700b91af362e3a5f8915c5797d97eb3f2e3197333a1117bb49
7
+ data.tar.gz: 71c78f0ff383876af1fe15d471e35ea70bedbabccc6e2b7b79bf7c6f643c5f5330bbe706b24b25c92f47fb68d85ec062c9e12819a5430cbff9e91fb7e08c3055
data/CHANGELOG.md CHANGED
@@ -1,3 +1,12 @@
1
+ <a name="v2.0.0"></a>
2
+ ### v2.0.0 (2021-01-13)
3
+
4
+
5
+ #### Chores
6
+
7
+ * Allow OmniAuth 2.0.0 ([f7ec7ee](/../../commit/f7ec7ee))
8
+
9
+
1
10
  <a name="v1.10.3"></a>
2
11
  ### v1.10.3 (2020-10-06)
3
12
 
data/README.md CHANGED
@@ -17,7 +17,7 @@ https://github.com/omniauth/omniauth-saml
17
17
  ## Requirements
18
18
 
19
19
  * [OmniAuth](http://www.omniauth.org/) 1.3+
20
- * Ruby 2.1.x+
20
+ * Ruby 2.4.x+
21
21
 
22
22
  ## Versioning
23
23
 
@@ -1,5 +1,5 @@
1
1
  module OmniAuth
2
2
  module SAML
3
- VERSION = '1.10.5'
3
+ VERSION = '2.0.0'
4
4
  end
5
5
  end
@@ -6,7 +6,7 @@ RSpec::Matchers.define :fail_with do |message|
6
6
  end
7
7
  end
8
8
 
9
- def post_xml(xml=:example_response, opts = {})
9
+ def post_xml(xml = :example_response, opts = {})
10
10
  post "/auth/saml/callback", opts.merge({'SAMLResponse' => load_xml(xml)})
11
11
  end
12
12
 
@@ -34,10 +34,10 @@ describe OmniAuth::Strategies::SAML, :type => :strategy do
34
34
  end
35
35
  let(:strategy) { [OmniAuth::Strategies::SAML, saml_options] }
36
36
 
37
- describe 'GET /auth/saml' do
37
+ describe 'POST /auth/saml' do
38
38
  context 'without idp runtime params present' do
39
39
  before do
40
- get '/auth/saml'
40
+ post '/auth/saml'
41
41
  end
42
42
 
43
43
  it 'should get authentication page' do
@@ -51,7 +51,7 @@ describe OmniAuth::Strategies::SAML, :type => :strategy do
51
51
 
52
52
  context 'with idp runtime params' do
53
53
  before do
54
- get '/auth/saml', 'original_param_key' => 'original_param_value', 'mapped_param_key' => 'mapped_param_value'
54
+ post '/auth/saml', 'original_param_key' => 'original_param_value', 'mapped_param_key' => 'mapped_param_value'
55
55
  end
56
56
 
57
57
  it 'should get authentication page' do
@@ -71,7 +71,7 @@ describe OmniAuth::Strategies::SAML, :type => :strategy do
71
71
 
72
72
  it 'should send the current callback_url as the assertion_consumer_service_url' do
73
73
  %w(foo.example.com bar.example.com).each do |host|
74
- get "https://#{host}/auth/saml"
74
+ post "https://#{host}/auth/saml"
75
75
 
76
76
  expect(last_response).to be_redirect
77
77
 
@@ -89,7 +89,7 @@ describe OmniAuth::Strategies::SAML, :type => :strategy do
89
89
  end
90
90
 
91
91
  context 'when authn request signing is requested' do
92
- subject { get '/auth/saml' }
92
+ subject { post '/auth/saml' }
93
93
 
94
94
  let(:private_key) { OpenSSL::PKey::RSA.new 2048 }
95
95
 
@@ -402,10 +402,10 @@ describe OmniAuth::Strategies::SAML, :type => :strategy do
402
402
  end
403
403
  end
404
404
 
405
- describe 'GET /auth/saml/metadata' do
405
+ describe 'POST /auth/saml/metadata' do
406
406
  before do
407
407
  saml_options[:issuer] = 'http://example.com/SAML'
408
- get '/auth/saml/metadata'
408
+ post '/auth/saml/metadata'
409
409
  end
410
410
 
411
411
  it 'should get SP metadata page' do
@@ -424,19 +424,19 @@ describe OmniAuth::Strategies::SAML, :type => :strategy do
424
424
  end
425
425
 
426
426
  context 'when hitting an unknown route in our sub path' do
427
- before { get '/auth/saml/unknown' }
427
+ before { post '/auth/saml/unknown' }
428
428
 
429
429
  specify { expect(last_response.status).to eql 404 }
430
430
  end
431
431
 
432
432
  context 'when hitting a completely unknown route' do
433
- before { get '/unknown' }
433
+ before { post '/unknown' }
434
434
 
435
435
  specify { expect(last_response.status).to eql 404 }
436
436
  end
437
437
 
438
438
  context 'when hitting a route that contains a substring match for the strategy name' do
439
- before { get '/auth/saml2/metadata' }
439
+ before { post '/auth/saml2/metadata' }
440
440
 
441
441
  it 'should not set the strategy' do
442
442
  expect(last_request.env['omniauth.strategy']).to be_nil
data/spec/spec_helper.rb CHANGED
@@ -16,6 +16,7 @@ require 'base64'
16
16
  TEST_LOGGER = Logger.new(StringIO.new)
17
17
  OneLogin::RubySaml::Logging.logger = TEST_LOGGER
18
18
  OmniAuth.config.logger = TEST_LOGGER
19
+ OmniAuth.config.request_validation_phase = proc {}
19
20
 
20
21
  RSpec.configure do |config|
21
22
  config.include Rack::Test::Methods
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-saml
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.10.5
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Raecoo Cao
@@ -14,7 +14,7 @@ authors:
14
14
  autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
- date: 2024-09-18 00:00:00.000000000 Z
17
+ date: 2021-01-14 00:00:00.000000000 Z
18
18
  dependencies:
19
19
  - !ruby/object:Gem::Dependency
20
20
  name: omniauth
@@ -22,34 +22,28 @@ dependencies:
22
22
  requirements:
23
23
  - - "~>"
24
24
  - !ruby/object:Gem::Version
25
- version: '1.3'
26
- - - ">="
27
- - !ruby/object:Gem::Version
28
- version: 1.3.2
25
+ version: '2.0'
29
26
  type: :runtime
30
27
  prerelease: false
31
28
  version_requirements: !ruby/object:Gem::Requirement
32
29
  requirements:
33
30
  - - "~>"
34
31
  - !ruby/object:Gem::Version
35
- version: '1.3'
36
- - - ">="
37
- - !ruby/object:Gem::Version
38
- version: 1.3.2
32
+ version: '2.0'
39
33
  - !ruby/object:Gem::Dependency
40
34
  name: ruby-saml
41
35
  requirement: !ruby/object:Gem::Requirement
42
36
  requirements:
43
37
  - - "~>"
44
38
  - !ruby/object:Gem::Version
45
- version: '1.17'
39
+ version: '1.9'
46
40
  type: :runtime
47
41
  prerelease: false
48
42
  version_requirements: !ruby/object:Gem::Requirement
49
43
  requirements:
50
44
  - - "~>"
51
45
  - !ruby/object:Gem::Version
52
- version: '1.17'
46
+ version: '1.9'
53
47
  - !ruby/object:Gem::Dependency
54
48
  name: rake
55
49
  requirement: !ruby/object:Gem::Requirement
@@ -167,17 +161,17 @@ required_ruby_version: !ruby/object:Gem::Requirement
167
161
  requirements:
168
162
  - - ">="
169
163
  - !ruby/object:Gem::Version
170
- version: '2.1'
164
+ version: '2.4'
171
165
  required_rubygems_version: !ruby/object:Gem::Requirement
172
166
  requirements:
173
167
  - - ">="
174
168
  - !ruby/object:Gem::Version
175
169
  version: '0'
176
170
  requirements: []
177
- rubygems_version: 3.5.15
171
+ rubygems_version: 3.1.2
178
172
  signing_key:
179
173
  specification_version: 4
180
174
  summary: A generic SAML strategy for OmniAuth.
181
175
  test_files:
182
- - spec/omniauth/strategies/saml_spec.rb
183
176
  - spec/spec_helper.rb
177
+ - spec/omniauth/strategies/saml_spec.rb