Files
zotp-bash/testotp-textoutput.sh
2026-06-06 21:36:42 +02:00

16 lines
325 B
Bash

#!/bin/bash
## zOTP Bash Example for Function testOTP - Using text output for validation over 15 minutes
declare thesalt="zOTP by Ze'ev Schurmann"
source zotp.inc.sh
declare theseed="user@domain.tld"
if [[ "$(testOTP 123456 15)" == "VALID" ]]; then
echo "OTP is valid..."
else
echo "OTP is invalid or expired..."
fi