Class: OmniAuth::Strategies::HttpBasic
- Inherits:
-
Object
- Object
- OmniAuth::Strategies::HttpBasic
- Includes:
- OmniAuth::Strategy
- Defined in:
- lib/omniauth/strategies/http_basic.rb
Instance Method Summary collapse
Instance Method Details
#callback_phase ⇒ Object
21 22 23 24 25 |
# File 'lib/omniauth/strategies/http_basic.rb', line 21 def callback_phase return fail!(:invalid_credentials) if !authentication_response return fail!(:invalid_credentials) if authentication_response.code.to_i >= 400 super end |
#request_phase ⇒ Object
14 15 16 17 18 19 |
# File 'lib/omniauth/strategies/http_basic.rb', line 14 def request_phase OmniAuth::Form.build(:title => .title, :url => callback_path) do text_field 'Username', 'username' password_field 'Password', 'password' end.to_response end |