#!/usr/bin/ruby #encoding=utf-8 require 'jfoundry/signer' module JFoundry module Signature module Version include JFoundry::Signer def generate_signature secret_key, method, req return sign(secret_key, string_to_sign(method, req)) end def string_to_sign method, req str = [ method.downcase, req['content-md5'], req['content-type'], req['date'], req['path'] ].join("\n") end end end end