# Some Php Snmp Scripting

I was digging through some of my old notes and came across a few SNMP networking PHP scripts that I put together for some Proxim AP-4000 access points. I put this script and many others together to help manage these standalone access points before there were wireless controllers. This particular PHP script sets up a while loop to modify some SNMP values to modify AP filters. The SNMP values within this script can be modified to be used in changing other values as well. Your setup will require PHP installed along with the SNMP package. Have fun.

<?php //set the variable that will be the start number of the third octet within your IP range

$ip = 100; //set your snmp RW password$snmpRwPass = yoursnmppassword;

//setup the loop that will snmpset each AP mgmt IP address defined starting at your IP variable and completing before your max value

while ( $ip <= 111) { //modifies snmp values of Proxim AP-4000 filters snmpset(“192.168.1.$ip”,”$snmpRwPass”,”.1.3.6.1.4.1.11898.2.1.5.5.3.1.6.1″,”i”,”1″, “10”); snmpset(“192.168.1.$ip”,”$snmpRwPass”,”.1.3.6.1.4.1.11898.2.1.5.5.3.1.6.2″,”i”,”1″, “10”); snmpset(“192.168.1.$ip”,”$snmpRwPass”,”.1.3.6.1.4.1.11898.2.1.5.5.3.1.6.3″,”i”,”1″, “10”); snmpset(“192.168.1.$ip”,”$snmpRwPass”,”.1.3.6.1.4.1.11898.2.1.5.5.1.0″, “i”,”1″, “10”); //print output of each AP mgmt IP thats completed echo “done with 192.168.1.”.$ip; echo “
”;

//counter for increasing AP mgmt IP

\$ip++;

} ?>

@javi_isolis