Changed trigger for mac address line to avoid conflicts with option82 data containing word 'ethernet'

This commit is contained in:
Kristoffer Bylund 2021-08-19 12:44:23 +02:00
parent 10102a6709
commit 1d72a13f0a
1 changed files with 1 additions and 1 deletions

View File

@ -65,7 +65,7 @@ module.exports = {
}
dhcp_lease_data[ip_address].end = end_unix_time;
}
if (/ethernet/i.test(lines[l])) {
if (/hardware ethernet/i.test(lines[l])) {
if (typeof line_data_arg[2] !== "undefined") {
dhcp_lease_data[ip_address].mac = line_data_arg[2].replace(/;/gi, '').trim();