Class: Warden::OAuth2::Strategies::ClientCredentials

Inherits:
Client
  • Object
show all
Defined in:
lib/warden/oauth2/strategies/client_credentials.rb

Instance Attribute Summary

Attributes inherited from Client

#client, #client_id, #client_secret

Attributes inherited from Base

#error_description

Instance Method Summary collapse

Methods inherited from Client

#authenticate!, #client_authenticated, #client_from_http_basic, #client_from_request_params, #error_status, #public_client?

Methods inherited from Base

#error_status, #store?

Instance Method Details

#modelObject



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

def model
  Warden::OAuth2.config.client_credentials_model
end

#valid?Boolean

Returns:

  • (Boolean)


10
11
12
# File 'lib/warden/oauth2/strategies/client_credentials.rb', line 10

def valid?
  params['grant_type'] == 'client_credentials'
end