ArubaOS 8.6.0.0Help Center
You are here: Home > External User Management > Sample Scripts > Querying a User

Querying a User

ThisXMLExtensible Markup Language. XML is a markup language that defines a set of rules for encoding documents in a format that is both human-readable and machine-readable.request uses theuser_querycommand to get the status and details of a user connected to your network.

C:\Python27>python ArubaXMLDemo.py --switch-ip=192.0.2.1 --secret=aruba123 --command=user_query --ip=192.0.2.2

The command sends the following information in theXMLExtensible Markup Language. XML is a markup language that defines a set of rules for encoding documents in a format that is both human-readable and machine-readable.request toMobility Master:

--switch-ip: IP address ofMobility Master

--secret: Shared secret key (sent as plain text)

--command:XMLExtensible Markup Language. XML is a markup language that defines a set of rules for encoding documents in a format that is both human-readable and machine-readable.APIApplication Programming Interface. Refers to a set of functions, procedures, protocols, and tools that enable users to build application software.command

--ip: IP address of the user

Mobility MasterResponse

Mobility Masterprocesses using anXMLExtensible Markup Language. XML is a markup language that defines a set of rules for encoding documents in a format that is both human-readable and machine-readable.format and sends the following response to theXMLExtensible Markup Language. XML is a markup language that defines a set of rules for encoding documents in a format that is both human-readable and machine-readable.APIApplication Programming Interface. Refers to a set of functions, procedures, protocols, and tools that enable users to build application software.server.

Prepared XML buf

---------------------------------

xml=

< ipaddr > 192.0.2.2 < / ipaddr >

cleartext

aruba123

1.0

---------------------------------

Sending XML request to https://192.0.2.1/auth/command.xml

Controller response status: 200

Response XML

-----------------------------------

Ok

0

a4:5e:60:c3:10:59

< ipaddr > 192.0.2.2 < / ipaddr >

John

authenticated

Wireless

1034

ap225-sales

00:03:51

Authenticated

clearpass-hq1

802.1X

ethersphere-wpa2

9c:1c:12:92:2e:f1

a-VHT-80

Wireless

93400

24947332

89042

79397284

Mobility MasterCLI

The output of theshow usercommand displays the client information.

(host) #show user

Users

-----

IP MAC Name Role Age(d:h:m) Auth VPN link

---------- ------------ ------ ---- ---------- ---- --------

192.0.2.2 a4:5e:60:c3:10:59 John authenticate 00:03:51 Authenticated

AP name Roaming Essid/Bssid/Phy Profile Forward mode

------- -------- --------------- ------- ------------

ap225-sales Wireless ethersphere-wpa2/9c:1c:12:92:2e:f1/a-VHT-80

Type Host Name

---- ---------

User Entries: 1/1

/*]]>*/
Baidu