ISC DHCP V3.0pl2: Unproper handling of -user & -group
Thomas Preissler
tomjohn at gmx.de
Mon Nov 3 23:32:01 UTC 2003
Hello folks,
I just figured out a problem with ISC DHCPD V3.0pl2.
I use "-user dhcp -group dhcp" on my actual Gentoo.
DHCPD starts, but when it wants to write the lease file, I get
Nov 3 22:29:42 [dhcpd] Can't create new lease file: Permission denied
/var/lib/dhcp/dhcpd.leases is of course dhcp:dhcp. After DHCPD
starts up, that file shows up as root:root.
I did
strace -f /usr/sbin/dhcpd -user dhcp -group dhcp eth0,br0 2>&1 | less
shows me:
...
fsync(5) = 0
unlink("/var/lib/dhcp/dhcpd.leases~") = 0
link("/var/lib/dhcp/dhcpd.leases", "/var/lib/dhcp/dhcpd.leases~") = 0
rename("/var/lib/dhcp/dhcpd.leases.1067901142", "/var/lib/dhcp/dhcpd.leases") = 0
socket(PF_INET, SOCK_DGRAM, IPPROTO_UDP) = 6
ioctl(6, 0x8912, 0xbfffe998) = 0
ioctl(6, 0x8912, 0xbfffe998) = 0
...
Sorry, but could it be, that the renaming of the file lets the permissions
untouched, i.e. root:root, and not dhcp:dhcp, as passed as
parameters?
Just ask for any further information...
Greets,
Tom
More information about the dhcp-hackers
mailing list