Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wash: Adding a descriptive array of the enabled WPS configuration methods to json output #243

Open
He1my opened this issue Jun 11, 2018 · 5 comments

Comments

@He1my
Copy link

He1my commented Jun 11, 2018

What are your thoughts about adding an easier method to output the WPS configuration methods in json,
for example
"wps_config_methods": "2084", "wps_config_methods_str": ["Label", "Push Button", "Virtual Display"],

according to Wireshark the bit values for the WPS configuration methods are

.... .... .... ...1	USB
.... .... .... ..1.	Ethernet
.... .... .... .1..	Label
.... .... .... 1...	Display
.... .... ...1 ....	External NFC
.... .... ..1. ....	Internal NFC
.... .... .1.. ....	NFC Interface
.... .... 1... ....	Push Button
.... ...1 .... ....	Keybad
.... ..1. .... ....	Virtual Push Button
.... .1.. .... ....	Physical Push Button
..1. .... .... ....	Virtual Display
.1.. .... .... ....	Physical Display
@rofl0r
Copy link
Collaborator

rofl0r commented Jun 12, 2018

i've stated on several occasions that the existing json output will not be modified (apart from eventually adding new field), so users of it have the guarantee that their scripts (consuming the json) will keep working.

it's trivial to add code in your script that parses the raw config methods.

we could provide a tiny filter tool (in tools/) which takes the default wash output and modifies into the form suggested by you: ./wash -j -s -n 100 | ../tools/pimp_json.py | yourfinalscript.py

@He1my
Copy link
Author

He1my commented Jun 12, 2018

what is suggested here is adding a new field "wps_config_methods_str", I am well aware that there should not be any modification to existing fields

@rofl0r
Copy link
Collaborator

rofl0r commented Jun 12, 2018

PR welcome

@DJDan
Copy link

DJDan commented Jul 6, 2018

This already exists in wash 1.6.5-git-1-g140507a
wash -j json output has wps_config_methods .

@He1my
Copy link
Author

He1my commented Jul 6, 2018

This already exists in wash 1.6.5-git-1-g140507a
wash -j json output has wps_config_methods .

yes "wps_config_methods" is there, but that is not what this is about, it is about adding another field "wps_config_methods_str" that shows the enabled wps config method names instead of just the hex value to make things easier to understand

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants