Method: ActionController::HttpAuthentication::Digest#encode_credentials
- Defined in:
- lib/action_controller/metal/http_authentication.rb
#encode_credentials(http_method, credentials, password, password_is_ha1) ⇒ Object
221 222 223 224 |
# File 'lib/action_controller/metal/http_authentication.rb', line 221 def encode_credentials(http_method, credentials, password, password_is_ha1) credentials[:response] = expected_response(http_method, credentials[:uri], credentials, password, password_is_ha1) "Digest " + credentials.sort_by {|x| x[0].to_s }.map {|v| "#{v[0]}='#{v[1]}'" }.join(', ') end |