gitlab_omniauth-ldap 2.1.1 → 2.2.0

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
- SHA1:
3
- metadata.gz: 6d0257f9f6fc7f3368403940bba04ecc860b8c52
4
- data.tar.gz: 706ce31f13aa10bc0e5e982ae2ad52d611ec1dbd
2
+ SHA256:
3
+ metadata.gz: 642e2ab518a4f8a4ba59ebaf35cfa5986e610fbe15692dd95dd7bf5a6a3a06fa
4
+ data.tar.gz: 630e6293aa7810f87433fb1a0bb51a4e8cd801f1e8e3f4865bdea803ba3bd57b
5
5
  SHA512:
6
- metadata.gz: 22c81461f04cd89702366adabeeff539195a887f046ebd1d0235f9bbbed2d0c8ace4a74e151924a37d330de3806727475e2d27790a328eb824e623e1e0e9295d
7
- data.tar.gz: 29bcd91f9be90911956f7891f81f33fcc591c0258861e2a99f2b99312b8ae6473cec4dfcef4dd535081254530e8e50b0968aa385b127ba530459ec97ba2ae6c7
6
+ metadata.gz: c97fd71ee465d6be8b3a91a532dcbfa24242bbe5ad6e18305881af005dc9c96c661e03298f9c4e75bba4b19c9e3152cc04d732e871eaf431422381ca7862f300
7
+ data.tar.gz: 14738f46becca517da74c67ad6f0fb37de4e545c98636e8a2a285eba5059e1722617662107196977847518416baf32221123f07ed93b6382fd5d6b6c580a56eb
data/.gitlab-ci.yml CHANGED
@@ -1,12 +1,17 @@
1
- image: "ruby:2.3.1"
2
-
3
- before_script:
4
- - bundle install
1
+ default:
2
+ image: "ruby:${RUBY_VERSION}"
5
3
 
6
4
  stages:
7
5
  - test
8
6
 
9
- rspec:
10
- stage: test
7
+ .test-template: &test
8
+ before_script:
9
+ - bundle install
11
10
  script:
12
11
  - bundle exec rake spec
12
+
13
+ rspec:
14
+ parallel:
15
+ matrix:
16
+ - RUBY_VERSION: [ "2.7", "3.0" ]
17
+ <<: *test
@@ -9,7 +9,7 @@ Gem::Specification.new do |gem|
9
9
  gem.homepage = "https://gitlab.com/gitlab-org/omniauth-ldap"
10
10
  gem.license = "MIT"
11
11
 
12
- gem.add_runtime_dependency 'omniauth', '~> 1.3'
12
+ gem.add_runtime_dependency 'omniauth', '>= 1.3', '< 3'
13
13
  gem.add_runtime_dependency 'net-ldap', '~> 0.16'
14
14
  gem.add_runtime_dependency 'pyu-ruby-sasl', '>= 0.0.3.3', '< 0.1'
15
15
  gem.add_runtime_dependency 'rubyntlm', '~> 0.5'
@@ -1,5 +1,5 @@
1
1
  module OmniAuth
2
2
  module LDAP
3
- VERSION = "2.1.1"
3
+ VERSION = "2.2.0"
4
4
  end
5
5
  end
@@ -30,7 +30,20 @@ describe "OmniAuth::Strategies::LDAP" do
30
30
  end
31
31
 
32
32
  describe '/auth/ldap' do
33
- before(:each){ get '/auth/ldap' }
33
+ let!(:csrf_token) { SecureRandom.base64(32) }
34
+ let(:post_env) { make_env('/auth/ldap', 'rack.session' => { csrf: csrf_token }, 'rack.input' => StringIO.new("authenticity_token=#{escaped_token}")) }
35
+ let(:escaped_token) { URI.encode_www_form_component(csrf_token, Encoding::UTF_8) }
36
+
37
+ before(:each) { post '/auth/ldap', nil, post_env }
38
+
39
+ def make_env(path = '/auth/ldap', props = {})
40
+ {
41
+ 'REQUEST_METHOD' => 'POST',
42
+ 'PATH_INFO' => path,
43
+ 'rack.session' => {},
44
+ 'rack.input' => StringIO.new('test=true')
45
+ }.merge(props)
46
+ end
34
47
 
35
48
  it 'should display a form' do
36
49
  last_response.status.should == 200
metadata CHANGED
@@ -1,29 +1,35 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab_omniauth-ldap
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.1
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ping Yu
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-02-22 00:00:00.000000000 Z
11
+ date: 2022-06-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: omniauth
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.3'
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: '3'
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
- - - "~>"
27
+ - - ">="
25
28
  - !ruby/object:Gem::Version
26
29
  version: '1.3'
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: '3'
27
33
  - !ruby/object:Gem::Dependency
28
34
  name: net-ldap
29
35
  requirement: !ruby/object:Gem::Requirement
@@ -171,8 +177,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
171
177
  - !ruby/object:Gem::Version
172
178
  version: '0'
173
179
  requirements: []
174
- rubyforge_project:
175
- rubygems_version: 2.6.14.3
180
+ rubygems_version: 3.3.16
176
181
  signing_key:
177
182
  specification_version: 4
178
183
  summary: A LDAP strategy for OmniAuth.