keyless 2.3.0 → 2.5.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: d12f8064aeb243a8080877c6435e950495041bde541bf333b716548c9ff7d61b
4
- data.tar.gz: 674b825647e89d2079e5fb7a1eabe670e91151a47ea577275e52c5fd9d91cace
3
+ metadata.gz: f07b02e8eeba997fbc4910c8ab6bd76f59061e636b2f6f62e49d8e86d8e6d96e
4
+ data.tar.gz: 7dc804516f699e7c03b8954617f04ebe5593f05e850a334a89e8963dc822c2c9
5
5
  SHA512:
6
- metadata.gz: faa90d0c79630233da270b0304feda76d5089d19428bc8229a5e2869fc6a405756a5b9fe009fbd7b8ffcf7e52c3cee69a3d6036eae2d9a53addcb49d3978235f
7
- data.tar.gz: 45cd81e55400160dea5ddc98b10b629436f395b5463c1b37aa9f15cccc1ea647821dd1811f19aaab643205d012cbf3abe07eef17bfd94952a32d45ddfe46674f
6
+ metadata.gz: 38dd52a272841b6969fb26b339245222a91f1be2e47256271c11796c08c5b0fa8b52d33d10acba3748b226c3269cdb7af9f1fc1be6c30903a46ad8a4d496fc07
7
+ data.tar.gz: 3af2b808fdd6fc4932ba1b1126b52991fe946c1a0838f4bc53cd923e33fe5bfbc193117ee667dbc95a31e1700fa434ca21ae57bb8ed1b502009c2d4c33eb9b45
@@ -20,10 +20,10 @@ jobs:
20
20
  steps:
21
21
  - uses: actions/checkout@v4
22
22
 
23
- - name: Install Ruby 3.2
23
+ - name: Install Ruby 3.3
24
24
  uses: ruby/setup-ruby@v1
25
25
  with:
26
- ruby-version: 3.2
26
+ ruby-version: 3.3
27
27
  bundler-cache: true
28
28
  rubygems: '3.6.9'
29
29
 
@@ -18,8 +18,8 @@ jobs:
18
18
  strategy:
19
19
  fail-fast: false
20
20
  matrix:
21
- ruby: ['3.2', '3.3', '3.4']
22
- rails: ['7.1', '7.2', '8.0', '8.1']
21
+ ruby: ['3.3', '3.4', '4.0']
22
+ rails: ['7.2', '8.0', '8.1']
23
23
  env:
24
24
  BUNDLE_GEMFILE: 'gemfiles/rails_${{ matrix.rails }}.gemfile'
25
25
  steps:
data/.rubocop.yml CHANGED
@@ -1,3 +1,7 @@
1
+ inherit_from:
2
+ - https://potpourri.hausgold.de/config/rubocop.yml
3
+ - https://potpourri.hausgold.de/config/rubocop-gem.yml
4
+
1
5
  plugins:
2
6
  - rubocop-rspec
3
7
  - rubocop-rails
@@ -5,58 +9,24 @@ plugins:
5
9
  Rails:
6
10
  Enabled: true
7
11
 
8
- Style/Documentation:
9
- Enabled: true
10
-
11
12
  AllCops:
12
13
  NewCops: enable
13
14
  SuggestExtensions: false
14
15
  DisplayCopNames: true
15
- TargetRubyVersion: 3.2
16
- TargetRailsVersion: 7.1
16
+ TargetRubyVersion: 3.3
17
+ TargetRailsVersion: 7.2
17
18
  Exclude:
18
19
  - bin/**/*
19
20
  - vendor/**/*
20
21
  - build/**/*
21
22
  - gemfiles/**/*
22
23
 
