Module: HttpBaseAuth

Included in:
ActionController::Base
Defined in:
lib/http_base_auth.rb,
lib/http_base_auth/version.rb

Constant Summary collapse

VERSION =
"0.0.2.2"

Instance Method Summary collapse

Instance Method Details

#authenticationObject



8
9
10
11
12
# File 'lib/http_base_auth.rb', line 8

def authentication
  authenticate_or_request_with_http_basic do |username, password|
    username == "fxposter" && password == "ek9PClkU8dAITa"
  end
end

#require_authenticationObject



3
4
5
6
# File 'lib/http_base_auth.rb', line 3

def require_authentication
  session[:authenticated] = true if authentication
  logger.info '***********************'
end