class RaptorIO::Protocol::HTTP::Request::Manipulators::Authenticators::Basic

Implements HTTP Basic authentication.

@author Tasos Laskos

Public Instance Methods

run() click to toggle source
# File lib/raptor-io/protocol/http/request/manipulators/authenticators/basic.rb, line 15
def run
  request.headers['Authorization'] =
      "Basic #{Base64.encode64("#{username}:#{password}").chomp}"
end

Private Instance Methods

password() click to toggle source
# File lib/raptor-io/protocol/http/request/manipulators/authenticators/basic.rb, line 26
def password
  options[:password]
end
username() click to toggle source
# File lib/raptor-io/protocol/http/request/manipulators/authenticators/basic.rb, line 22
def username
  options[:username]
end