23
- Metrics/BlockLength:
24
- Exclude:
25
- - Rakefile
26
- - '*.gemspec'
27
- - spec/**/*.rb
28
- - '**/*.rake'
29
- - doc/**/*.rb
30
-
31
- # MFA is not yet enabled for our gems yet.
32
- Gemspec/RequireMFA:
33
- Enabled: false
34
-
35
- # We stay with the original Ruby Style Guide recommendation.
36
- Layout/LineLength:
37
- Max: 80
38
-
39
- # Document all the things.
40
- Style/DocumentationMethod:
41
- Enabled: true
42
- RequireForNonPublicMethods: true
43
-
44
24
  # It's a deliberate idiom in RSpec.
45
25
  # See: https://github.com/bbatsov/rubocop/issues/4222
46
26
  Lint/AmbiguousBlockAssociation:
47
27
  Exclude:
48
28
  - "spec/**/*"
49
29
 
50
- # Because +expect_any_instance_of().to have_received()+ is not
51
- # supported with the +with(hash_including)+ matchers
52
- RSpec/MessageSpies:
53
- EnforcedStyle: receive
54
-
55
- # Because nesting makes sense here to group the feature tests
56
- # more effective. This increases maintainability.
57
- RSpec/NestedGroups:
58
- Max: 4
59
-
60
30
  # Disable regular Rails spec paths.
61
31
  Rails/FilePath:
62
32
  Enabled: false
@@ -64,8 +34,3 @@ Rails/FilePath:
64
34
  # Because we just implemented the ActiveRecord API.
65
35
  Rails/SkipsModelValidations:
66
36
  Enabled: false
67
-
68
- # We use memoized helpers all over the place to construct inputs and output
69
- # which can be customized at nested contexts easily.
70
- RSpec/MultipleMemoizedHelpers:
71
- Enabled: false
data/Appraisals CHANGED
@@ -1,9 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- appraise 'rails-7.1' do
4
- gem 'activesupport', '~> 7.1.0'
5
- end
6
-
7
3
  appraise 'rails-7.2' do
8
4
  gem 'activesupport', '~> 7.2.0'
9
5
  end
data/CHANGELOG.md CHANGED
@@ -2,6 +2,15 @@
2
2
 
3
3
  * TODO: Replace this bullet point with an actual description of a change.
4
4
 
