Skip to content

Commit

Permalink
Apparently S3 always uses the same format to sign
Browse files Browse the repository at this point in the history
  • Loading branch information
brettcvz committed Oct 11, 2013
1 parent 1e62034 commit 156a1e4
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions index.js
Expand Up @@ -30,12 +30,7 @@ exports.urlSigner = function(key, secret, options){


var epo = Math.floor(expires.getTime()/1000); var epo = Math.floor(expires.getTime()/1000);


var str; var str = verb + '\n\n\n' + epo + '\n' + '/' + bucket + (fname[0] === '/'?'':'/') + fname;
if (subdomain) {
str = verb + '\n\n\n' + epo + '\n' + (fname[0] === '/'?'':'/') + fname;
} else {
str = verb + '\n\n\n' + epo + '\n' + '/' + bucket + (fname[0] === '/'?'':'/') + fname;
}


var hashed = hmacSha1(str); var hashed = hmacSha1(str);


Expand Down

0 comments on commit 156a1e4

Please sign in to comment.