omniauth-keycloak 1.4.1 → 1.4.4

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
2
  SHA256:
3
- metadata.gz: a2e287221e83ebd9675dce6a96add0c979a5e953880fbacfa10357a6b7de2f1a
4
- data.tar.gz: 301ae570d0e3e72366913a472940d809db176338027069fec50138d1cebd8fbc
3
+ metadata.gz: 79b854153d87dedf293c8d1e4d30994169a92633d69ef4848e1a1af0356a82c2
4
+ data.tar.gz: 54f9007dd675375cec26c5b2c5447bc85b5077fa378723c099243501794eedb9
5
5
  SHA512:
6
- metadata.gz: 13bb46c55f76bd31550870fea1a78cea8fd50ae2fb6c9d3764002cc95c3edddb4a6748ee97d52b18d9add2c85a23a31f85c45eb5352c86482fbc3c2263542505
7
- data.tar.gz: f215a482d4c8f8760f8d86495bb6c5ea6cda2afb2fd15c8f9ff52aabfaea9d4c40fb81606edb4306f24d1dd0312f280dc8a728a7fad63901b94540566e99e0f6
6
+ metadata.gz: 1b0f823afd6af3f57472078f79da245b14867cfff35b1e892c777d1cdfe779524e6e68877534fdc19fc8b372705b777bf350d649a91f6b0bd7b8e7fd020b97ca
7
+ data.tar.gz: 8f51a1218d726e2a3de85d01355297ade8fe6e6f705752c870e374bf18684bdbf5bb2e83294e3653bf7ecc0885ce52383eec81f6dc37734b05bdf910732ddb00
data/CHANGELOG.md CHANGED
@@ -1,5 +1,64 @@
1
1
  # Changelog
2
2
 
