xref: /freebsd/contrib/ntp/ntpd/ntp.keys.def (revision 2b15cb3d0922bd70ea592f0da9b4a5b167f4d53f)
1*2b15cb3dSCy Schubert/* -*- Mode: Text -*- */
2*2b15cb3dSCy Schubert
3*2b15cb3dSCy Schubertautogen definitions options;
4*2b15cb3dSCy Schubert
5*2b15cb3dSCy Schubert#include copyright.def
6*2b15cb3dSCy Schubert#include version.def
7*2b15cb3dSCy Schubert
8*2b15cb3dSCy Schubert// We want the synopsis to be "/etc/ntp.keys" but we need the prog-name
9*2b15cb3dSCy Schubert// to be ntp.keys - the latter is also how autogen produces the output
10*2b15cb3dSCy Schubert// file name.
11*2b15cb3dSCy Schubertprog-name	= "ntp.keys";
12*2b15cb3dSCy Schubertfile-path	= "/etc/ntp.keys";
13*2b15cb3dSCy Schubertprog-title	= "NTP symmetric key file format";
14*2b15cb3dSCy Schubert
15*2b15cb3dSCy Schubert/* explain: Additional information whenever the usage routine is invoked */
16*2b15cb3dSCy Schubertexplain = <<- _END_EXPLAIN
17*2b15cb3dSCy Schubert	_END_EXPLAIN;
18*2b15cb3dSCy Schubert
19*2b15cb3dSCy Schubertdoc-section	= {
20*2b15cb3dSCy Schubert  ds-type	= 'DESCRIPTION';
21*2b15cb3dSCy Schubert  ds-format	= 'mdoc';
22*2b15cb3dSCy Schubert  ds-text	= <<- _END_PROG_MDOC_DESCRIP
23*2b15cb3dSCy SchubertThis document describes the format of an NTP symmetric key file.
24*2b15cb3dSCy SchubertFor a description of the use of this type of file, see the
25*2b15cb3dSCy Schubert.Qq Authentication Support
26*2b15cb3dSCy Schubertsection of the
27*2b15cb3dSCy Schubert.Xr ntp.conf 5
28*2b15cb3dSCy Schubertpage.
29*2b15cb3dSCy Schubert.Pp
30*2b15cb3dSCy Schubert.Xr ntpd 8
31*2b15cb3dSCy Schubertreads its keys from a file specified using the
32*2b15cb3dSCy Schubert.Fl k
33*2b15cb3dSCy Schubertcommand line option or the
34*2b15cb3dSCy Schubert.Ic keys
35*2b15cb3dSCy Schubertstatement in the configuration file.
36*2b15cb3dSCy SchubertWhile key number 0 is fixed by the NTP standard
37*2b15cb3dSCy Schubert(as 56 zero bits)
38*2b15cb3dSCy Schubertand may not be changed,
39*2b15cb3dSCy Schubertone or more keys numbered between 1 and 65534
40*2b15cb3dSCy Schubertmay be arbitrarily set in the keys file.
41*2b15cb3dSCy Schubert.Pp
42*2b15cb3dSCy SchubertThe key file uses the same comment conventions
43*2b15cb3dSCy Schubertas the configuration file.
44*2b15cb3dSCy SchubertKey entries use a fixed format of the form
45*2b15cb3dSCy Schubert.Pp
46*2b15cb3dSCy Schubert.D1 Ar keyno type key
47*2b15cb3dSCy Schubert.Pp
48*2b15cb3dSCy Schubertwhere
49*2b15cb3dSCy Schubert.Ar keyno
50*2b15cb3dSCy Schubertis a positive integer (between 1 and 65534),
51*2b15cb3dSCy Schubert.Ar type
52*2b15cb3dSCy Schubertis the message digest algorithm,
53*2b15cb3dSCy Schubertand
54*2b15cb3dSCy Schubert.Ar key
55*2b15cb3dSCy Schubertis the key itself.
56*2b15cb3dSCy Schubert.Pp
57*2b15cb3dSCy SchubertThe
58*2b15cb3dSCy Schubert.Ar key
59*2b15cb3dSCy Schubertmay be given in a format
60*2b15cb3dSCy Schubertcontrolled by the
61*2b15cb3dSCy Schubert.Ar type
62*2b15cb3dSCy Schubertfield.
63*2b15cb3dSCy SchubertThe
64*2b15cb3dSCy Schubert.Ar type
65*2b15cb3dSCy Schubert.Li MD5
66*2b15cb3dSCy Schubertis always supported.
67*2b15cb3dSCy SchubertIf
68*2b15cb3dSCy Schubert.Li ntpd
69*2b15cb3dSCy Schubertwas built with the OpenSSL library
70*2b15cb3dSCy Schubertthen any digest library supported by that library may be specified.
71*2b15cb3dSCy SchubertHowever, if compliance with FIPS 140-2 is required the
72*2b15cb3dSCy Schubert.Ar type
73*2b15cb3dSCy Schubertmust be either
74*2b15cb3dSCy Schubert.Li SHA
75*2b15cb3dSCy Schubertor
76*2b15cb3dSCy Schubert.Li SHA1 .
77*2b15cb3dSCy Schubert.Pp
78*2b15cb3dSCy SchubertWhat follows are some key types, and corresponding formats:
79*2b15cb3dSCy Schubert.Pp
80*2b15cb3dSCy Schubert.Bl -tag -width RMD160 -compact
81*2b15cb3dSCy Schubert.It Li MD5
82*2b15cb3dSCy SchubertThe key is 1 to 16 printable characters terminated by
83*2b15cb3dSCy Schubertan EOL,
84*2b15cb3dSCy Schubertwhitespace,
85*2b15cb3dSCy Schubertor
86*2b15cb3dSCy Schuberta
87*2b15cb3dSCy Schubert.Li #
88*2b15cb3dSCy Schubert(which is the "start of comment" character).
89*2b15cb3dSCy Schubert.Pp
90*2b15cb3dSCy Schubert.It Li SHA
91*2b15cb3dSCy Schubert.It Li SHA1
92*2b15cb3dSCy Schubert.It Li RMD160
93*2b15cb3dSCy SchubertThe key is a hex-encoded ASCII string of 40 characters,
94*2b15cb3dSCy Schubertwhich is truncated as necessary.
95*2b15cb3dSCy Schubert.El
96*2b15cb3dSCy Schubert.Pp
97*2b15cb3dSCy SchubertNote that the keys used by the
98*2b15cb3dSCy Schubert.Xr ntpq 8
99*2b15cb3dSCy Schubertand
100*2b15cb3dSCy Schubert.Xr ntpdc 8
101*2b15cb3dSCy Schubertprograms are checked against passwords
102*2b15cb3dSCy Schubertrequested by the programs and entered by hand,
103*2b15cb3dSCy Schubertso it is generally appropriate to specify these keys in ASCII format.
104*2b15cb3dSCy Schubert	_END_PROG_MDOC_DESCRIP;
105*2b15cb3dSCy Schubert};
106*2b15cb3dSCy Schubert
107*2b15cb3dSCy Schubertdoc-section	= {
108*2b15cb3dSCy Schubert  ds-type	= 'FILES';
109*2b15cb3dSCy Schubert  ds-format	= 'mdoc';
110*2b15cb3dSCy Schubert  ds-text	= <<- _END_MDOC_FILES
111*2b15cb3dSCy Schubert.Bl -tag -width /etc/ntp.keys -compact
112*2b15cb3dSCy Schubert.It Pa /etc/ntp.keys
113*2b15cb3dSCy Schubertthe default name of the configuration file
114*2b15cb3dSCy Schubert.El
115*2b15cb3dSCy Schubert	_END_MDOC_FILES;
116*2b15cb3dSCy Schubert};
117*2b15cb3dSCy Schubert
118*2b15cb3dSCy Schubertdoc-section	= {
119*2b15cb3dSCy Schubert  ds-type	= 'SEE ALSO';
120*2b15cb3dSCy Schubert  ds-format	= 'mdoc';
121*2b15cb3dSCy Schubert  ds-text	= <<- _END_MDOC_SEE_ALSO
122*2b15cb3dSCy Schubert.Xr ntp.conf 5 ,
123*2b15cb3dSCy Schubert.Xr ntpd 1ntpdmdoc ,
124*2b15cb3dSCy Schubert.Xr ntpdate 1ntpdatemdoc ,
125*2b15cb3dSCy Schubert.Xr ntpdc 1ntpdcmdoc ,
126*2b15cb3dSCy Schubert.Xr sntp 1sntpmdoc
127*2b15cb3dSCy Schubert	_END_MDOC_SEE_ALSO;
128*2b15cb3dSCy Schubert};
129*2b15cb3dSCy Schubert
130*2b15cb3dSCy Schubert/*
131*2b15cb3dSCy Schubertdoc-section	= {
132*2b15cb3dSCy Schubert  ds-type	= 'BUGS';
133*2b15cb3dSCy Schubert  ds-format	= 'mdoc';
134*2b15cb3dSCy Schubert  ds-text	= <<- _END_MDOC_BUGS
135*2b15cb3dSCy Schubert.Xr ntpd 8
136*2b15cb3dSCy Schuberthas gotten rather fat.
137*2b15cb3dSCy SchubertWhile not huge, it has gotten larger than might
138*2b15cb3dSCy Schubertbe desirable for an elevated-priority daemon running on a workstation,
139*2b15cb3dSCy Schubertparticularly since many of the fancy features which consume the space
140*2b15cb3dSCy Schubertwere designed more with a busy primary server, rather than a high
141*2b15cb3dSCy Schubertstratum workstation, in mind.
142*2b15cb3dSCy Schubert	_END_MDOC_BUGS;
143*2b15cb3dSCy Schubert};
144*2b15cb3dSCy Schubert*/
145*2b15cb3dSCy Schubert
146*2b15cb3dSCy Schubertdoc-section	= {
147*2b15cb3dSCy Schubert  ds-type	= 'NOTES';
148*2b15cb3dSCy Schubert  ds-format	= 'mdoc';
149*2b15cb3dSCy Schubert  ds-text	= <<- _END_MDOC_NOTES
150*2b15cb3dSCy SchubertThis document was derived from FreeBSD.
151*2b15cb3dSCy Schubert	_END_MDOC_NOTES;
152*2b15cb3dSCy Schubert};
153