oidc_provider 0.3.1 → 0.3.2
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 +4 -4
- data/README.md +1 -1
- data/app/controllers/oidc_provider/authorizations_controller.rb +1 -1
- data/app/controllers/oidc_provider/concerns/authentication.rb +2 -2
- data/app/controllers/oidc_provider/discovery_controller.rb +5 -5
- data/lib/oidc_provider.rb +3 -0
- data/lib/oidc_provider/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7c504532c6405c7f41979a993c21991615aa11f712c6a15614fc39fb13e8ab37
|
4
|
+
data.tar.gz: 71cb6284b3343f18c94d088c9cc4684c2d4af33a87533dd7221736b368d2cfc7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8409ca665b3ccc46b0704181b98edec93425f86d149b658cdcbe849d908627b8b30dd5dde1b3b76b24b02c5afa373a2091628375bc76bf0b11c44d04cb372926
|
7
|
+
data.tar.gz: e34af03142b05bedcfd334f7845c9de3395b86372ab76f4c67c4e9204c53b8b28018440167ebc8ff43d79216c53ec2b48a0e6cc56aa4d83d97efd5817593dcdf
|
data/README.md
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
module OIDCProvider
|
2
2
|
module Concerns
|
3
3
|
module Authentication
|
4
|
-
def
|
4
|
+
def oidc_current_account
|
5
5
|
send(OIDCProvider.current_account_method)
|
6
6
|
end
|
7
7
|
|
@@ -10,7 +10,7 @@ module OIDCProvider
|
|
10
10
|
end
|
11
11
|
|
12
12
|
def require_authentication
|
13
|
-
|
13
|
+
send(OIDCProvider.current_authentication_method)
|
14
14
|
end
|
15
15
|
|
16
16
|
def require_access_token
|
@@ -27,11 +27,11 @@ module OIDCProvider
|
|
27
27
|
def openid_configuration
|
28
28
|
config = OpenIDConnect::Discovery::Provider::Config::Response.new(
|
29
29
|
issuer: OIDCProvider.issuer,
|
30
|
-
authorization_endpoint: authorizations_url,
|
31
|
-
token_endpoint: tokens_url,
|
32
|
-
userinfo_endpoint: user_info_url,
|
33
|
-
end_session_endpoint: end_session_url,
|
34
|
-
jwks_uri: jwks_url,
|
30
|
+
authorization_endpoint: authorizations_url(host: OIDCProvider.issuer),
|
31
|
+
token_endpoint: tokens_url(host: OIDCProvider.issuer),
|
32
|
+
userinfo_endpoint: user_info_url(host: OIDCProvider.issuer),
|
33
|
+
end_session_endpoint: end_session_url(host: OIDCProvider.issuer),
|
34
|
+
jwks_uri: jwks_url(host: OIDCProvider.issuer),
|
35
35
|
scopes_supported: ["openid"] + OIDCProvider.supported_scopes.map(&:name),
|
36
36
|
response_types_supported: [:code],
|
37
37
|
grant_types_supported: [:authorization_code],
|
data/lib/oidc_provider.rb
CHANGED
@@ -31,6 +31,9 @@ module OIDCProvider
|
|
31
31
|
mattr_accessor :current_account_method
|
32
32
|
@@current_account_method = :current_user
|
33
33
|
|
34
|
+
mattr_accessor :current_authentication_method
|
35
|
+
@@current_authentication_method = :authenticate_user!
|
36
|
+
|
34
37
|
mattr_accessor :account_identifier
|
35
38
|
@@account_identifier = :id
|
36
39
|
|