The dhcp server database authentication-mode command configures the integrity authentication mode for the lease.txt and conflict.txt files.
The undo dhcp server database authentication-mode command restores the integrity authentication mode of the lease.txt and conflict.txt files to check.
By default, the file integrity authentication mode is check.
Parameter | Description | Value |
---|---|---|
check |
Indicates that the authentication mode is check. If the file is a historical version file that does not carry the file integrity authentication code, the data is directly restored. If the file is a new version file that carries the file integrity authentication code, the file integrity authentication is performed before the data is restored. |
- |
no-check |
Indicates that the file integrity authentication is not performed and data is directly restored. |
- |
force-check |
Indicates that the authentication mode is force-check. If the file is a historical version file that does not carry the file integrity authentication code, the data is not restored. If the file is a new version file that carries the file integrity authentication code, the file integrity authentication is performed before the data is restored. |
- |
Usage Scenario
To prevent data loss caused by device faults, you can enable the DHCPv4 address pool data saving and restoration functions. The system generates lease.txt and conflict.txt files in the dhcp folder to save normal address lease information and address conflict information, respectively. To prevent the lease.txt and conflict.txt files from being tampered with, the encrypted file integrity authentication code is added to the lease.txt and conflict.txt files. After the device is restarted, the system decrypts the file integrity authentication code and verifies the file integrity based on the decrypted file integrity authentication code before restoring the address lease information and address conflict information from the lease.txt and conflict.txt files. If the verification is successful, the data is restored. If the verification fails, the data is discarded and a log is recorded.
Precautions