Files

Merb::Authentication::Strategies::Basic::BasicAuth

Public Class Methods

new(request, params) click to toggle source
# File lib/merb-auth-more/strategies/basic/basic_auth.rb, line 40
def initialize(request, params)
  super
  @auth = Rack::Auth::Basic::Request.new(request.env)
end
realm() click to toggle source
# File lib/merb-auth-more/strategies/basic/basic_auth.rb, line 27
def self.realm
  @realm ||= "Application"
end

Public Instance Methods

realm() click to toggle source
# File lib/merb-auth-more/strategies/basic/basic_auth.rb, line 32
def realm
  @realm ||= self.class.realm
end
run!() click to toggle source
# File lib/merb-auth-more/strategies/basic/basic_auth.rb, line 15
def run!
  if basic_authentication?
    basic_authentication do |login, password|
      user = user_class.authenticate(login, password)
      unless user
        request_basic_auth!
      end
      user
    end
  end
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.