cisco — Configuring NTP Authentication

Administering the Device Configuring NTP Authentication Command or Action Purpose Example: Device(config)# ntp authenticate Use the no form of this command to disable NTP authentication Step 4 [no] ntp authentication-key number {md5 | cmac-aes-128 | hmac-sha1 | hmac-sha2-256} value Example: Device(config)# ntp authentication-key 42 md5 aNiceKey Defines the authentication keys. • Each key has a key number, a type, and a value. • Keys can be one of the following types: • md5: Authentication using the MD5 algorithm. • cmac-aes-128: Authentication using Cipher-based message authentication codes (CMAC) with the AES-128 algorithm. The digest length is 128 bits and the key length is 16 or 32 bytes.

• hmac-sha1: Authentication using Hash-based Message Authentication Code (HMAC) using the SHA1 hash function. The digest length is 128 bits and the key length is 1 to 32 bytes. • hmac-sha2-256: Authentication using HMAC using the SHA2 hash function. The digest length is 256 bits and the key length is 1 to 32 bytes Use the no form of this command to remove authentication key. Step 5 [no] ntp trusted-key key-number Example: Device(config)# ntp trusted-key 42 Defines trusted authentication keys that a peer NTP device must provide in its NTP packets for this device to synchronize to it. Use the no form of this command to disable trusted authentication.

Step 6 [no] ntp server ip-address key key-id [prefer] Example: Device(config)# ntp server 172.16.22.44 key 42 Allows the software clock to be synchronized by an NTP time server. • ip-address: The IP address of the time server providing the clock synchronization. • key-id: Authentication key defined with the ntp authentication-key command. Administering the Device 14