Skip to content

Token Generator for EdgeCast Token-Based Authentication - NodeJS

License

Notifications You must be signed in to change notification settings

hattan/ectoken-nodejs

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status

Verizon Digital Media Services

Token Generator for Edgecast Token-Based Authentication

Token-Based Authentication safeguards against hotlinking by adding a token requirement to requests for content secured by it. This token, which must be defined in the request URL's query string, defines the criteria that must be met before the requested content may be served via the CDN. This repository contains the following token generation resources:

node.js Token Generator for EdgeCast Token-Based Authentication

Methods

  • encrypt(key, params, verbose)
  • decrypt(key, token, verbose)

Example

const ectoken = require('ectoken').V3;

// encrypt
const token = ectoken.encrypt('keyvalue', 'ec_expire=1257642471&ec_clientip=11.22.33.1');

// decrypt
const params = ectoken.decrypt('keyvalue', token);

Contributing

Contributions are welcome! Please review our contribution guidelines.

More Information

Please refer to the CDN Help Center, which is available from within the MCC, for more information (e.g., parameter names and usage).

License

View legal and licensing information.

Other Languages & Documentation

You can find implementations of EC Token in other languages and further documentation on the EC Token Repo.

About

Token Generator for EdgeCast Token-Based Authentication - NodeJS

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 99.0%
  • Shell 1.0%