Class: Warden::OAuth2::Strategies::AccessingProtectedResource

Inherits:
Bearer
  • Object
show all
Defined in:
lib/warden/oauth2/strategies/accessing_protected_resource.rb

Instance Attribute Summary

Attributes inherited from Base

#error_description

Instance Method Summary collapse

Methods inherited from Bearer

#token_string, #token_string_from_header, #token_string_from_request_params

Methods inherited from Token

#error_status, #token, #token_string

Methods inherited from Base

#error_status, #store?

Instance Method Details

#authenticate!Object



11
12
13
14
# File 'lib/warden/oauth2/strategies/accessing_protected_resource.rb', line 11

def authenticate!
  self.error_description = 'Bearer Token is not provided'
  fail! 'token_required'
end

#valid?Boolean

Returns:

  • (Boolean)


7
8
9
# File 'lib/warden/oauth2/strategies/accessing_protected_resource.rb', line 7

def valid?
  !super
end