kdc: _kdc_find_etype prevent NULL dereference
[heimdal.git] / kuser / kx509.1
blob1fb3ce2af5d6ed6e2956fa2834d65b1d78d9c34d
1 .\" Copyright (c) 2019 Kungliga Tekniska Högskolan
2 .\" (Royal Institute of Technology, Stockholm, Sweden).
3 .\" All rights reserved.
4 .\"
5 .\" Redistribution and use in source and binary forms, with or without
6 .\" modification, are permitted provided that the following conditions
7 .\" are met:
8 .\"
9 .\" 1. Redistributions of source code must retain the above copyright
10 .\"    notice, this list of conditions and the following disclaimer.
11 .\"
12 .\" 2. Redistributions in binary form must reproduce the above copyright
13 .\"    notice, this list of conditions and the following disclaimer in the
14 .\"    documentation and/or other materials provided with the distribution.
15 .\"
16 .\" 3. Neither the name of the Institute nor the names of its contributors
17 .\"    may be used to endorse or promote products derived from this software
18 .\"    without specific prior written permission.
19 .\"
20 .\" THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
21 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
24 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 .\" SUCH DAMAGE.
31 .\"
32 .\" $Id$
33 .\"
34 .Dd October  6, 2005
35 .Dt KLIST 1
36 .Os HEIMDAL
37 .Sh NAME
38 .Nm kx509
39 .Nd acquire or extract certificates using Kerberos credentials
40 .Sh SYNOPSIS
41 .Nm
42 .Bk -words
43 .Oo Fl c Ar cache \*(Ba Xo
44 .Fl Fl cache= Ns Ar cache
45 .Xc
46 .Oc
47 .Oo Fl s \*(Ba Xo
48 .Fl Fl save
49 .Xc
50 .Oc
51 .Oo Fl o Ar store \*(Ba Xo
52 .Fl Fl out= Ns Ar store
53 .Xc
54 .Oc
55 .Oo Fl x \*(Ba Xo
56 .Fl Fl extract
57 .Xc
58 .Oc
59 .Oo Fl t Ar time-left \*(Ba Xo
60 .Fl Fl test= Ns Ar time-left
61 .Xc
62 .Oc
63 .Oo Fl C Ar PKCS10:filename \*(Ba Xo
64 .Fl Fl csr= Ns Ar PKCS10:filename
65 .Xc
66 .Oc
67 .Oo Fl C Ar PKCS10:filename \*(Ba Xo
68 .Fl Fl csr= Ns Ar PKCS10:filename
69 .Xc
70 .Oc
71 .Oo Fl K Ar hx509-store \*(Ba Xo
72 .Fl Fl private-key= Ns Ar hx509-store
73 .Xc
74 .Oc
75 .Oo Fl r Ar realm \*(Ba Xo
76 .Fl Fl realm= Ns Ar realm
77 .Xc
78 .Oc
79 .Op Fl Fl help
80 .Ek
81 .Sh DESCRIPTION
82 .Nm
83 acquires PKIX credentials from a credential cache using the kx509
84 protocol, or extracts PKIX credentials stored in a credential
85 cache.
86 .Pp
87 Options supported:
88 .Bl -tag -width Ds
89 .It Fl c Ar cache , Fl Fl cache= Ns Ar cache
90 credential cache to use (if not given, then the default will be
91 used).
92 .It Fl t Ar time-left , Fl Fl test= Ns Ar time-left
93 Test for there being an active and valid certificate in the
94 credential cache, with at least
95 .Ar time-left
96 seconds left of valid life.  If given with the
97 .Fl o
98 then the certificates in the hx509 store are tested along with
99 those in the credentials cache (if any).
100 .It Fl x , Fl Fl extract
101 Extract, rather than acquire credentials.
102 .It Fl s , Fl Fl save
103 save the acquired certificate and the private key used in the
104 given credential cache.
105 .It Fl o , Fl Fl out= Ns Ar hx509-store
106 An hx509 store specification, such as
107 .Va DER-FILE:/path/to/der/file ,
108 .Va PEM-FILE:/path/to/PEM/file ,
109 .Va FILE:/path/to/PEM/file ,
111 .Va PKCS12:/path/to/PKCS#12/file
112 into which to store any PKIX certificate and private key
113 (unencrypted) that may have been acquired with the kx509 protocol
114 and stored in the
115 .Ns Ar ccache.
116 .It Fl r Ar realm, Fl Fl realm= Ns Ar realm
117 specify the name of the realm whose kx509 service to use.
118 .It Fl K Ar store, Fl Fl private-key= Ns Ar store
119 use the private key from the given hx509 store for requesting a
120 certificate.
121 .It Fl C Ar csr, Fl Fl csr= Ns Ar certificate-request
122 specify a CSR to use, which must be a string of the form
123 PKCS10:filename and which must contain the DER encoding of a
124 PKCS#10 certification request.
128 .Nm hxtool(1)
129 command can be used to create private keys and CSRs.
130 .Sh SEE ALSO
131 .Xr kdestroy 1 ,
132 .Xr kinit 1 ,
133 .Xr hxtool 1