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

cloudfront-signer

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cloudfront-signer

Sign urls for AWS CloudFront

  • 4.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
77
decreased by-32.46%
Maintainers
1
Weekly downloads
 
Created
Source

CloudFront Signer Build Status

Sign urls with canned or custom policy

Notice: Use aws-sdk library rather, this one was done before I knew about it, and inspired from aws-cloudfront-sign

// canned:
const cfSign = require('cloudfront-signer');

const expire = Math.floor((Date.now()+86400e3)*0.001); // expire in one day
const url = 'http://xyz.cloudfront.net/test/cool?fun=1';
const signedUrl = url + '&' + cfSign(url, expire, cfKeypairId, cfPrivateKey)
// custom (allow wildcards):
const cfSign = require('cloudfront-signer');

const expire = Math.floor((Date.now()+86400e3)*0.001); // expire in one day
const qs = cfSign('http://xyz.cloudfront.net/test/*', expire, cfKeypairId, cfPrivateKey)
// valid for 'http://xyz.cloudfront.net/test/test/bar?' + qs
// valid for 'http://xyz.cloudfront.net/test/test/cool?fun=1&' + qs

Keywords

FAQs

Package last updated on 10 Aug 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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