Following is a description of the format of NTP key files. For a description of the use of these files, see the "Authentication Support" section of the ntp.conf(5) page.
In the case of DES, the keys are 56 bits long with, depending on type, a parity check on each byte. In the case of MD5, the keys are 64 bits (8 bytes). ntpd(8) reads its keys from a file specified using the -k command line option or the keys statement in the configuration file. While key number 0 is fixed by the NTP standard (as 56 zero bits) and may not be changed, one or more of the keys numbered 1 through 15 may be arbitrarily set in the keys file.
The key file uses the same comment conventions as the configuration file. Key entries use a fixed format of the form
where keyno is a positive integer, type is a single character which defines the key format, and key is the key itself.
The key may be given in one of four different formats, controlled by the type character. The four key types, and corresponding formats, are listed following.