Module: Keyless
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/keyless.rb,
lib/keyless/jwt.rb,
lib/keyless/version.rb,
lib/keyless/configuration.rb,
lib/keyless/rsa_public_key.rb
Overview
The JWT authentication concern.
Defined Under Namespace
Classes: Configuration, Jwt, RsaPublicKey
Constant Summary collapse
- VERSION =
'1.0.2'
Class Attribute Summary collapse
-
.configuration ⇒ Configuration
Retrieve the current configuration object.
Class Method Summary collapse
-
.configure {|configuration| ... } ⇒ Object
Configure the concern by providing a block which takes care of this task.
-
.reset_configuration! ⇒ Object
Reset the current configuration with the default one.
Class Attribute Details
.configuration ⇒ Configuration
Retrieve the current configuration object.
29 30 31 |
# File 'lib/keyless.rb', line 29 def self.configuration @configuration ||= Configuration.new end |
Class Method Details
.configure {|configuration| ... } ⇒ Object
Configure the concern by providing a block which takes care of this task. Example:
Keyless.configure do |conf|
# conf.xyz = [..]
end
39 40 41 |
# File 'lib/keyless.rb', line 39 def self.configure yield(configuration) end |
.reset_configuration! ⇒ Object
Reset the current configuration with the default one.
44 45 46 |
# File 'lib/keyless.rb', line 44 def self.reset_configuration! self.configuration = Configuration.new end |