ns_hotp - Returns a decimal-coded one-time password (HOTP)
The function returns a one time password based on a HMAC algorithm (HOTP) as described in RFC-4226, where the message algorithm can be specified.
RFC-4226 defines HOTP as:
HOTP(K,C) = Truncate(HMAC-SHA-1(K,C)) K: key C: counter (moving factor for one time passwd)
The implemented function ns_hotp is a generalization over RFC by allowing to specify the message digest algorithm and the number of characters of the returned truncated value.
The listed commands is available in installations when NaviServer is compiled with OpenSSL support and where the nsf package is installed.
data is the moving factor for the one time password ("C" in the formula above).
nscp 2> ns_hotp -key "tweedie123" 1 763540