Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

aws-signature-v4

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

aws-signature-v4 - npm Package Compare versions

Comparing version 1.2.0 to 1.2.1

8

index.js

@@ -96,5 +96,2 @@ /* eslint-env node */

query['X-Amz-SignedHeaders'] = exports.createSignedHeaders(options.headers);
if (options.sessionToken) {
query['X-Amz-Security-Token'] = options.sessionToken;
}

@@ -105,2 +102,7 @@ var canonicalRequest = exports.createCanonicalRequest(method, path, query, options.headers, payload);

query['X-Amz-Signature'] = signature;
if (options.sessionToken) {
query['X-Amz-Security-Token'] = options.sessionToken;
}
return options.protocol + '://' + host + path + '?' + querystring.stringify(query);

@@ -107,0 +109,0 @@ };

{
"name": "aws-signature-v4",
"version": "1.2.0",
"version": "1.2.1",
"description": "Generate AWS V4 Signatures and Signed URLs",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -0,1 +1,4 @@

[![Build Status](https://travis-ci.org/department-stockholm/aws-signature-v4.svg?branch=master)](https://travis-ci.org/department-stockholm/aws-signature-v4)
[![npm version](https://badge.fury.io/js/aws-signature-v4.svg)](https://badge.fury.io/js/aws-signature-v4)
# AWS Signature V4

@@ -2,0 +5,0 @@

@@ -80,3 +80,3 @@ /* eslint-env node, mocha */

it('should generate a presigned url with security token', function() {
it('should generate a presigned url with security token, and security token should be the last parameter', function() {
var presignedUrlWithSecurityToken = aws.createPresignedS3URL('test.txt', {

@@ -89,4 +89,4 @@ key: accessKey,

});
assert.equal(presignedUrlWithSecurityToken, 'https://examplebucket.s3.amazonaws.com/test.txt?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20130524%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20130524T000000Z&X-Amz-Expires=86400&X-Amz-SignedHeaders=host&X-Amz-Security-Token=EXAMPLESESSION&X-Amz-Signature=12abb65becb4cfbac48bfdd9eb3178408ff6fd7f470505f4baf3dcad7088253f');
assert.equal(presignedUrlWithSecurityToken, 'https://examplebucket.s3.amazonaws.com/test.txt?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20130524%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20130524T000000Z&X-Amz-Expires=86400&X-Amz-SignedHeaders=host&X-Amz-Signature=aeeed9bbccd4d02ee5c0109b86d86835f995330da4c265957d157751f604d404&X-Amz-Security-Token=EXAMPLESESSION');
});
});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc