U2F Authentication for Node.js
This is a simple library to register and check signatures provided by U2F clients/devices. It's intended to be used in Relying Parties - websites that want to add U2F 2-factor authentication for their users.
To use U2F, it is recommended to familiarize yourself with FIDO Alliance Specifications, although basic usage is shown below.
…Note that the window.u2f object is defined in the official Javascript U2F API, for which a polyfill is available as an npm module.
const registrationRequest = ... // Retrieve this from hitting the registration challenge endpoint
window.u2f.register(registrationRequest.appId, [registrationRequest], [], (registrationResponse) => {
// Send this registration response to the registration verification server endpoint
});…const authRequest = ...; // Retrieve this from hitting the authentication challenge endpoint
window.u2f.sign(authRequest.appId, authRequest.challenge, [authRequest], (authResponse) => {
// Send this authentication response to the authentication verification server endpoint
});http://demo.yubico.com/u2f
https://github.com/Yubico/python-u2flib-server
MIT
No open issues yet, or sync has not completed.