the-useless-one / pywerview

A (partial) Python rewriting of PowerSploit's PowerView
GNU General Public License v3.0
921 stars 114 forks source link

get-netuser, get-netcomputer return custom --attributes #35

Closed 99red closed 3 years ago

99red commented 5 years ago

get-netuser, get-netcomputer can now return specific attributes from the command line.

Ex: ./pywerview.py get-netuser -t 10.13.37.1 -u user -p pw -w corp --attributes samaccountname Ex: ./pywerview.py get-netcomputer -t 10.13.37.1 -u user -p pw -w corp --attributes dnshostname operatingsystem serviceprincipalname

Possibly good idea to move --attributes argument parsing to adparser, but i don't see how we can cleanly implement the receiving of arguments in pywerview/cli/helpers.py get functions without majorly refactoring either the function prototypes, or the calling function in pywerview/cli/main.py (other than hacking in ignoreargs, **ignorekwargs).