Class: AuthRails::Configuration::Jwt

Inherits:
Object
  • Object
show all
Defined in:
lib/auth_rails/configuration/jwt.rb

Defined Under Namespace

Classes: AccessToken, RefreshToken

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.strategyObject

Returns the value of attribute strategy.



7
8
9
# File 'lib/auth_rails/configuration/jwt.rb', line 7

def strategy
  @strategy
end

Class Method Details

.access_token {|AccessToken| ... } ⇒ Object

Yields:



9
10
11
12
13
# File 'lib/auth_rails/configuration/jwt.rb', line 9

def access_token
  yield AccessToken

  AccessToken.algorithm ||= 'HS256'
end

.refresh_token {|RefreshToken| ... } ⇒ Object

Yields:



15
16
17
18
19
# File 'lib/auth_rails/configuration/jwt.rb', line 15

def refresh_token
  yield RefreshToken

  RefreshToken.cookie_key ||= :ref_tok
end