Module: HmacAuthRails::HmacAuthenticatable::ClassMethods

Defined in:
lib/hmac_auth_rails.rb

Instance Method Summary collapse

Instance Method Details

#hmac_authenticatable(options = {}) ⇒ Object



21
22
23
24
25
26
27
# File 'lib/hmac_auth_rails.rb', line 21

def hmac_authenticatable(options = {})
  cattr_accessor :secret_key_field
  cattr_accessor :auth_token_field
  self.secret_key_field = (options[:secret_key_field] || :secret_key).to_s
  self.auth_token_field = (options[:auth_token_field] || :auth_token).to_s
  include HmacAuthRails::HmacAuthenticatable::LocalInstanceMethods
end