hectorm / Otpauth
Licence: mit
One Time Password (HOTP/TOTP) library for Node.js, Deno and browsers.
Stars: β 135
Programming Languages
javascript
184084 projects - #8 most used programming language
Labels
Projects that are alternatives of or similar to Otpauth
Otplib
π One Time Password (OTP) / 2FA for Node.js and Browser - Supports HOTP, TOTP and Google Authenticator
Stars: β 916 (+578.52%)
Mutual labels: otp, two-factor-authentication, authenticator, hotp, two-factor, browser
Speakeasy
**NOT MAINTAINED** Two-factor authentication for Node.js. One-time passcode generator (HOTP/TOTP) with support for Google Authenticator.
Stars: β 2,531 (+1774.81%)
Mutual labels: node-js, totp, two-factor-authentication, hotp, two-factor
2FAuth
A Web app to manage your Two-Factor Authentication (2FA) accounts and generate their security codes
Stars: β 664 (+391.85%)
Mutual labels: otp, two-factor, totp, hotp, two-factor-authentication
Authenticatorpro
π± Two-Factor Authentication (2FA) client for Android + Wear OS
Stars: β 155 (+14.81%)
Mutual labels: totp, two-factor-authentication, authenticator, hotp
rx-otp
HMAC-based (HOTP) and Time-based (TOTP) One-Time Password manager. Works with Google Authenticator for Two-Factor Authentication.
Stars: β 79 (-41.48%)
Mutual labels: otp, totp, hotp, two-factor-authentication
Aegis
A free, secure and open source app for Android to manage your 2-step verification tokens.
Stars: β 2,692 (+1894.07%)
Mutual labels: otp, totp, authenticator, hotp
Twofactor totp
π Second factor TOTP (RFC 6238) provider for Nextcloud
Stars: β 203 (+50.37%)
Mutual labels: otp, totp, two-factor-authentication, two-factor
Go Guardian
Go-Guardian is a golang library that provides a simple, clean, and idiomatic way to create powerful modern API and web authentication.
Stars: β 204 (+51.11%)
Mutual labels: auth, totp, authenticator, hotp
totp
Time-Based One-Time Password Code Generator
Stars: β 76 (-43.7%)
Mutual labels: two-factor, totp, authenticator, two-factor-authentication
Onetimepassword
π A small library for generating TOTP and HOTP one-time passwords on iOS.
Stars: β 243 (+80%)
Mutual labels: otp, totp, two-factor-authentication, hotp
Andotp
Open source two-factor authentication for Android
Stars: β 3,326 (+2363.7%)
Mutual labels: otp, totp, two-factor-authentication, hotp
otp-java
A small and easy-to-use one-time password generator library for Java according to RFC 4226 (HOTP) and RFC 6238 (TOTP).
Stars: β 107 (-20.74%)
Mutual labels: otp, totp, hotp, two-factor-authentication
Freeotpplus
Enhanced fork of FreeOTP-Android providing a feature-rich 2FA authenticator
Stars: β 223 (+65.19%)
Mutual labels: otp, totp, authenticator, hotp
crotp
CrOTP - One Time Passwords for Crystal
Stars: β 62 (-54.07%)
Mutual labels: otp, totp, hotp, two-factor-authentication
apache 2fa
Apache two-factor (2FA) authentication with Google Authenticator based on Time-based One-Time Password (TOTP) or HMAC-based one-time password (HOTP) Algorithms.
Stars: β 63 (-53.33%)
Mutual labels: two-factor, totp, hotp, two-factor-authentication
Otphp
π A PHP library for generating one time passwords according to RFC 4226 (HOTP) and the RFC 6238 (TOTP)
Stars: β 857 (+534.81%)
Mutual labels: otp, totp, hotp
hotp-php
HMAC Based One Time Passwords in PHP. RFC4226 and RFC6238 compliant.
Stars: β 51 (-62.22%)
Mutual labels: otp, totp, hotp
multiOTPCredentialProvider
multiOTP Credential Provider is a V2 Credential Provider for Windows 7/8/8.1/10/2012(R2)/2016 with options like RDP only and UPN name support
Stars: β 121 (-10.37%)
Mutual labels: otp, totp, hotp
Privacyidea
π multi factor authentication system (2FA, MFA, OTP Server)
Stars: β 1,027 (+660.74%)
Mutual labels: otp, two-factor-authentication, two-factor
react-native-sms-user-consent
React Native wrapper for Android's SMS User Consent API, ready to use in React Native apps with minimum effort.
Stars: β 45 (-66.67%)
Mutual labels: otp, two-factor, auth
OTPAuth
One Time Password (HOTP/TOTP) library for Node.js, Deno and browsers.
Usage
Node.js
import * as OTPAuth from 'otpauth';
// Create a new TOTP object.
let totp = new OTPAuth.TOTP({
issuer: 'ACME',
label: 'AzureDiamond',
algorithm: 'SHA1',
digits: 6,
period: 30,
secret: 'NB2W45DFOIZA' // or "OTPAuth.Secret.fromB32('NB2W45DFOIZA')"
});
// Generate a token.
let token = totp.generate();
// Validate a token.
let delta = totp.validate({
token: token,
window: 1
});
// Convert to Google Authenticator key URI.
// otpauth://totp/ACME:AzureDiamond?issuer=ACME&secret=NB2W45DFOIZA&algorithm=SHA1&digits=6&period=30
let uri = totp.toString(); // or "OTPAuth.URI.stringify(totp)"
// Convert from Google Authenticator key URI.
let parsedTotp = OTPAuth.URI.parse(uri);
Deno
// @deno-types="https://deno.land/x/otpauth/types/index.d.ts"
import * as OTPAuth from 'https://deno.land/x/otpauth/dist/otpauth.esm.js'
// Same as above...
Browsers
<script src="https://cdn.jsdelivr.net/npm/otpauth/dist/otpauth.umd.min.js"></script>
<script>
// Same as above...
</script>
Documentation
See the documentation page.
Supported hashing algorithms
In Node.js, the same algorithms as
Crypto.createHmac
function are supported, since it is used internally. In Deno and browsers, the SHA1
, SHA256
and SHA512
algorithms are supported by using the
Stanford Javascript Crypto Library.
License
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].