Module: JsonTokenAuthentication

Defined in:
lib/json_token_authentication.rb,
lib/json_token_authentication/utility.rb,
lib/json_token_authentication/version.rb,
lib/json_token_authentication/responder.rb,
lib/json_token_authentication/validator.rb,
lib/generators/json_token_authentication/install_generator.rb

Defined Under Namespace

Modules: Generators, Utility Classes: Responder, Validator

Constant Summary collapse

VERSION =
"0.1.0"

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.encoderObject

Returns the value of attribute encoder.



5
6
7
# File 'lib/json_token_authentication.rb', line 5

def encoder
  @encoder
end

.encoder_secretObject

Returns the value of attribute encoder_secret.



5
6
7
# File 'lib/json_token_authentication.rb', line 5

def encoder_secret
  @encoder_secret
end

.entity_class_nameObject

Returns the value of attribute entity_class_name.



5
6
7
# File 'lib/json_token_authentication.rb', line 5

def entity_class_name
  @entity_class_name
end

.entity_identifier_method_nameObject

Returns the value of attribute entity_identifier_method_name.



5
6
7
# File 'lib/json_token_authentication.rb', line 5

def entity_identifier_method_name
  @entity_identifier_method_name
end

.expiry_withinObject

Returns the value of attribute expiry_within.



5
6
7
# File 'lib/json_token_authentication.rb', line 5

def expiry_within
  @expiry_within
end

Class Method Details

.configure {|_self| ... } ⇒ Object

Yields:

  • (_self)

Yield Parameters:



12
13
14
# File 'lib/json_token_authentication.rb', line 12

def configure
  yield(self)
end

.max_expiry_timeObject



8
9
10
# File 'lib/json_token_authentication.rb', line 8

def max_expiry_time
  expiry_within.from_now.to_i
end