MartijnBraam / python-isc-dhcp-leases

Small python module for reading /var/lib/dhcp/dhcpd.leases from isc-dhcp-server

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

iaid endianness/signed incorrect

freddy36 opened this issue · comments

iaid is incorrectly unpacked (wrong endianess and as signed integer), it should be:
self.iaid = struct.unpack('<I', self.host_identifier[0:4])[0]
instead of
self.iaid = struct.unpack('>i', self.host_identifier[0:4])[0

Oops, changed it