Class: Rack::OAuth2::Server::Token::Request
- Inherits:
-
Abstract::Request
- Object
- Request
- Abstract::Request
- Rack::OAuth2::Server::Token::Request
- Defined in:
- lib/rack/oauth2/server/token.rb
Direct Known Subclasses
AuthorizationCode::Request, ClientCredentials::Request, Extension::Example::Request, JWTBearer::Request, Password::Request, Rack::OAuth2::Server::Token::RefreshToken::Request, SAML2Bearer::Request
Instance Method Summary collapse
-
#initialize(env) ⇒ Request
constructor
A new instance of Request.
Methods inherited from Abstract::Request
Constructor Details
#initialize(env) ⇒ Request
Returns a new instance of Request.
49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/rack/oauth2/server/token.rb', line 49 def initialize(env) auth = Rack::Auth::Basic::Request.new(env) if auth.provided? && auth.basic? @client_id, @client_secret = auth.credentials super else super @client_secret = params['client_secret'] end @grant_type = params['grant_type'].to_s end |