Project

General

Profile

Actions

Bug #12959

open

dhcplease process wrongly update host file if client-hostname is empty

Added by Max Bal 3 months ago. Updated 3 months ago.

Status:
Feedback
Priority:
Normal
Assignee:
-
Category:
DHCP (IPv4)
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Plus Target Version:
Release Notes:
Default
Affected Version:
2.5.1
Affected Architecture:

Description

I've activated "Register DHCP leases in DNS forwarder" option.
I case where one of my device requests an IP without giving a hostname (which does not comply with RFC 2132), the file /var/dhcpd/var/db/dhcpd.leases contains entries like client-hostname "";
In that particular case, dhcplease process that writes in /etc/hosts puts the last non empty client-hostname value. Which makes DNS resolution points to an incorrect IP address...
Observed in 2.5.1 and also in 2.6.0

Actions #1

Updated by Jim Pingle 3 months ago

  • Category changed from DNS Forwarder to DHCP (IPv4)
Actions #2

Updated by Viktor Gurov 3 months ago

  • Status changed from New to Feedback

Unable to reproduce on 2.7.0.a.20220327.0600
Could you show an example of /var/dhcpd/var/db/dhcpd.leases entries? (you can replace sensitive data with ***)

Actions #3

Updated by Max Bal 3 months ago

lease 172.16.8.16 {
starts 1 2022/03/28 15:23:31;
ends 1 2022/03/28 15:25:01;
cltt 1 2022/03/28 15:23:31;
binding state active;
next binding state free;
rewind binding state free;
dynamic-bootp;
hardware ethernet :**::b5:07:f2;
uid "\000SWITCH";
client-hostname "";
}

Actions

Also available in: Atom PDF