Add manpage for dropbearconvert

Move dropbearkey to manual section 1
Add install target for manpages

--HG--
rename : dropbearkey.8 => dropbearkey.1
This commit is contained in:
Matt Johnston 2013-10-03 23:45:25 +08:00
parent 6a09fa23d0
commit fc1155f974
3 changed files with 74 additions and 22 deletions

View File

@ -66,9 +66,10 @@ VPATH=@srcdir@
srcdir=@srcdir@ srcdir=@srcdir@
prefix=@prefix@ prefix=@prefix@
exec_prefix=${prefix} datarootdir = @datarootdir@
bindir=${exec_prefix}/bin bindir=@bindir@
sbindir=${exec_prefix}/sbin sbindir=@sbindir@
mandir=@mandir@
CC=@CC@ CC=@CC@
AR=@AR@ AR=@AR@
@ -123,33 +124,31 @@ install: $(addprefix inst_, $(TARGETS))
installdropbearmulti: insdbmulti $(addprefix insmulti, $(PROGRAMS)) installdropbearmulti: insdbmulti $(addprefix insmulti, $(PROGRAMS))
insdbmulti: dropbearmulti insdbmulti: dropbearmulti
$(INSTALL) -d -m 755 $(DESTDIR)$(bindir) $(INSTALL) -d $(DESTDIR)$(bindir)
$(INSTALL) -m 755 dropbearmulti$(EXEEXT) $(DESTDIR)$(bindir) $(INSTALL) dropbearmulti$(EXEEXT) $(DESTDIR)$(bindir)
-chown root $(DESTDIR)$(bindir)/dropbearmulti$(EXEEXT)
-chgrp 0 $(DESTDIR)$(bindir)/dropbearmulti$(EXEEXT)
insmultidropbear: dropbearmulti insmultidropbear: dropbearmulti
$(INSTALL) -d -m 755 $(DESTDIR)$(sbindir) $(INSTALL) -d $(DESTDIR)$(sbindir)
-rm -f $(DESTDIR)$(sbindir)/dropbear$(EXEEXT) -rm -f $(DESTDIR)$(sbindir)/dropbear$(EXEEXT)
-ln -s $(bindir)/dropbearmulti$(EXEEXT) $(DESTDIR)$(sbindir)/dropbear$(EXEEXT) -ln -s $(bindir)/dropbearmulti$(EXEEXT) $(DESTDIR)$(sbindir)/dropbear$(EXEEXT)
insmulti%: dropbearmulti insmulti%: dropbearmulti
$(INSTALL) -d -m 755 $(DESTDIR)$(bindir) $(INSTALL) -d $(DESTDIR)$(bindir)
-rm -f $(DESTDIR)$(bindir)/$*$(EXEEXT) -rm -f $(DESTDIR)$(bindir)/$*$(EXEEXT)
-ln -s $(bindir)/dropbearmulti$(EXEEXT) $(DESTDIR)$(bindir)/$*$(EXEEXT) -ln -s $(bindir)/dropbearmulti$(EXEEXT) $(DESTDIR)$(bindir)/$*$(EXEEXT)
# dropbear should go in sbin, so it needs a seperate rule # dropbear should go in sbin, so it needs a seperate rule
inst_dropbear: dropbear inst_dropbear: dropbear
$(INSTALL) -d -m 755 $(DESTDIR)$(sbindir) $(INSTALL) -d $(DESTDIR)$(sbindir)
$(INSTALL) -m 755 dropbear$(EXEEXT) $(DESTDIR)$(sbindir) $(INSTALL) dropbear$(EXEEXT) $(DESTDIR)$(sbindir)
-chown root $(DESTDIR)$(sbindir)/dropbear$(EXEEXT) $(INSTALL) -d $(DESTDIR)$(mandir)/man8
-chgrp 0 $(DESTDIR)$(sbindir)/dropbear$(EXEEXT) $(INSTALL) -m 644 dropbear.8 $(DESTDIR)$(mandir)/man8/dropbear.8
inst_%: $* inst_%: $*
$(INSTALL) -d -m 755 $(DESTDIR)$(bindir) $(INSTALL) -d $(DESTDIR)$(bindir)
$(INSTALL) -m 755 $*$(EXEEXT) $(DESTDIR)$(bindir) $(INSTALL) $*$(EXEEXT) $(DESTDIR)$(bindir)
-chown root $(DESTDIR)$(bindir)/$*$(EXEEXT) $(INSTALL) -d $(DESTDIR)$(mandir)/man1
-chgrp 0 $(DESTDIR)$(bindir)/$*$(EXEEXT) $(INSTALL) -m 644 $*.1 $(DESTDIR)$(mandir)/man1/$*.1
# for some reason the rule further down doesn't like $($@objs) as a prereq. # for some reason the rule further down doesn't like $($@objs) as a prereq.

