Permalink
Browse files

Slighly clearer name for the auth header signing method

  • Loading branch information...
1 parent 85f4a3e commit 9fa43de083b01ef091ac198b4f5d8c6405b2557c @joho joho committed Feb 9, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/best3.rb
View
@@ -36,11 +36,11 @@ def perform_request(request_method, uri, headers, body = nil)
def make_headers(request_method, uri, headers, body = nil)
headers['Date'] = Time.now.rfc822
- headers['Authorization'] = make_auth(request_method, uri, headers, body)
+ headers['Authorization'] = signed_authorisation_header(request_method, uri, headers, body)
headers
end
- def make_auth(request_method, uri, headers, body = nil)
+ def signed_authorisation_header(request_method, uri, headers, body = nil)
# auth key thingo stolen from aws::s3 library, lol.
signed_request = [OpenSSL::HMAC.digest(OpenSSL::Digest::Digest.new('sha1'), @secret, request_info_for_signing(request_method, uri, headers))].pack('m').strip

0 comments on commit 9fa43de

Please sign in to comment.