Software: Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.12 with Suhosin-Patch mod_ssl/2.2.8 OpenSSL/0.9.8g. PHP/5.2.4-2ubuntu5.12 uname -a: Linux forum.circlefusion.com 2.6.24-19-server #1 SMP Wed Jun 18 15:18:00 UTC 2008 i686 uid=33(www-data) gid=33(www-data) groups=33(www-data) Safe-mode: OFF (not secure) /usr/share/doc/ifupdown/examples/ drwxr-xr-x |
Viewing file: check-mac-address.sh (496 B) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) | #!/bin/sh # # Checks if the given interface matches the given ethernet MAC. # If it does it exits with 0 (success) status; # if it doesn't then it exists with 1 (error) status. set -e export LANG=C if [ ! "$2" ] ; then echo "Usage: $0 IFACE targetMAC" exit 1 fi iface="$1" targetmac=`echo "$2" | sed -e 'y/ABCDEF/abcdef/'` mac=$(/sbin/ifconfig "$iface" | sed -n -e '/^.*HWaddr \([:[:xdigit:]]*\).*/{s//\1/;y/ABCDEF/abcdef/;p;q;}') if [ "$targetmac" = "$mac" ]; then exit 0; else exit 1; fi |
:: Command execute :: | |
--[ c99shell v.2.1 [PHP 7 Update] [1.12.2019] maintained by KaizenLouie and updated by cermmik | C99Shell Github (MySQL update) | Generation time: 0.0056 ]-- |