def s3_upload_signature
      signature = OpenSSL::HMAC.digest(
        OpenSSL::Digest.new('sha1'),
        config.secret_key,
        s3_upload_policy_document
      )
      encode(signature)
    end
def s3_upload_signature
      signature = OpenSSL::HMAC.digest(
        OpenSSL::Digest.new('sha1'),
        config.secret_key,
        s3_upload_policy_document
      )
      encode(signature)
    end
sign our request by Base64 encoding the policy document.