ericgarnel Tue, 08/26/2008 - 07:28
User Badges:
  • Gold, 750 points or more

Do you have a wireless control server? It would do it for you. Otherwise, you would have to determine the proper OIDS & other info and use an snmpset to do it via snmp 2c read/write community. You would most likely have to snmpwalk the controller and weed out the correct string to get the values for the ssid

gmoroni Tue, 08/26/2008 - 07:32
User Badges:

Hi eric,

tnx for the answer

actually I don't usa a WCS.

But if it can simplify my life about SNMP for WLC... why not.



ericgarnel Tue, 08/26/2008 - 07:40
User Badges:
  • Gold, 750 points or more

The WLC will make your life easier as you add more controllers & APs. I have 4 controllers and the WCS, but still make my changes on the controllers out of habit.

jmmerritt Mon, 10/26/2009 - 05:17
User Badges:

The method I have used is;


snmpwalk -c -v 2c enterprises.9.9.512.1.1.1.1.4


This will return an index list of the SSID's that you have defined on the controller. Ie;


SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.1 = STRING: "Widget Inc."

SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.2 = STRING: "Guest"

SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.3 = STRING: "Lab"


Then, set the PSK of the SSID based on the index value (the last number in the OID) ;


ie.


snmpset -c -v 2c enterprises.9.9.521.1.1.1.1.7.x i 3 enterprises.9.9.521.1.1.1.1.8.x string

where x is the index value.


So, for example to set the Guest SSID for controler 10.10.1.1;


snmpwalk -c -v 2c 10.10.1.1 enterprises.9.9.512.1.1.1.1.4


returns;


SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.1 = STRING: "Widget Inc."

SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.2 = STRING: "Guest"


2 is the index value for the Guest SSID.


To set the PSK to 0011001100 (not recommeneded!) then;


snmpset -c -v 2c 10.10.1.1 enterprises.9.9.521.1.1.1.1.7.2 i 3 enterprises.9.9.521.1.1.1.1.8.2 string 0011001100



I hope that explains it easily enough.


If anyone can find a way of reading back the PSK once set, I'd be grateful! I haven't been able to do that yet!



Denis Orlov Mon, 02/01/2016 - 00:56
User Badges:

If someone need to change PSK key for WLAN using SNMP, the working example is bellow. I hope this save time for somebody and you can take a cup of coffie instead spend time in Google, trying to find correct solution.

1) First of all using snmp we can get id of each existing WLAN:
snmpwalk -v 2c -c test123 x.x.x.x enterprises.9.9.512.1.1.1.1.4
SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.1 = STRING: "WLAN1"
SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.2 = STRING: "WLAN2"
SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.3 = STRING: "WLAN3"
SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.4 = STRING: "WLAN4"
SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.5 = STRING: "WLAN5"
SNMPv2-SMI::enterprises.9.9.512.1.1.1.1.4.6 = STRING: "WLAN6"

2) Than, we can set PSK for specific WLAN using this command:
snmpset -v 2c -c test123 x.x.x.x  enterprises.9.9.521.1.1.1.1.7.5 i 3 enterprises.9.9.521.1.1.1.1.8.5 s "94621518"
where
"test123" - snmp RW community
"94621518" - new PSK for our WLAN
"x.x.x.x" - WLC IP-address



P.S. Tested on Cisco AIR-CTVM-K9 with OS version - "8.1.102.0"

Actions

This Discussion

 

 

Trending Topics - Security & Network