Skip to content

reubenmiller/totp-generator

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

totp-generator

Build Status Code Climate Test Coverage npm Version

totp-generator lets you generate TOTP tokens from a TOTP key

How to use

var totp = require('totp-generator');

var token = totp('JBSWY3DPEHPK3PXP');

console.log(token); // prints a 6 digit time base token based on inputed key and time

Works with these token requirements

  • SHA-1
  • 30 sec epoch interval
  • 6 digit tokens

What do I use this library for?

  • E2E tests (where you need to login with 2-factor authentication)

About

Generate TOTP tokens from key

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%