3
+ ## [v1.4.3](https://github.com/ccrockett/omniauth-keycloak/tree/v1.4.3) (2022-07-24)
4
+
5
+ [Full Changelog](https://github.com/ccrockett/omniauth-keycloak/compare/v1.4.2...v1.4.3)
6
+
7
+ **Fixed bugs:**
8
+
9
+ - Error: uninitialized constant OmniAuth::Strategies::KeycloakOpenId::MultiJson after gem update [\#30](https://github.com/ccrockett/omniauth-keycloak/issues/30)
10
+
11
+ ## [v1.4.2](https://github.com/ccrockett/omniauth-keycloak/tree/v1.4.2) (2022-06-14)
12
+
13
+ [Full Changelog](https://github.com/ccrockett/omniauth-keycloak/compare/v1.4.1...v1.4.2)
14
+
15
+ **Closed issues:**
16
+
17
+ - Adjust endpoints to updated Keycloak paths [\#29](https://github.com/ccrockett/omniauth-keycloak/issues/29)
18
+ - Expose id\_token inside extra hash of auth hash [\#25](https://github.com/ccrockett/omniauth-keycloak/issues/25)
19
+
20
+ **Merged pull requests:**
21
+
22
+ - Set omniauth version to \>= 2.0 [\#28](https://github.com/ccrockett/omniauth-keycloak/pull/28) ([hobbypunk90](https://github.com/hobbypunk90))
23
+
24
+ ## [v1.4.1](https://github.com/ccrockett/omniauth-keycloak/tree/v1.4.1) (2022-05-25)
25
+
26
+ [Full Changelog](https://github.com/ccrockett/omniauth-keycloak/compare/v1.4.0...v1.4.1)
27
+
28
+ **Closed issues:**
29
+
30
+ - Get Request is now Post Request [\#23](https://github.com/ccrockett/omniauth-keycloak/issues/23)
31
+ - Is the "/auth/" part mandatory in Keycloak's configuration URL? [\#19](https://github.com/ccrockett/omniauth-keycloak/issues/19)
32
+ - Add example instructions for Keycloak configuration [\#14](https://github.com/ccrockett/omniauth-keycloak/issues/14)
33
+
34
+ **Merged pull requests:**
35
+
36
+ - expose id\_token inside extra hash of auth hash [\#26](https://github.com/ccrockett/omniauth-keycloak/pull/26) ([rah-wtag](https://github.com/rah-wtag))
37
+ - Bump bindata from 2.4.9 to 2.4.10 [\#22](https://github.com/ccrockett/omniauth-keycloak/pull/22) ([dependabot[bot]](https://github.com/apps/dependabot))
38
+
39
+ ## [v1.4.0](https://github.com/ccrockett/omniauth-keycloak/tree/v1.4.0) (2021-12-18)
40
+
41
+ [Full Changelog](https://github.com/ccrockett/omniauth-keycloak/compare/v1.3.0...v1.4.0)
42
+
43
+ **Closed issues:**
44
+
45
+ - Are there any reason to specify one certificate key to decode JWT? [\#17](https://github.com/ccrockett/omniauth-keycloak/issues/17)
46
+ - No route matches \[POST\] "/auth/keycloak\_openid" [\#15](https://github.com/ccrockett/omniauth-keycloak/issues/15)
47
+
48
+ **Merged pull requests:**
49
+
50
+ - Use JSON::JWK::Set instead of JSON::JWK [\#21](https://github.com/ccrockett/omniauth-keycloak/pull/21) ([hobbypunk90](https://github.com/hobbypunk90))
51
+ - Allow pass a Proc to the setup option when you specify a strategy [\#18](https://github.com/ccrockett/omniauth-keycloak/pull/18) ([Cambero](https://github.com/Cambero))
52
+ - Add information on how to use it to readme [\#16](https://github.com/ccrockett/omniauth-keycloak/pull/16) ([frenesim](https://github.com/frenesim))
53
+
54
+ ## [v1.3.0](https://github.com/ccrockett/omniauth-keycloak/tree/v1.3.0) (2021-05-17)
55
+
56
+ [Full Changelog](https://github.com/ccrockett/omniauth-keycloak/compare/v1.2.1...v1.3.0)
57
+
58
+ **Merged pull requests:**
59
+
60
+ - Bump Omniauth dependencies to v2 [\#13](https://github.com/ccrockett/omniauth-keycloak/pull/13) ([offner](https://github.com/offner))
61
+
3
62
  ## [v1.2.1](https://github.com/ccrockett/omniauth-keycloak/tree/v1.2.1) (2020-12-19)
4
63
 
5
64
  [Full Changelog](https://github.com/ccrockett/omniauth-keycloak/compare/v1.2.0...v1.2.1)
@@ -14,6 +73,7 @@
14
73
 
15
74
  - Raise errors on setup failure and logging with OmniAuth::Strategy::log method [\#10](https://github.com/ccrockett/omniauth-keycloak/pull/10) ([alexpetrov](https://github.com/alexpetrov))
16
75
  - Bump json from 2.1.0 to 2.3.1 [\#9](https://github.com/ccrockett/omniauth-keycloak/pull/9) ([dependabot[bot]](https://github.com/apps/dependabot))
76
+ - Bump rack from 2.2.2 to 2.2.3 [\#7](https://github.com/ccrockett/omniauth-keycloak/pull/7) ([dependabot[bot]](https://github.com/apps/dependabot))
17
77
 
18
78
  ## [v1.2.0](https://github.com/ccrockett/omniauth-keycloak/tree/v1.2.0) (2020-05-28)
19
79
 
@@ -21,7 +81,6 @@
21
81
 
22
82
  **Merged pull requests:**
23
83
 
24
- - Bump rack from 2.2.2 to 2.2.3 [\#7](https://github.com/ccrockett/omniauth-keycloak/pull/7) ([dependabot[bot]](https://github.com/apps/dependabot))
25
84
  - Bump activesupport from 6.0.1 to 6.0.3.1 [\#6](https://github.com/ccrockett/omniauth-keycloak/pull/6) ([dependabot[bot]](https://github.com/apps/dependabot))
26
85
  - Update rake requirement from ~\> 10.0 to ~\> 13.0 [\#4](https://github.com/ccrockett/omniauth-keycloak/pull/4) ([dependabot[bot]](https://github.com/apps/dependabot))
27
86
  - Bump rack from 2.0.7 to 2.0.8 [\#2](https://github.com/ccrockett/omniauth-keycloak/pull/2) ([dependabot[bot]](https://github.com/apps/dependabot))
data/Gemfile.lock CHANGED
@@ -1,9 +1,10 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- omniauth-keycloak (1.4.1)
4
+ omniauth-keycloak (1.4.2)
5
+ faraday
5
6
  json-jwt (~> 1.13.0)
6
- omniauth (~> 2.0.4)
7
+ omniauth (>= 2.0)
7
8
  omniauth-oauth2 (~> 1.7.1)
8
9
 
9
10
  GEM
data/README.md CHANGED
@@ -16,6 +16,15 @@ Or install it yourself as:
16
16
 
17
17
  $ gem install omniauth-keycloak
18
18
 
19
+ ## Use with Keycloak >= 17 (Quarkus distribution)
20
+ In version 17 of Keycloak, `/auth` was removed from the default context path. (See Issue [#29](https://github.com/ccrockett/omniauth-keycloak/issues/29))
21
+ In order to reduce breaking existing user's setup, this gem assumes `/auth` as the default context.
22
+ __So if you want to use Keycloak 17 or greater then you must do one of the following:__
23
+
24
+ 1. Pass in `--http-relative-path '/auth'` option with the keycloak start command
25
+ 2. Pass in a empty string for you base_url client_option:
26
+ `client_options: {base_url: '', site: 'https://example.keycloak-url.com', realm: 'example-realm'}`
27
+
19
28
  ## Usage
20
29
 
21
30
  `OmniAuth::Strategies::Keycloak` is simply a Rack middleware. Read the OmniAuth docs for detailed instructions: https://github.com/intridea/omniauth.
@@ -1,5 +1,5 @@
1
1
  module Omniauth
2
2
  module Keycloak
3
- VERSION = "1.4.1"
3
+ VERSION = "1.4.4"
4
4
  end
5
5
  end
@@ -31,7 +31,7 @@ module OmniAuth
31
31
  log :debug, "Going to get Keycloak configuration. URL: #{config_url}"
32
32
  response = Faraday.get config_url
33
33
  if (response.status == 200)
34
- json = MultiJson.load(response.body)
34
+ json = JSON.parse(response.body)
35
35
 
36
36
  @certs_endpoint = json["jwks_uri"]
37
37
  @userinfo_endpoint = json["userinfo_endpoint"]
@@ -47,7 +47,7 @@ module OmniAuth
47
47
  log :debug, "Going to get certificates. URL: #{@certs_endpoint}"
48
48
  certs = Faraday.get @certs_endpoint
49
49
  if (certs.status == 200)
50
- json = MultiJson.load(certs.body)
50
+ json = JSON.parse(certs.body)
51
51
  @certs = json["keys"]
52
52
  log :debug, "Successfully got certificate. Certificate length: #{@certs.length}"
53
53
  else
@@ -23,9 +23,10 @@ Gem::Specification.new do |spec|
23
23
  spec.require_paths = ["lib"]
24
24
 
25
25
 
26
- spec.add_dependency "omniauth", "~> 2.0.4"
26
+ spec.add_dependency "omniauth", ">= 2.0"
27
27
  spec.add_dependency "omniauth-oauth2", "~> 1.7.1"
28
28
  spec.add_dependency "json-jwt", "~> 1.13.0"
29
+ spec.add_dependency "faraday"
29
30
 
30
31
  spec.add_development_dependency "bundler", "~> 2.2"
31
32
  spec.add_development_dependency "rake", "~> 13.0"
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-keycloak
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.1
4
+ version: 1.4.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cameron Crockett
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-05-25 00:00:00.000000000 Z
11
+ date: 2022-07-25 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
- version: 2.0.4
19
+ version: '2.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: 2.0.4
26
+ version: '2.0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: omniauth-oauth2
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -52,6 +52,20 @@ dependencies:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: 1.13.0
55
+ - !ruby/object:Gem::Dependency
56
+ name: faraday
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :runtime
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
55
69
  - !ruby/object:Gem::Dependency
56
70
  name: bundler
57
71
  requirement: !ruby/object:Gem::Requirement