aboutsummaryrefslogtreecommitdiff
path: root/nitrocli/doc/nitrocli.1
diff options
context:
space:
mode:
Diffstat (limited to 'nitrocli/doc/nitrocli.1')
-rw-r--r--nitrocli/doc/nitrocli.111
1 files changed, 10 insertions, 1 deletions
diff --git a/nitrocli/doc/nitrocli.1 b/nitrocli/doc/nitrocli.1
index fdbdb86..21aab03 100644
--- a/nitrocli/doc/nitrocli.1
+++ b/nitrocli/doc/nitrocli.1
@@ -47,12 +47,17 @@ the current time.
Therefore, the Nitrokey clock must be synchronized with the clock of the
application that requests the one-time password.
.TP
-\fBnitrocli otp get \fIslot \fR[\fB\-a\fR|\fB\-\-algorithm \fIalgorithm\fR]
+\fBnitrocli otp get \fIslot \fR[\fB\-a\fR|\fB\-\-algorithm \fIalgorithm\fR] \
+\fB[\-t\fR|\fB\-\-time \fItime\fR]
Generate a one-time password.
\fIslot\fR is the number of the slot to generate the password from.
\fIalgorithm\fR is the OTP algorithm to use.
Possible values are \fBhotp\fR for the HOTP algorithm according to RFC 4226 and
\fBtotp\fR for the TOTP algorithm according to RFC 6238 (default).
+Per default, this commands sets the Nitrokey's time to the system time if the
+TOTP algorithm is selected.
+If \fB\-\-time\fR is set, it is set to \fItime\fR instead, which must be a Unix
+timestamp (i.e., the number of seconds since 1970-01-01 00:00:00 UTC).
This command might require the user PIN (see the Configuration section).
.TP
\fBnitrocli otp set \fIslot name secret \
@@ -120,14 +125,18 @@ These two options are mutually exclusive.
Configure a one-time password slot with a hexadecimal secret representation:
$ \fBnitrocli otp set 0 test\-rfc4226 3132333435363738393031323334353637383930 \-\-algorithm hotp\fR
$ \fBnitrocli otp set 1 test\-foobar 666F6F626172 \-\-algorithm hotp\fR
+ $ \fBnitrocli otp set 0 test\-rfc6238 3132333435363738393031323334353637383930 \-\-algorithm totp \-\-digits 8\fR
.P
Configure a one-time password slot with an ASCII secret representation:
$ \fBnitrocli otp set 0 test\-rfc4226 12345678901234567890 \-\-ascii \-\-algorithm hotp\fR
$ \fBnitrocli otp set 1 test\-foobar foobar \-\-ascii \-\-algorithm hotp\fR
+ $ \fBnitrocli otp set 0 test\-rfc6238 12345678901234567890 \-\-ascii \-\-algorithm totp \-\-digits 8\fR
.P
Generate a one-time password:
$ \fBnitrocli otp get 0 \-\-algorithm hotp\fR
755224
+ $ \fBnitrocli otp get 0 \-\-algorithm totp \-\-time 1234567890\fR
+ 89005924
.P
Clear a one-time password slot:
$ \fBnitrocli otp clear 0 \-\-algorithm hotp\fR