50
dropbearconvert.1 Normal file
View File

@ -0,0 +1,50 @@
.TH dropbearconvert 1
.SH NAME
dropbearconvert \- convert between Dropbear and OpenSSH private key formats
.SH SYNOPSIS
.B dropbearconvert
.I input_type
.I output_type
.I input_file
.I output_file
.SH DESCRIPTION
.B Dropbear
and
.B OpenSSH
SSH implementations have different private key formats.
.B dropbearconvert
can convert between the two.
.P
Dropbear uses the same SSH public key format as OpenSSH, it can be extracted
from a private key by using
.B dropbearkey \-y
.P
Encrypted private keys are not supported, use ssh-keygen(1) to decrypt them
first.
.SH OPTIONS
.TP
.B input type
Either
.I dropbear
or
.I openssh
.TP
.B output type
Either
.I dropbear
or
.I openssh
.TP
.B input file
An existing Dropbear or OpenSSH private key file
.TP
.B output file
The path to write the converted private key file
.SH EXAMPLE
# dropbearconvert openssh dropbear ~/.ssh/id_rsa ~/.ssh/dropbear_priv
.SH AUTHOR
Matt Johnston (matt@ucc.asn.au).
.SH SEE ALSO
dropbearkey(1), ssh-keygen(1)
.P
https://matt.ucc.asn.au/dropbear/dropbear.html

View File

@ -1,6 +1,6 @@
.TH dropbearkey 8 .TH dropbearkey 1
.SH NAME .SH NAME
dropbearkey \- create private keys for the use with dropbear(8) dropbearkey \- create private keys for the use with dropbear(8) or dbclient(1)
.SH SYNOPSIS .SH SYNOPSIS
.B dropbearkey .B dropbearkey
\-t \-t
@ -16,8 +16,7 @@ generates a
or or
.I DSS .I DSS
format SSH private key, and saves it to a file for the use with the format SSH private key, and saves it to a file for the use with the
.BR dropbear (8) Dropbear client or server.
SSH 2 server.
Note that Note that
some SSH implementations some SSH implementations
use the term "DSA" rather than "DSS", they mean the same thing. use the term "DSA" rather than "DSS", they mean the same thing.
@ -38,6 +37,10 @@ Write the secret key to the file
Set the key size to Set the key size to
.I bits .I bits
bits, should be multiple of 8 (optional). bits, should be multiple of 8 (optional).
.SH NOTES
The program dropbearconvert(1) can be used to convert between Dropbear and OpenSSH key formats.
.P
Dropbear does not support encrypted keys.
.SH EXAMPLE .SH EXAMPLE
# dropbearkey -t rsa -f /etc/dropbear/dropbear_rsa_host_key # dropbearkey -t rsa -f /etc/dropbear/dropbear_rsa_host_key
.SH AUTHOR .SH AUTHOR
@ -45,6 +48,6 @@ Matt Johnston (matt@ucc.asn.au).
.br .br
Gerrit Pape (pape@smarden.org) wrote this manual page. Gerrit Pape (pape@smarden.org) wrote this manual page.
.SH SEE ALSO .SH SEE ALSO
dropbear(8), dbclient(1) dropbear(8), dbclient(1), dropbearconvert(1)
.P .P
https://matt.ucc.asn.au/dropbear/dropbear.html https://matt.ucc.asn.au/dropbear/dropbear.html