gamora 0.9.0 → 0.10.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 +4 -4
- data/README.md +32 -0
- data/lib/gamora/authentication/base.rb +1 -0
- data/lib/gamora/user.rb +1 -0
- data/lib/gamora/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 62fcee90396875db0256e297c90dda80546c3268cfecdd4f0e53b7f3c4e68ba8
|
4
|
+
data.tar.gz: '093571bfd8706530b474c1bf9d046db56cd5a0a53820546afc88f274f528a6a6'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: '0888b96495e6e55f0cc49512a9ec0c8d73d67e839a2dae0207bdb81728032e46436b8a3ce0cdf1daa1352d5ae849a4a723a28fe29d9c6c615b5efbf6dd33cc8c'
|
7
|
+
data.tar.gz: 3c00a26cce8ad257170853ffc0c6c9fd3a355372f401881b470cb9cdb86d0a94e43b401e5ac94024979faa3636969fc33ec7429f033287d006a6ff5bfa8360aa
|
data/README.md
CHANGED
@@ -115,6 +115,38 @@ Optionally, if you want to do something different when authentication
|
|
115
115
|
fails, you just need to override the `user_authentication_failed!`
|
116
116
|
method in you controller and customize it as you wish.
|
117
117
|
|
118
|
+
## Cross-Client Identity
|
119
|
+
|
120
|
+
By default, gamora will accept only access tokens that were generating
|
121
|
+
with the `client_id` in the configuration. If access tokens coming from
|
122
|
+
other clients have to be accepted, make sure to add their client ids to
|
123
|
+
the `whitelisted_clients` config option.
|
124
|
+
|
125
|
+
```ruby
|
126
|
+
Gamora.setup do |config|
|
127
|
+
...
|
128
|
+
|
129
|
+
config.whitelisted_clients = ["OTHER_CLIENT_ID"]
|
130
|
+
end
|
131
|
+
```
|
132
|
+
|
133
|
+
## Caching
|
134
|
+
|
135
|
+
In order to avoid performing requests to the IDP on each request in the
|
136
|
+
application, it is possible to set a caching time for introspection and
|
137
|
+
userinfo endpoints. Make sure to not have a too long expiration time for
|
138
|
+
`introspect_cache_expires_in` but not too short to impact the application
|
139
|
+
performance, it is a balance.
|
140
|
+
|
141
|
+
```ruby
|
142
|
+
Gamora.setup do |config|
|
143
|
+
...
|
144
|
+
|
145
|
+
config.userinfo_cache_expires_in = 10.minute
|
146
|
+
config.introspect_cache_expires_in = 5.seconds
|
147
|
+
end
|
148
|
+
```
|
149
|
+
|
118
150
|
## Development
|
119
151
|
|
120
152
|
After checking out the repo, run `bin/setup` to install dependencies. Then,
|
data/lib/gamora/user.rb
CHANGED
data/lib/gamora/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gamora
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.10.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alejandro Gutiérrez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-12-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: oauth2
|