xref: /freebsd/lib/geom/shsec/gshsec.8 (revision 66bee50af774673bfaeb4c66a5a82e0ac99e70a4)
1*e4b0a90eSBrooks Davis.\" Copyright (c) 2005 Pawel Jakub Dawidek <pjd@FreeBSD.org>
2*e4b0a90eSBrooks Davis.\" All rights reserved.
3*e4b0a90eSBrooks Davis.\"
4*e4b0a90eSBrooks Davis.\" Redistribution and use in source and binary forms, with or without
5*e4b0a90eSBrooks Davis.\" modification, are permitted provided that the following conditions
6*e4b0a90eSBrooks Davis.\" are met:
7*e4b0a90eSBrooks Davis.\" 1. Redistributions of source code must retain the above copyright
8*e4b0a90eSBrooks Davis.\"    notice, this list of conditions and the following disclaimer.
9*e4b0a90eSBrooks Davis.\" 2. Redistributions in binary form must reproduce the above copyright
10*e4b0a90eSBrooks Davis.\"    notice, this list of conditions and the following disclaimer in the
11*e4b0a90eSBrooks Davis.\"    documentation and/or other materials provided with the distribution.
12*e4b0a90eSBrooks Davis.\"
13*e4b0a90eSBrooks Davis.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND
14*e4b0a90eSBrooks Davis.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15*e4b0a90eSBrooks Davis.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16*e4b0a90eSBrooks Davis.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE
17*e4b0a90eSBrooks Davis.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18*e4b0a90eSBrooks Davis.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19*e4b0a90eSBrooks Davis.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20*e4b0a90eSBrooks Davis.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21*e4b0a90eSBrooks Davis.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22*e4b0a90eSBrooks Davis.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23*e4b0a90eSBrooks Davis.\" SUCH DAMAGE.
24*e4b0a90eSBrooks Davis.\"
25*e4b0a90eSBrooks Davis.Dd October 1, 2013
26*e4b0a90eSBrooks Davis.Dt GSHSEC 8
27*e4b0a90eSBrooks Davis.Os
28*e4b0a90eSBrooks Davis.Sh NAME
29*e4b0a90eSBrooks Davis.Nm gshsec
30*e4b0a90eSBrooks Davis.Nd "control utility for shared secret devices"
31*e4b0a90eSBrooks Davis.Sh SYNOPSIS
32*e4b0a90eSBrooks Davis.Nm
33*e4b0a90eSBrooks Davis.Cm label
34*e4b0a90eSBrooks Davis.Op Fl hv
35*e4b0a90eSBrooks Davis.Ar name
36*e4b0a90eSBrooks Davis.Ar prov prov ...
37*e4b0a90eSBrooks Davis.Nm
38*e4b0a90eSBrooks Davis.Cm stop
39*e4b0a90eSBrooks Davis.Op Fl fv
40*e4b0a90eSBrooks Davis.Ar name ...
41*e4b0a90eSBrooks Davis.Nm
42*e4b0a90eSBrooks Davis.Cm clear
43*e4b0a90eSBrooks Davis.Op Fl v
44*e4b0a90eSBrooks Davis.Ar prov ...
45*e4b0a90eSBrooks Davis.Nm
46*e4b0a90eSBrooks Davis.Cm dump
47*e4b0a90eSBrooks Davis.Ar prov ...
48*e4b0a90eSBrooks Davis.Nm
49*e4b0a90eSBrooks Davis.Cm list
50*e4b0a90eSBrooks Davis.Nm
51*e4b0a90eSBrooks Davis.Cm status
52*e4b0a90eSBrooks Davis.Nm
53*e4b0a90eSBrooks Davis.Cm load
54*e4b0a90eSBrooks Davis.Nm
55*e4b0a90eSBrooks Davis.Cm unload
56*e4b0a90eSBrooks Davis.Sh DESCRIPTION
57*e4b0a90eSBrooks DavisThe
58*e4b0a90eSBrooks Davis.Nm
59*e4b0a90eSBrooks Davisutility is used for setting up a device which contains a shared secret.
60*e4b0a90eSBrooks DavisThe secret is shared between the given providers.
61*e4b0a90eSBrooks DavisTo collect the secret, all providers are needed.
62*e4b0a90eSBrooks DavisIf one of the components is missing, there is no way to get any useful data from
63*e4b0a90eSBrooks Davisthe rest of them.
64*e4b0a90eSBrooks DavisThe first argument to
65*e4b0a90eSBrooks Davis.Nm
66*e4b0a90eSBrooks Davisindicates an action to be performed:
67*e4b0a90eSBrooks Davis.Bl -tag -width ".Cm destroy"
68*e4b0a90eSBrooks Davis.It Cm label
69*e4b0a90eSBrooks DavisSet up a shared secret device from the given components with the specified
70*e4b0a90eSBrooks Davis.Ar name .
71*e4b0a90eSBrooks DavisMetadata are stored in the last sector of every component.
72*e4b0a90eSBrooks Davis.It Cm stop
73*e4b0a90eSBrooks DavisTurn off an existing shared secret device by its
74*e4b0a90eSBrooks Davis.Ar name .
75*e4b0a90eSBrooks DavisThis command does not touch on-disk metadata!
76*e4b0a90eSBrooks Davis.It Cm clear
77*e4b0a90eSBrooks DavisClear metadata on the given providers.
78*e4b0a90eSBrooks Davis.It Cm dump
79*e4b0a90eSBrooks DavisDump metadata stored on the given providers.
80*e4b0a90eSBrooks Davis.It Cm list
81*e4b0a90eSBrooks DavisSee
82*e4b0a90eSBrooks Davis.Xr geom 8 .
83*e4b0a90eSBrooks Davis.It Cm status
84*e4b0a90eSBrooks DavisSee
85*e4b0a90eSBrooks Davis.Xr geom 8 .
86*e4b0a90eSBrooks Davis.It Cm load
87*e4b0a90eSBrooks DavisSee
88*e4b0a90eSBrooks Davis.Xr geom 8 .
89*e4b0a90eSBrooks Davis.It Cm unload
90*e4b0a90eSBrooks DavisSee
91*e4b0a90eSBrooks Davis.Xr geom 8 .
92*e4b0a90eSBrooks Davis.El
93*e4b0a90eSBrooks Davis.Pp
94*e4b0a90eSBrooks DavisAdditional options:
95*e4b0a90eSBrooks Davis.Bl -tag -width ".Fl f"
96*e4b0a90eSBrooks Davis.It Fl f
97*e4b0a90eSBrooks DavisForce the removal of the specified shared secret device.
98*e4b0a90eSBrooks Davis.It Fl h
99*e4b0a90eSBrooks DavisHardcode providers' names in metadata.
100*e4b0a90eSBrooks Davis.It Fl v
101*e4b0a90eSBrooks DavisBe more verbose.
102*e4b0a90eSBrooks Davis.El
103*e4b0a90eSBrooks Davis.Sh EXIT STATUS
104*e4b0a90eSBrooks DavisExit status is 0 on success, and 1 if the command fails.
105*e4b0a90eSBrooks Davis.Sh EXAMPLES
106*e4b0a90eSBrooks DavisThe following example shows how to create a shared secret device.
107*e4b0a90eSBrooks DavisThe secret will be split between a slice on a local disk and a USB Pen drive.
108*e4b0a90eSBrooks Davis.Bd -literal -offset indent
109*e4b0a90eSBrooks Davisgshsec label -v secret /dev/ada0s1 /dev/da0
110*e4b0a90eSBrooks Davisnewfs /dev/shsec/secret
111*e4b0a90eSBrooks Davis.Ed
112*e4b0a90eSBrooks Davis.Pp
113*e4b0a90eSBrooks DavisFrom now on, when the USB Pen drive is inserted, it will be automatically
114*e4b0a90eSBrooks Davisdetected and connected, making the secret available via the
115*e4b0a90eSBrooks Davis.Pa /dev/shsec/secret
116*e4b0a90eSBrooks Davisdevice.
117*e4b0a90eSBrooks Davis.Sh SEE ALSO
118*e4b0a90eSBrooks Davis.Xr geom 4 ,
119*e4b0a90eSBrooks Davis.Xr geom 8 ,
120*e4b0a90eSBrooks Davis.Xr newfs 8
121*e4b0a90eSBrooks Davis.Sh HISTORY
122*e4b0a90eSBrooks DavisThe
123*e4b0a90eSBrooks Davis.Nm
124*e4b0a90eSBrooks Davisutility appeared in
125*e4b0a90eSBrooks Davis.Fx 5.4 .
126*e4b0a90eSBrooks Davis.Sh AUTHORS
127*e4b0a90eSBrooks Davis.An Pawel Jakub Dawidek Aq Mt pjd@FreeBSD.org
128