0.0.1 • Published 10 years ago

yubikeyify v0.0.1

Weekly downloads
5
License
MIT
Repository
github
Last release
10 years ago

A Node.js client library for verifying OTPs with the Yubikey api servers.

Install

npm install yubikeyify

Or fork this repo and help improve it.

Usage:

var Yubikey = require('yubikeyify');

var yubikey = new Yubkey(client_id, secret_key, callbackparameter);
// client_id and secret_key can also be discovered from env

function onVerify(err, auth, callbackparameter) {
  // if err is null, you're good
  // auth is true if everything is fine
  // callbackparameter is something you can use for what you see fit
}

yubikey.verify('vvvvvvcurikvhjcvnlnbecbkubjvuittbifhndhn', onVerify);

Testing

Plug your YubiKey in, and run ./test.js. Try entering the same token twice.

Resources

0.0.1

10 years ago