devise_auth_proxy 0.2.10 → 0.2.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8c5675d27e3bcd5d4206f86b6b2c9f01b6fbae7beca8399bf28b41bdd9bae4a4
4
- data.tar.gz: 607124aafe2da1c99ba2f2e54e040ef99892edcbeada88f759b20f89b1e42f57
3
+ metadata.gz: 76a08bfabfbd0b04ce4cb7fb4ae6b5d6cd53296b365158adc95e8eb7e7e33e47
4
+ data.tar.gz: c6c81ce74bd088e22066c409d6c94d26ddc0883d71b8ae920f6860569be43873
5
5
  SHA512:
6
- metadata.gz: e93177f7e0a21cfb1ea8d626f94e3319042fbfd8f5b74cf5c1b0f17323400ae60402ae2dd67444202d74e7eab5572a90809a420c4c2bb95a0083fd388a6a135f
7
- data.tar.gz: 8231753cf5baed0c9d0e939a5f4edb4f59d2ee99940864dc48ae11bda8d44b1ef8ddfd779459dbbcb8303135b17adbdecfa3236c541405ef68b8d2162dfff861
6
+ metadata.gz: ae48cbc65b9423bb5da6fabd84910c98e89d13b25f420e185fd92777afd2a471b60f2196fbee00ec9fa84b3fda9b6738a8cf88c5129e1e0a2e87942f1259d520
7
+ data.tar.gz: 742e2d8f3a6f412781bd548e5f091766c019626d63dc6b665e0c1d30a9302054049237502d5e89cff8b459e43d3a660cbdc4399aabc2cbb4177f1bd1dbebee53
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- devise_auth_proxy (0.2.10)
4
+ devise_auth_proxy (0.2.11)
5
5
  devise
6
6
 
7
7
  GEM
data/README.md CHANGED
@@ -33,6 +33,7 @@ Configuration options:
33
33
  * `auto_update` - Boolean (default: false). Whether to auto-update authenticated user attributes from proxy user attributes.
34
34
  * `default_role` - List (default: []). A list of role default for new user. If your application integrate with CanCan of something like that.
35
35
  * `logout_service` - String. A service to handle logout session.
36
+ * `skip_session` - Boolean (default: false). To skip storage login session.
36
37
  * `logout_url` - String (default: '/'). For redirecting to a proxy user logout URL after signing out of the Rails application. Include DeviseAuthProxy::ControllerBehavior in your application controller to enable (by overriding Devise's after_sign_out_path_for).
37
38
 
38
39
 
@@ -48,6 +49,7 @@ DeviseAuthProxy.configure do |config|
48
49
  config.attribute_map = { email: 'mail' }
49
50
  config.default_role = ['role_name / role_id']
50
51
  config.logout_service = '<service name>'
52
+ config.skip_session = true
51
53
  config.logout_url = "http://localhost:3000/logout"
52
54
  end
53
55
  ```
@@ -4,7 +4,8 @@ require 'devise_auth_proxy/version'
4
4
  module DeviseAuthProxy
5
5
  class << self
6
6
  attr_accessor :env_key, :auto_create, :auto_update, :auth_key,
7
- :attribute_map, :default_role, :logout_service, :logout_url
7
+ :attribute_map, :default_role, :logout_service, :logout_url,
8
+ :skip_session
8
9
  end
9
10
 
10
11
  # request.env key for remote user name
@@ -35,6 +36,9 @@ module DeviseAuthProxy
35
36
  # (it overrides Devise's after_sign_out_path_for method).
36
37
  self.logout_url = '/'
37
38
 
39
+ # To skip storage login session. Default is false.
40
+ self.skip_session = false
41
+
38
42
  def self.configure
39
43
  yield self
40
44
  end
@@ -17,6 +17,10 @@ module Devise
17
17
  success!(resource)
18
18
  end
19
19
 
20
+ def store?
21
+ !DeviseAuthProxy.skip_session
22
+ end
23
+
20
24
  end
21
25
  end
22
26
  end
@@ -1,3 +1,3 @@
1
1
  module DeviseAuthProxy
2
- VERSION = "0.2.10"
2
+ VERSION = "0.2.11"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: devise_auth_proxy
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.10
4
+ version: 0.2.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - QuangTK
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-01 00:00:00.000000000 Z
11
+ date: 2020-10-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: devise