5
+ ### 2.5.0 (26 December 2025)
6
+
7
+ * Added Ruby 4.0 support ([#21](https://github.com/hausgold/keyless/pull/21))
8
+ * Dropped Ruby 3.2 and Rails 7.1 support ([#20](https://github.com/hausgold/keyless/pull/20))
9
+
10
+ ### 2.4.0 (19 December 2025)
11
+
12
+ * Migrated to a shared Rubocop configuration for HAUSGOLD gems ([#19](https://github.com/hausgold/keyless/pull/19))
13
+
5
14
  ### 2.3.0 (16 December 2025)
6
15
 
7
16
  * Switched from `httparty` to the `http` gem and added support for retries on
data/Dockerfile CHANGED
@@ -1,4 +1,4 @@
1
- FROM hausgold/ruby:3.2
1
+ FROM hausgold/ruby:3.3
2
2
  LABEL org.opencontainers.image.authors="containers@hausgold.de"
3
3
 
4
4
  # Update system gem
data/Envfile CHANGED
@@ -1,3 +1,4 @@
1
1
  LANG=en_US.UTF-8
2
2
  LANGUAGE=en_US.UTF-8
3
3
  LC_ALL=en_US.UTF-8
4
+ RUBOCOP_CACHE_ROOT=/app/tmp
data/Gemfile CHANGED
@@ -9,10 +9,10 @@ gemspec
9
9
 
10
10
  # Development dependencies
11
11
  gem 'appraisal', '~> 2.4'
12
- gem 'bundler', '~> 2.6'
12
+ gem 'bundler', '>= 2.6', '< 5'
13
13
  gem 'countless', '~> 2.2'
14
14
  gem 'guard-rspec', '~> 4.7'
15
- gem 'railties', '>= 7.1'
15
+ gem 'railties', '>= 7.2'
16
16
  gem 'rake', '~> 13.0'
17
17
  gem 'rspec', '~> 3.12'
18
18
  gem 'rubocop'
data/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2023 HAUSGOLD | talocasa GmbH
3
+ Copyright (c) 2025 HAUSGOLD | talocasa GmbH
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/Makefile CHANGED
@@ -83,7 +83,8 @@ all:
83
83
  install:
84
84
  # Install the dependencies
85
85
  @$(MKDIR) -p $(VENDOR_DIR)
86
- @$(call run-shell,$(BUNDLE) check || $(BUNDLE) install --path $(VENDOR_DIR))
86
+ @$(call run-shell,$(BUNDLE) config set --local path '$(VENDOR_DIR)')
87
+ @$(call run-shell,$(BUNDLE) check || $(BUNDLE) install)
87
88
  @$(call run-shell,$(BUNDLE) exec $(APPRAISAL) install)
88
89
 
89
90
  update:
data/README.md CHANGED
@@ -75,8 +75,8 @@ end
75
75
  ### RSA public key helper
76
76
 
77
77
  We provide a straightforward solution to deal with the provision of RSA public
78
- keys. Somethimes you want to distribute them by file to each machine and have
79
- a local access, and somethimes you provide an endpoint on your identity
78
+ keys. Sometimes you want to distribute them by file to each machine and have
79
+ a local access, and sometimes you provide an endpoint on your identity
80
80
  provider to fetch the RSA public key via HTTP/HTTPS. The `RsaPublicKey` class
81
81
  helps you to fulfill this task easily.
82
82
 
@@ -3,10 +3,10 @@
3
3
  source "https://rubygems.org"
4
4
 
5
5
  gem "appraisal", "~> 2.4"
6
- gem "bundler", "~> 2.6"
6
+ gem "bundler", ">= 2.6", "< 5"
7
7
  gem "countless", "~> 2.2"
8
8
  gem "guard-rspec", "~> 4.7"
9
- gem "railties", ">= 7.1"
9
+ gem "railties", ">= 7.2"
10
10
  gem "rake", "~> 13.0"
11
11
  gem "rspec", "~> 3.12"
12
12
  gem "rubocop"
@@ -3,10 +3,10 @@
3
3
  source "https://rubygems.org"
4
4
 
5
5
  gem "appraisal", "~> 2.4"
6
- gem "bundler", "~> 2.6"
6
+ gem "bundler", ">= 2.6", "< 5"
7
7
  gem "countless", "~> 2.2"
8
8
  gem "guard-rspec", "~> 4.7"
9
- gem "railties", ">= 7.1"
9
+ gem "railties", ">= 7.2"
10
10
  gem "rake", "~> 13.0"
11
11
  gem "rspec", "~> 3.12"
12
12
  gem "rubocop"
@@ -3,10 +3,10 @@
3
3
  source "https://rubygems.org"
4
4
 
5
5
  gem "appraisal", "~> 2.4"
6
- gem "bundler", "~> 2.6"
6
+ gem "bundler", ">= 2.6", "< 5"
7
7
  gem "countless", "~> 2.2"
8
8
  gem "guard-rspec", "~> 4.7"
9
- gem "railties", ">= 7.1"
9
+ gem "railties", ">= 7.2"
10
10
  gem "rake", "~> 13.0"
11
11
  gem "rspec", "~> 3.12"
12
12
  gem "rubocop"
data/keyless.gemspec CHANGED
@@ -33,9 +33,9 @@ Gem::Specification.new do |spec|
33
33
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
34
34
  spec.require_paths = ['lib']
35
35
 
36
- spec.required_ruby_version = '>= 3.2'
36
+ spec.required_ruby_version = '>= 3.3'
37
37
 
38
- spec.add_dependency 'activesupport', '>= 7.1'
38
+ spec.add_dependency 'activesupport', '>= 7.2'
39
39
  spec.add_dependency 'http', '~> 5.3'
40
40
  spec.add_dependency 'jwt', '>= 2.6'
41
41
  spec.add_dependency 'mutex_m', '>= 0.3'
data/lib/keyless/jwt.rb CHANGED
@@ -51,7 +51,7 @@ module Keyless
51
51
  payload.typ == 'refresh'
52
52
  end
53
53
 
54
- # Retrives the expiration date from the payload when set.
54
+ # Retrieves the expiration date from the payload when set.
55
55
  #
56
56
  # @return [nil|ActiveSupport::TimeWithZone] The expiration date
57
57
  def expires_at
@@ -3,7 +3,7 @@
3
3
  # The gem version details.
4
4
  module Keyless
5
5
  # The version of the +keyless+ gem
6
- VERSION = '2.3.0'
6
+ VERSION = '2.5.0'
7
7
 
8
8
  class << self
9
9
  # Returns the version of gem as a string.
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: keyless
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.0
4
+ version: 2.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hermann Mayer
@@ -17,14 +17,14 @@ dependencies:
17
17
  requirements:
18
18
  - - ">="
19
19
  - !ruby/object:Gem::Version
20
- version: '7.1'
20
+ version: '7.2'
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - ">="
26
26
  - !ruby/object:Gem::Version
27
- version: '7.1'
27
+ version: '7.2'
28
28
  - !ruby/object:Gem::Dependency
29
29
  name: http
30
30
  requirement: !ruby/object:Gem::Requirement
@@ -144,8 +144,6 @@ files:
144
144
  - config/docker/.inputrc
145
145
  - doc/assets/project.svg
146
146
  - docker-compose.yml
147
- - gemfiles/rails_6.1.gemfile
148
- - gemfiles/rails_7.1.gemfile
149
147
  - gemfiles/rails_7.2.gemfile
150
148
  - gemfiles/rails_8.0.gemfile
151
149
  - gemfiles/rails_8.1.gemfile
@@ -170,7 +168,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
170
168
  requirements:
171
169
  - - ">="
172
170
  - !ruby/object:Gem::Version
173
- version: '3.2'
171
+ version: '3.3'
174
172
  required_rubygems_version: !ruby/object:Gem::Requirement
175
173
  requirements:
176
174
  - - ">="
@@ -1,23 +0,0 @@
1
- # This file was generated by Appraisal
2
-
3
- source "https://rubygems.org"
4
-
5
- gem "appraisal", "~> 2.4"
6
- gem "bundler", "~> 2.3"
7
- gem "countless", "~> 1.1"
8
- gem "guard-rspec", "~> 4.7"
9
- gem "railties", ">= 6.1"
10
- gem "rake", "~> 13.0"
11
- gem "rspec", "~> 3.12"
12
- gem "rubocop"
13
- gem "rubocop-rails"
14
- gem "rubocop-rspec"
15
- gem "simplecov", ">= 0.22"
16
- gem "timecop", ">= 0.9.6"
17
- gem "vcr", "~> 6.0"
18
- gem "webmock", "~> 3.18"
19
- gem "yard", ">= 0.9.28"
20
- gem "yard-activesupport-concern", ">= 0.0.1"
21
- gem "activesupport", "~> 6.1.0"
22
-
23
- gemspec path: "../"
@@ -1,23 +0,0 @@
1
- # This file was generated by Appraisal
2
-
3
- source "https://rubygems.org"
4
-
5
- gem "appraisal", "~> 2.4"
6
- gem "bundler", "~> 2.6"
7
- gem "countless", "~> 2.2"
8
- gem "guard-rspec", "~> 4.7"
9
- gem "railties", ">= 7.1"
10
- gem "rake", "~> 13.0"
11
- gem "rspec", "~> 3.12"
12
- gem "rubocop"
13
- gem "rubocop-rails"
14
- gem "rubocop-rspec"
15
- gem "simplecov", ">= 0.22"
16
- gem "timecop", ">= 0.9.6"
17
- gem "vcr", "~> 6.0"
18
- gem "webmock", "~> 3.18"
19
- gem "yard", ">= 0.9.28"
20
- gem "yard-activesupport-concern", ">= 0.0.1"
21
- gem "activesupport", "~> 7.1.0"
22
-
23
- gemspec path: "../"