prx_auth-rails 4.2.1 → 4.3.0

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: 1852c166da48f2df9481fa8d2343e8e5e378875cd8ceda9b1bb459a78ee91e3a
4
- data.tar.gz: b8cdc9d9ef469dbcb7b25ff606842763c3008fa8d33ed9291ad1729c821e6427
3
+ metadata.gz: 6b7949aca4f9d44ec4e43115fc0547dcc4f978ccbd47273581ecdd0c3d9944dd
4
+ data.tar.gz: 4269a31f563ef7cdbb075333ebe2cf56385eef73e6fd5aa48bc5fbd8dcf69471
5
5
  SHA512:
6
- metadata.gz: cfe2defaa2d06e944e4926a984140d47c1e7687976843d0c93f44133f6bea5fd7700317128dad8d150fb1cc424ace31700a528d1a24dc1be6b7fec7f8a698c11
7
- data.tar.gz: b72915c790ec4d918f388b626704a5996e9afa0c83a52b6d2a4c1d01f217a07c22fad448820b8fc80145a8ba04727e75080fce3a1266f45b8fa6d722e704c9a5
6
+ metadata.gz: '0206995f93f0b37563b3d3ad787c654dff2a7ef6545887a043eb65cb7befdfc05abfe10ef889b0b3dfe496112107010dfa5bcc249a1a05a33176abb582195c62'
7
+ data.tar.gz: ecedfd4de9cdd442f6482dc8cc89cea6c151ff26d958732f0141241ec29ab57f3a3f6f516d972584d627dc3bc70cbfdd1aaa31fa8d54dcf1ffb43b00e10fcee8
@@ -40,7 +40,7 @@ module PrxAuth::Rails
40
40
 
41
41
  def destroy
42
42
  sign_out_user
43
- redirect_to after_sign_out_path
43
+ redirect_to after_sign_out_path, allow_other_host: true
44
44
  end
45
45
 
46
46
  def auth_error
@@ -1 +1,3 @@
1
- Rails.application.config.assets.precompile << %w[prx_auth-rails_manifest.js]
1
+ if defined?(Rails.application.config.assets)
2
+ Rails.application.config.assets.precompile << %w[prx_auth-rails_manifest.js]
3
+ end
data/config/routes.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  PrxAuth::Rails::Engine.routes.draw do
2
2
  scope module: "prx_auth/rails" do
3
- resource "sessions", except: :index, defaults: {format: "html"} do
3
+ resource "sessions", defaults: {format: "html"} do
4
4
  get "auth_error", to: "sessions#auth_error"
5
5
  end
6
6
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module PrxAuth
4
4
  module Rails
5
- VERSION = "4.2.1"
5
+ VERSION = "4.3.0"
6
6
  end
7
7
  end
@@ -26,7 +26,7 @@ Gem::Specification.new do |spec|
26
26
  spec.add_development_dependency "guard"
27
27
  spec.add_development_dependency "guard-minitest"
28
28
  spec.add_development_dependency "m", "~> 1.5"
29
- spec.add_development_dependency "rails", "~> 6.1.0"
29
+ spec.add_development_dependency "rails", "~> 8.0.1"
30
30
  spec.add_development_dependency "pry"
31
31
  spec.add_development_dependency "sqlite3"
32
32
  spec.add_development_dependency "webmock"
@@ -1,7 +1,7 @@
1
1
  # Be sure to restart your server when you modify this file.
2
2
 
3
3
  # Version of your assets, change this if you want to expire all your assets.
4
- Rails.application.config.assets.version = "1.0"
4
+ # Rails.application.config.assets.version = "1.0"
5
5
 
6
6
  # Add additional assets to the asset load path.
7
7
  # Rails.application.config.assets.paths << Emoji.images_path
@@ -58,7 +58,7 @@ module PrxAuth::Rails
58
58
 
59
59
  assert session[@nonce_session_key].nil?
60
60
  assert response.code == "302"
61
- assert response.body.match?(/after-sign-in-path/)
61
+ assert response.headers["Location"].match?(/after-sign-in-path/)
62
62
  end
63
63
  end
64
64
  end
@@ -85,7 +85,7 @@ module PrxAuth::Rails
85
85
  session[@nonce_session_key] = "nonce-does-not-match"
86
86
  post :create, params: @token_params, format: :json
87
87
  assert response.code == "302"
88
- assert response.body.match(/auth_error\?error=verification_failed/)
88
+ assert response.headers["Location"].match(/auth_error\?error=verification_failed/)
89
89
  end
90
90
  end
91
91
 
@@ -109,7 +109,7 @@ module PrxAuth::Rails
109
109
  post :create, params: @token_params, format: :json
110
110
 
111
111
  assert response.code == "302"
112
- assert response.body.match?(/error=verification_failed/)
112
+ assert response.headers["Location"].match?(/error=verification_failed/)
113
113
  end
114
114
  end
115
115
  end
@@ -12,7 +12,7 @@ describe PrxAuth::Rails do
12
12
  end
13
13
 
14
14
  it "installs and configures prx_auth middleware" do
15
- mw = MiniTest::Mock.new
15
+ mw = Minitest::Mock.new
16
16
  mw.expect :insert_after, nil do |c1, c2, cert_location:, issuer:|
17
17
  assert_equal Rack::Head, c1
18
18
  assert_equal Rack::PrxAuth, c2
@@ -20,7 +20,7 @@ describe PrxAuth::Rails do
20
20
  assert_equal "id.prx.test", issuer
21
21
  end
22
22
 
23
- app = MiniTest::Mock.new
23
+ app = Minitest::Mock.new
24
24
  app.expect :middleware, mw
25
25
 
26
26
  subject.install_middleware!(app)
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prx_auth-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.1
4
+ version: 4.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Rhoden
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2023-08-29 00:00:00.000000000 Z
10
+ date: 2025-03-17 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: actionpack
@@ -114,14 +113,14 @@ dependencies:
114
113
  requirements:
115
114
  - - "~>"
116
115
  - !ruby/object:Gem::Version
117
- version: 6.1.0
116
+ version: 8.0.1
118
117
  type: :development
119
118
  prerelease: false
120
119
  version_requirements: !ruby/object:Gem::Requirement
121
120
  requirements:
122
121
  - - "~>"
123
122
  - !ruby/object:Gem::Version
124
- version: 6.1.0
123
+ version: 8.0.1
125
124
  - !ruby/object:Gem::Dependency
126
125
  name: pry
127
126
  requirement: !ruby/object:Gem::Requirement
@@ -287,7 +286,6 @@ homepage: https://github.com/PRX/prx_auth-rails
287
286
  licenses:
288
287
  - MIT
289
288
  metadata: {}
290
- post_install_message:
291
289
  rdoc_options: []
292
290
  require_paths:
293
291
  - lib
@@ -302,8 +300,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
302
300
  - !ruby/object:Gem::Version
303
301
  version: '0'
304
302
  requirements: []
305
- rubygems_version: 3.3.3
306
- signing_key:
303
+ rubygems_version: 3.6.2
307
304
  specification_version: 4
308
305
  summary: Rails integration for next generation PRX Authorization system.
309
306
  test_files: []