diff --git a/.gitignore b/.gitignore index 588ef51..025ab81 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,5 @@ design db config.php scanner/pamela.log +mac_log.csv +mac_log.csv.complete diff --git a/admin.php b/admin.php new file mode 100755 index 0000000..e0ca8ed --- /dev/null +++ b/admin.php @@ -0,0 +1,31 @@ + +
+ + + + + + + diff --git a/associate.php b/associate.php new file mode 100755 index 0000000..5dfc83e --- /dev/null +++ b/associate.php @@ -0,0 +1,77 @@ + 0){ + return true;} + else { return false; } + } + +$arp_found = false; + + function arp_lookup($ip) { + global $arp_found; + + $arp = shell_exec("/usr/sbin/arp -a | grep $ip"); + preg_match('/at ([0-9a-f]{2}[: ]){6}/i',$arp,$matches); + if(sizeof($matches) > 0) { + $mac = split(" ",$matches[0]); + $arp_found = true; + return $mac[1]; + } + else { + $arp_found = false; + return ""; + } + } +include('header-inc.php'); +?> + + +