Sha256: a8e26463fd0173376e61361d0ccd14dc8202dbb6794d745c7e392387b1da3bf6

Contents?: true

Size: 754 Bytes

Versions: 2

Compression:

Stored size: 754 Bytes

Contents

require "azure/tables/auth/shared_key"

module Azure
  module Tables
    module Auth
      class SharedKeyLite < SharedKey
        # Public: The name of the strategy.
        #
        # Returns a String.
        def name
          "SharedKeyLite"
        end

        # Generate the string to sign.
        #
        # verb       - The HTTP request method.
        # uri        - The URI of the request we're signing.
        # headers    - A Hash of HTTP request headers.
        #
        # Returns a plain text string.
        def signable_string(method, uri, headers)
          [
            headers.fetch("Date") { headers.fetch("x-ms-date") },
            canonicalized_resource(uri)
          ].join("\n")
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
azure-0.1.1 lib/azure/tables/auth/shared_key_lite.rb
azure-0.1.0 lib/azure/tables/auth/shared_key_lite.rb