yubikeyify

0.0.1 • Public • Published

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

Dependencies (1)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i yubikeyify

    Weekly Downloads

    0

    Version

    0.0.1

    License

    MIT

    Last publish

    Collaborators

    • skeldoy