mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-05 19:23:49 +00:00
Update provision.php
This commit is contained in:
@@ -115,14 +115,25 @@ include "root.php";
|
||||
$row = $prep_statement->fetch();
|
||||
$count = $row['count'];
|
||||
if ($row['count'] > 0) {
|
||||
return true;
|
||||
$mac_exists = true;
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
$mac_exists = false;
|
||||
}
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
$mac_exists = false;
|
||||
}
|
||||
if ($mac_exists) {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
//log the invalid mac address attempt to the syslog server
|
||||
openlog("FusionPBX", LOG_PID | LOG_PERROR, LOG_LOCAL0);
|
||||
syslog(LOG_WARNING, '['.$_SERVER['REMOTE_ADDR']."] invalid mac address ".$mac);
|
||||
closelog();
|
||||
//invalid mac address return false
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user