Skip to content

p-j/meteor-crypto-hmac

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HMAC (hash-based message authentication code) function from CryptoJS, packaged for Meteor.

Build Status

Dependency

Install

Inside your project folder run

$ meteor add jparker:crypto-hmac

You'll also need to have installed the package for the hash function you want to use, such as MD5 (jparker:crypto-md5) or SHA1 (jparker:crypto-sha1). Once you have jparker:crypto-hmac installed, any crypto-* hash function packages you install will provide a corresponding method under the CryptoJS namespace.

Usage

  • var hash = CryptoJS.HmacMD5('Message', 'Secret Passphrase').toString(); // '5e03d0c1b42ef0b7e61fb333f3993949'
  • var hash = CryptoJS.HmacSHA1('Message', 'Secret Passphrase').toString();
  • var hash = CryptoJS.HmacSHA256('Message', 'Secret Passphrase').toString();

See also

The CryptoJS project lives at https://code.google.com/p/crypto-js/.
HMAC functions are documented at https://code.google.com/p/crypto-js/#HMAC.

Related packages

Credits

Based on Dan Dascalescu's work

About

HMAC (keyed-hash message authentication codes) from CryptoJS repackaged for Meteor

Resources

Stars

Watchers

Forks

Packages

No packages published