| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
Parser for iw and iwinfo on OpenWrt devices. Currently supports only device list and connected stations data. Output from iw and iwinfo on other platforms might work, but it's not tested.
python -m pip install -U ap-parseLog in to the device via SSH and run the the command of choice. Feed the output to ap-parse either programmatically or via the CLI.
List devices with iw:
iw devList stations with iw:
iw dev <device name> station dumpList devices with iwinfo:
iwinfoList stations with iwinfo:
iwinfo <device name> assoclistPipe the command output to ap-parse. Example for iwinfo device list:
ssh <user@host> iwinfo | python -m apparse iwinfo device
| Argument | Type | Values | Description |
|---|---|---|---|
| backend | str | iw, iwinfo | Utility used to generate the output data |
| type | str | device, station | Type of the output data |
Save the command output to a file and pass it as a string to the appropriate parser. Example for iwinfo device list:
ssh <user@host> iwinfo > output.txtimport apparse
with open('output.txt', 'r', encoding='utf-8') as f:
raw_data = f.read()
parsed_data = apparse.parse_iwinfo_station(raw_data)
print(parsed_data)In case you wish to add or remove fields or modify regexes, subclass one of the parser classes under its respective module apparse.*_parser.
MIT license. See LICENSE for more information.
| Back | FazBrowse Home | New Git URL |