summaryrefslogtreecommitdiffstats
path: root/usr.bin/key
diff options
context:
space:
mode:
authorcharnier <charnier@FreeBSD.org>2000-12-10 20:52:43 +0000
committercharnier <charnier@FreeBSD.org>2000-12-10 20:52:43 +0000
commit1a7832d52733a1b945f4c6806e25643560852460 (patch)
treedfab064717fc63ed3c1bfaba54e8da6b7fd3cc9d /usr.bin/key
parentb022d1d27e2a42e93ab520d233de00d72a07feea (diff)
downloadFreeBSD-src-1a7832d52733a1b945f4c6806e25643560852460.zip
FreeBSD-src-1a7832d52733a1b945f4c6806e25643560852460.tar.gz
Remove one more incorrect section name. Typos.
Add rcsid. fprintf -> warn.
Diffstat (limited to 'usr.bin/key')
-rw-r--r--usr.bin/key/key.118
-rw-r--r--usr.bin/key/skey.c11
2 files changed, 18 insertions, 11 deletions
diff --git a/usr.bin/key/key.1 b/usr.bin/key/key.1
index 2b3545c..1e49886 100644
--- a/usr.bin/key/key.1
+++ b/usr.bin/key/key.1
@@ -14,11 +14,18 @@
.Ar key
.Sh DESCRIPTION
.Nm Key
-takes the optional count of the number of one time access
+takes the optional count of the number of one time access
passwords to print
-along with a (maximum) sequence number and key as command line args,
+along with a (maximum) sequence number and key as command line arguments,
it prompts for the user's secret password, and produces both word
and hex format responses.
+.Pp
+The following option is available:
+.Bl -tag -width Fl
+.It Fl n Ar count
+The number of one time access passwords to print.
+The default is 1.
+.El
.Sh EXAMPLES
Usage example:
.Bd -literal -offset indent -compact
@@ -28,18 +35,13 @@ OMEN US HORN OMIT BACK AHOY
\&.... 4 more passwords.
>
.Ed
-.Sh OPTIONS
-.Bl -tag -width Fl
-.It Fl n Ar count
-The number of one time access passwords to print.
-The default is one.
-.El
.Sh SEE ALSO
.Xr keyinfo 1 ,
.Xr keyinit 1 ,
.Xr skey 1
.\" .BR keysu(1),
.Sh AUTHORS
+.An -nosplit
Command by
.An Phil Karn ,
.An Neil M. Haller ,
diff --git a/usr.bin/key/skey.c b/usr.bin/key/skey.c
index 42ef6c5..6dc5a0a 100644
--- a/usr.bin/key/skey.c
+++ b/usr.bin/key/skey.c
@@ -10,6 +10,11 @@
* >
*/
+#ifndef lint
+static const char rcsid[] =
+ "$FreeBSD$";
+#endif /* not lint */
+
#include <err.h>
#include <stdio.h>
#include <stdlib.h>
@@ -18,7 +23,7 @@
#ifdef __MSDOS__
#include <dos.h>
-#else /* Assume BSD unix */
+#else /* Assume BSD Unix */
#include <fcntl.h>
#endif
@@ -59,14 +64,14 @@ char *argv[];
seed = slash;
if((n = atoi(argv[optind])) < 0){
- fprintf(stderr,"%s not positive\n",argv[optind]);
+ warnx("%s not positive",argv[optind]);
usage();
}
}
else {
if((n = atoi(argv[optind])) < 0){
- fprintf(stderr,"%s not positive\n",argv[optind]);
+ warnx("%s not positive",argv[optind]);
usage();
}
seed = argv[++optind];
OpenPOWER on IntegriCloud