/otp

A simple and easy to use library for use with ScrambleID, it provides HOTP default settings that satisfy the google authenticator protocol, while being customizable enough to satisfy the needs of the more esoteric parts of scrambleID protocol and the software that utilizes it

Primary LanguageGo

Multiverse OS Logo

Scramble ID: OTP (HOTP, and TOTP) Library

URL multiverse-os.org

A library to satisfy the requirements of Scramble ID, it provides by default HOTP settings that satisfy the google authenticator protocol, while being customizable enough to satisfy the needs of the more esoteric parts of scramble ID and the software that uses it.

Usage

Usage is done by chaining any customization onto the intialization function:

The simplest version, that will work with google authenicator is:

  hotp := otp.NewHOTP("seed-value")

And customization is done with chained functions:

  hotp := otp.NewHOTP("seed-value").Encoding(sha256.New)