HOTP: An HMAC-Based One-Time Password Algorithm *RFC 4226,HOTP Algorithm public class OneTimePasswordAlgorithm {
public OneTimePasswordAlgorithm() {
}
} private static final int[] doubleDigits =
{ 0, 2, 4, 6, 8, 1, 3, 5, 7, 9 }; public static int calcChecksum(long num, int digits) {
boolean doubleDigit =…