jay_doubleu_tee 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +11 -0
- data/.rspec +3 -0
- data/.travis.yml +6 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +12 -0
- data/Gemfile.lock +65 -0
- data/LICENSE.txt +21 -0
- data/README.md +118 -0
- data/Rakefile +6 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/jay_double_uti-0.1.0.gem +0 -0
- data/jay_doubleu_tee.gemspec +34 -0
- data/lib/jay_doubleu_tee/auth.rb +5 -0
- data/lib/jay_doubleu_tee/authorization.rb +23 -0
- data/lib/jay_doubleu_tee/decoder.rb +44 -0
- data/lib/jay_doubleu_tee/prepare_signature.rb +16 -0
- data/lib/jay_doubleu_tee/version.rb +3 -0
- data/lib/jay_doubleu_tee.rb +23 -0
- metadata +123 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 2e0f1808e15a6fb71cc47526d3de8484372e5c9f5f32da231fec7219e799e99e
|
4
|
+
data.tar.gz: 7ca92e01391c1eccae6ae8b682ccf8b36e6a0c064f64360659affed49d3922a0
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 9bbe5175ffd3190eb9846b3f660c5a912fda3c22eaaa086d39715b2cabd1336fb2b9e14ece3cc301284e425e995b5c34fcf090f10be0ab256f67034c6c05db1c
|
7
|
+
data.tar.gz: 64b240f9370f3f3489703465ae4ed2c92927234d18be7313cf1b7d5d75ce0bf7dd90996d69f5aa6dc68f80b9fdf339b4dad5d10879b6fd7031894fc640a49256
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,74 @@
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
2
|
+
|
3
|
+
## Our Pledge
|
4
|
+
|
5
|
+
In the interest of fostering an open and welcoming environment, we as
|
6
|
+
contributors and maintainers pledge to making participation in our project and
|
7
|
+
our community a harassment-free experience for everyone, regardless of age, body
|
8
|
+
size, disability, ethnicity, gender identity and expression, level of experience,
|
9
|
+
nationality, personal appearance, race, religion, or sexual identity and
|
10
|
+
orientation.
|
11
|
+
|
12
|
+
## Our Standards
|
13
|
+
|
14
|
+
Examples of behavior that contributes to creating a positive environment
|
15
|
+
include:
|
16
|
+
|
17
|
+
* Using welcoming and inclusive language
|
18
|
+
* Being respectful of differing viewpoints and experiences
|
19
|
+
* Gracefully accepting constructive criticism
|
20
|
+
* Focusing on what is best for the community
|
21
|
+
* Showing empathy towards other community members
|
22
|
+
|
23
|
+
Examples of unacceptable behavior by participants include:
|
24
|
+
|
25
|
+
* The use of sexualized language or imagery and unwelcome sexual attention or
|
26
|
+
advances
|
27
|
+
* Trolling, insulting/derogatory comments, and personal or political attacks
|
28
|
+
* Public or private harassment
|
29
|
+
* Publishing others' private information, such as a physical or electronic
|
30
|
+
address, without explicit permission
|
31
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
32
|
+
professional setting
|
33
|
+
|
34
|
+
## Our Responsibilities
|
35
|
+
|
36
|
+
Project maintainers are responsible for clarifying the standards of acceptable
|
37
|
+
behavior and are expected to take appropriate and fair corrective action in
|
38
|
+
response to any instances of unacceptable behavior.
|
39
|
+
|
40
|
+
Project maintainers have the right and responsibility to remove, edit, or
|
41
|
+
reject comments, commits, code, wiki edits, issues, and other contributions
|
42
|
+
that are not aligned to this Code of Conduct, or to ban temporarily or
|
43
|
+
permanently any contributor for other behaviors that they deem inappropriate,
|
44
|
+
threatening, offensive, or harmful.
|
45
|
+
|
46
|
+
## Scope
|
47
|
+
|
48
|
+
This Code of Conduct applies both within project spaces and in public spaces
|
49
|
+
when an individual is representing the project or its community. Examples of
|
50
|
+
representing a project or community include using an official project e-mail
|
51
|
+
address, posting via an official social media account, or acting as an appointed
|
52
|
+
representative at an online or offline event. Representation of a project may be
|
53
|
+
further defined and clarified by project maintainers.
|
54
|
+
|
55
|
+
## Enforcement
|
56
|
+
|
57
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
58
|
+
reported by contacting the project team at sebastian@driggl.com. All
|
59
|
+
complaints will be reviewed and investigated and will result in a response that
|
60
|
+
is deemed necessary and appropriate to the circumstances. The project team is
|
61
|
+
obligated to maintain confidentiality with regard to the reporter of an incident.
|
62
|
+
Further details of specific enforcement policies may be posted separately.
|
63
|
+
|
64
|
+
Project maintainers who do not follow or enforce the Code of Conduct in good
|
65
|
+
faith may face temporary or permanent repercussions as determined by other
|
66
|
+
members of the project's leadership.
|
67
|
+
|
68
|
+
## Attribution
|
69
|
+
|
70
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
71
|
+
available at [https://contributor-covenant.org/version/1/4][version]
|
72
|
+
|
73
|
+
[homepage]: https://contributor-covenant.org
|
74
|
+
[version]: https://contributor-covenant.org/version/1/4/
|
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,65 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
jay_doubleu_tee (0.1.0)
|
5
|
+
dry-configurable
|
6
|
+
dry-effects
|
7
|
+
dry-monads
|
8
|
+
jwt
|
9
|
+
|
10
|
+
GEM
|
11
|
+
remote: https://rubygems.org/
|
12
|
+
specs:
|
13
|
+
concurrent-ruby (1.1.9)
|
14
|
+
diff-lcs (1.4.4)
|
15
|
+
dry-configurable (0.13.0)
|
16
|
+
concurrent-ruby (~> 1.0)
|
17
|
+
dry-core (~> 0.6)
|
18
|
+
dry-container (0.9.0)
|
19
|
+
concurrent-ruby (~> 1.0)
|
20
|
+
dry-configurable (~> 0.13, >= 0.13.0)
|
21
|
+
dry-core (0.7.1)
|
22
|
+
concurrent-ruby (~> 1.0)
|
23
|
+
dry-effects (0.2.0)
|
24
|
+
concurrent-ruby (~> 1.0)
|
25
|
+
dry-container (~> 0.7, >= 0.7.2)
|
26
|
+
dry-core (~> 0.5, >= 0.5)
|
27
|
+
dry-inflector (~> 0.1, >= 0.1.2)
|
28
|
+
dry-initializer (~> 3.0)
|
29
|
+
dry-inflector (0.2.1)
|
30
|
+
dry-initializer (3.0.4)
|
31
|
+
dry-monads (1.4.0)
|
32
|
+
concurrent-ruby (~> 1.0)
|
33
|
+
dry-core (~> 0.7)
|
34
|
+
ffi (1.15.4)
|
35
|
+
jwt (2.3.0)
|
36
|
+
rack (2.2.3)
|
37
|
+
rake (12.3.3)
|
38
|
+
rbnacl (7.1.1)
|
39
|
+
ffi
|
40
|
+
rspec (3.10.0)
|
41
|
+
rspec-core (~> 3.10.0)
|
42
|
+
rspec-expectations (~> 3.10.0)
|
43
|
+
rspec-mocks (~> 3.10.0)
|
44
|
+
rspec-core (3.10.1)
|
45
|
+
rspec-support (~> 3.10.0)
|
46
|
+
rspec-expectations (3.10.1)
|
47
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
48
|
+
rspec-support (~> 3.10.0)
|
49
|
+
rspec-mocks (3.10.2)
|
50
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
51
|
+
rspec-support (~> 3.10.0)
|
52
|
+
rspec-support (3.10.3)
|
53
|
+
|
54
|
+
PLATFORMS
|
55
|
+
ruby
|
56
|
+
|
57
|
+
DEPENDENCIES
|
58
|
+
jay_doubleu_tee!
|
59
|
+
rack
|
60
|
+
rake (~> 12.0)
|
61
|
+
rbnacl
|
62
|
+
rspec (~> 3.0)
|
63
|
+
|
64
|
+
BUNDLED WITH
|
65
|
+
2.1.4
|
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2021 Sebastian Wilgosz
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,118 @@
|
|
1
|
+
# JayDoubleuTee
|
2
|
+
|
3
|
+
A JWT authorization middleware for any web application.
|
4
|
+
|
5
|
+
JayDoubleuTee is inspired by [Hanami philosophy](https://hanamirb.org) to build components that are highly reusable, and compatible with any ruby application.
|
6
|
+
|
7
|
+
JayDoubleuTee is fully compatible with RACK, so it is with Hanami, Rails, Sinatra, Roda, and whatever else you can think about.
|
8
|
+
|
9
|
+
## Installation
|
10
|
+
|
11
|
+
Add this line to your application's Gemfile:
|
12
|
+
|
13
|
+
```ruby
|
14
|
+
gem 'jay_doubleu_tee'
|
15
|
+
```
|
16
|
+
|
17
|
+
And then execute:
|
18
|
+
|
19
|
+
$ bundle install
|
20
|
+
|
21
|
+
Or install it yourself as:
|
22
|
+
|
23
|
+
$ gem install jay_doubleu_tee
|
24
|
+
|
25
|
+
## Usage
|
26
|
+
|
27
|
+
### Plain ruby Rack application
|
28
|
+
|
29
|
+
```ruby
|
30
|
+
require "jay_doubleu_tee"
|
31
|
+
|
32
|
+
class App
|
33
|
+
include JayDoubleuTee::Auth
|
34
|
+
|
35
|
+
def call(env)
|
36
|
+
status, body =
|
37
|
+
if auth.success?
|
38
|
+
[200, ["Hello, World!\n#{auth.value!}"]]
|
39
|
+
else
|
40
|
+
[401, [{ error: auth.failure }.to_json]]
|
41
|
+
end
|
42
|
+
|
43
|
+
[status, headers, body]
|
44
|
+
end
|
45
|
+
|
46
|
+
private
|
47
|
+
|
48
|
+
def headers
|
49
|
+
{ 'Content-Type' => 'application/json' }
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
53
|
+
use JayDoubleuTee::Authentication
|
54
|
+
|
55
|
+
run App.new
|
56
|
+
```
|
57
|
+
|
58
|
+
### Hanami 2.0
|
59
|
+
|
60
|
+
```ruby
|
61
|
+
# config.ru
|
62
|
+
|
63
|
+
require "jay_doubleu_tee"
|
64
|
+
use JayDoubleuTee::Authentication
|
65
|
+
```
|
66
|
+
|
67
|
+
### Rails
|
68
|
+
|
69
|
+
```ruby
|
70
|
+
# config.ru
|
71
|
+
|
72
|
+
require "jay_doubleu_tee"
|
73
|
+
use JayDoubleuTee::Authentication
|
74
|
+
```
|
75
|
+
|
76
|
+
#### Supported algorithms
|
77
|
+
|
78
|
+
JayDoubleuTee does not use any encryption algoritym by default. 'none' is set.
|
79
|
+
|
80
|
+
Below are listed all supported algoritms at the moment.
|
81
|
+
|
82
|
+
```ruby
|
83
|
+
%w[none HS256 RS256 prime256v1 ES256 ED25519 PS256]
|
84
|
+
```
|
85
|
+
|
86
|
+
For more info about each of them refer to [jwt documentation](https://github.com/jwt/ruby-jwt#algorithms-and-usage)
|
87
|
+
|
88
|
+
### Configuration
|
89
|
+
|
90
|
+
To set encryption algorithm, you can configure
|
91
|
+
|
92
|
+
```ruby
|
93
|
+
JayDoubleuTee.configure do |config|
|
94
|
+
config.algorithm = 'RS256'
|
95
|
+
config.secret = ENV['PUBLIC_KEY']
|
96
|
+
end
|
97
|
+
```
|
98
|
+
|
99
|
+
Again, for information how to generate private and public keys, [jwt documentation](https://github.com/jwt/ruby-jwt#algorithms-and-usage) or check out the [spec files](https://github.com/hanamimastery/jay_doubleu_tee/tree/master/spec/jay_doubleu_tee/decoder_spec.rb)
|
100
|
+
|
101
|
+
## Development
|
102
|
+
|
103
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
104
|
+
|
105
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
106
|
+
|
107
|
+
## Contributing
|
108
|
+
|
109
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/hanamimastery/jay_doubleu_tee. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/hanamimastery/jay_doubleu_tee/blob/master/CODE_OF_CONDUCT.md).
|
110
|
+
|
111
|
+
|
112
|
+
## License
|
113
|
+
|
114
|
+
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
|
115
|
+
|
116
|
+
## Code of Conduct
|
117
|
+
|
118
|
+
Everyone interacting in the JayDoubleuTee project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/jay_doubleu_tee/blob/master/CODE_OF_CONDUCT.md).
|
data/Rakefile
ADDED
data/bin/console
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require "bundler/setup"
|
4
|
+
require "jay_doubleu_tee"
|
5
|
+
|
6
|
+
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
+
# with your gem easier. You can also use a different console, if you like.
|
8
|
+
|
9
|
+
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
+
# require "pry"
|
11
|
+
# Pry.start
|
12
|
+
|
13
|
+
require "irb"
|
14
|
+
IRB.start(__FILE__)
|
data/bin/setup
ADDED
Binary file
|
@@ -0,0 +1,34 @@
|
|
1
|
+
require_relative 'lib/jay_doubleu_tee/version'
|
2
|
+
|
3
|
+
Gem::Specification.new do |spec|
|
4
|
+
spec.name = "jay_doubleu_tee"
|
5
|
+
spec.version = JayDoubleuTee::VERSION
|
6
|
+
spec.authors = ["Sebastian Wilgosz"]
|
7
|
+
spec.email = ["sebastian@hanamimastery.com"]
|
8
|
+
|
9
|
+
spec.summary = %q{A JWT authorization solution for any ruby web app.}
|
10
|
+
spec.description = %q{JayDoubleuTee is a simple but powerful middleware for authorising endpoints in any ruby application. Uses dry-effects and jwt under the hood. }
|
11
|
+
spec.homepage = "https://github.com/hanamimastery/jay_doubleu_tee"
|
12
|
+
spec.license = "MIT"
|
13
|
+
spec.required_ruby_version = Gem::Requirement.new(">= 2.3.0")
|
14
|
+
|
15
|
+
spec.metadata["allowed_push_host"] = "https://rubygems.org"
|
16
|
+
|
17
|
+
spec.metadata["homepage_uri"] = spec.homepage
|
18
|
+
spec.metadata["source_code_uri"] = "https://github.com/hanamimastery/jay_doubleu_tee"
|
19
|
+
spec.metadata["changelog_uri"] = "https://github.com/hanamimastery/jay_doubleu_tee/tree/master/CHANGELOG.md"
|
20
|
+
|
21
|
+
# Specify which files should be added to the gem when it is released.
|
22
|
+
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
23
|
+
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
24
|
+
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
25
|
+
end
|
26
|
+
spec.bindir = "exe"
|
27
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
28
|
+
spec.require_paths = ["lib"]
|
29
|
+
|
30
|
+
spec.add_dependency "jwt"
|
31
|
+
spec.add_dependency "dry-effects"
|
32
|
+
spec.add_dependency "dry-monads"
|
33
|
+
spec.add_dependency "dry-configurable"
|
34
|
+
end
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "dry/effects"
|
4
|
+
require "jay_doubleu_tee/decoder"
|
5
|
+
|
6
|
+
module JayDoubleuTee
|
7
|
+
class Authorization
|
8
|
+
include Dry::Effects::Handler.Reader(:auth)
|
9
|
+
|
10
|
+
attr_reader :decoder
|
11
|
+
|
12
|
+
def initialize(app)
|
13
|
+
@app = app
|
14
|
+
@decoder = Decoder.new
|
15
|
+
end
|
16
|
+
|
17
|
+
def call(env)
|
18
|
+
with_auth(decoder.call(env["HTTP_AUTHORIZATION"])) do
|
19
|
+
@app.call(env)
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,44 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "jwt"
|
4
|
+
require "dry/monads"
|
5
|
+
require "jay_doubleu_tee/prepare_signature"
|
6
|
+
|
7
|
+
module JayDoubleuTee
|
8
|
+
|
9
|
+
class Decoder
|
10
|
+
include Dry::Monads[:result]
|
11
|
+
|
12
|
+
InvalidTokenError = Class.new(StandardError)
|
13
|
+
|
14
|
+
def call(given)
|
15
|
+
# Set password to nil and validation to false otherwise this won't work
|
16
|
+
token = extract_token(given)
|
17
|
+
res = JWT.decode token, signature, verify?, { algorithm: algorithm }
|
18
|
+
Success(res[0]) # hides information about chosen algorithm and returns only payload
|
19
|
+
rescue JWT::DecodeError
|
20
|
+
Failure(InvalidTokenError.new("Unauthorized. Token invalid"))
|
21
|
+
end
|
22
|
+
|
23
|
+
private
|
24
|
+
|
25
|
+
def algorithm
|
26
|
+
JayDoubleuTee.config.algorithm
|
27
|
+
end
|
28
|
+
|
29
|
+
def verify?
|
30
|
+
algorithm != "none"
|
31
|
+
end
|
32
|
+
|
33
|
+
def signature
|
34
|
+
PrepareSignature.new.call(
|
35
|
+
algorithm: algorithm,
|
36
|
+
secret: JayDoubleuTee.config.secret
|
37
|
+
)
|
38
|
+
end
|
39
|
+
|
40
|
+
def extract_token(given)
|
41
|
+
given.to_s.gsub("Bearer ", "")
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
@@ -0,0 +1,16 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "jwt"
|
4
|
+
|
5
|
+
module JayDoubleuTee
|
6
|
+
class PrepareSignature
|
7
|
+
def call(algorithm:, secret:)
|
8
|
+
return OpenSSL::PKey::RSA.new(secret) if algorithm == "RS256"
|
9
|
+
return OpenSSL::PKey::EC.new(secret) if algorithm == "ES256"
|
10
|
+
return RbNaCl::Signatures::Ed25519::VerifyKey.new(secret) if algorithm == "ED25519"
|
11
|
+
return OpenSSL::PKey::RSA.new(secret) if algorithm == "PS256"
|
12
|
+
|
13
|
+
secret
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "dry-configurable"
|
4
|
+
|
5
|
+
require "jay_doubleu_tee/version"
|
6
|
+
require "jay_doubleu_tee/authorization"
|
7
|
+
require "jay_doubleu_tee/auth"
|
8
|
+
|
9
|
+
module JayDoubleuTee
|
10
|
+
class Error < StandardError; end
|
11
|
+
ConfigurationError = Class.new(Error)
|
12
|
+
|
13
|
+
ALGORITHMS = %w[none HS256 RS256 prime256v1 ES256 ED25519 PS256]
|
14
|
+
|
15
|
+
extend Dry::Configurable
|
16
|
+
|
17
|
+
setting :algorithm, default: 'none' do |value|
|
18
|
+
raise ConfigurationError, "Unsupported algorithm." unless ALGORITHMS.include?(value)
|
19
|
+
value
|
20
|
+
end
|
21
|
+
|
22
|
+
setting :secret, default: nil
|
23
|
+
end
|
metadata
ADDED
@@ -0,0 +1,123 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: jay_doubleu_tee
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Sebastian Wilgosz
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2021-12-12 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: jwt
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: dry-effects
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: dry-monads
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: dry-configurable
|
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'
|
69
|
+
description: 'JayDoubleuTee is a simple but powerful middleware for authorising endpoints
|
70
|
+
in any ruby application. Uses dry-effects and jwt under the hood. '
|
71
|
+
email:
|
72
|
+
- sebastian@hanamimastery.com
|
73
|
+
executables: []
|
74
|
+
extensions: []
|
75
|
+
extra_rdoc_files: []
|
76
|
+
files:
|
77
|
+
- ".gitignore"
|
78
|
+
- ".rspec"
|
79
|
+
- ".travis.yml"
|
80
|
+
- CODE_OF_CONDUCT.md
|
81
|
+
- Gemfile
|
82
|
+
- Gemfile.lock
|
83
|
+
- LICENSE.txt
|
84
|
+
- README.md
|
85
|
+
- Rakefile
|
86
|
+
- bin/console
|
87
|
+
- bin/setup
|
88
|
+
- jay_double_uti-0.1.0.gem
|
89
|
+
- jay_doubleu_tee.gemspec
|
90
|
+
- lib/jay_doubleu_tee.rb
|
91
|
+
- lib/jay_doubleu_tee/auth.rb
|
92
|
+
- lib/jay_doubleu_tee/authorization.rb
|
93
|
+
- lib/jay_doubleu_tee/decoder.rb
|
94
|
+
- lib/jay_doubleu_tee/prepare_signature.rb
|
95
|
+
- lib/jay_doubleu_tee/version.rb
|
96
|
+
homepage: https://github.com/hanamimastery/jay_doubleu_tee
|
97
|
+
licenses:
|
98
|
+
- MIT
|
99
|
+
metadata:
|
100
|
+
allowed_push_host: https://rubygems.org
|
101
|
+
homepage_uri: https://github.com/hanamimastery/jay_doubleu_tee
|
102
|
+
source_code_uri: https://github.com/hanamimastery/jay_doubleu_tee
|
103
|
+
changelog_uri: https://github.com/hanamimastery/jay_doubleu_tee/tree/master/CHANGELOG.md
|
104
|
+
post_install_message:
|
105
|
+
rdoc_options: []
|
106
|
+
require_paths:
|
107
|
+
- lib
|
108
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
109
|
+
requirements:
|
110
|
+
- - ">="
|
111
|
+
- !ruby/object:Gem::Version
|
112
|
+
version: 2.3.0
|
113
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - ">="
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '0'
|
118
|
+
requirements: []
|
119
|
+
rubygems_version: 3.1.4
|
120
|
+
signing_key:
|
121
|
+
specification_version: 4
|
122
|
+
summary: A JWT authorization solution for any ruby web app.
|
123
|
+
test_files: []
|