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

Revises --fuzzers argument docs #198

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bwolfe-corvus
Copy link

  • If used with no arguments, prints available fuzzers
  • default fuzzer list matches with generate() function's possible defaults

Resubmitting with a simpler change. You were right in that I did not originally notice that the various and tld-swap fuzzers weren't tied to class methods. Since I'm only looking to do a change that affects ease of usage, I just tried to match up the --fuzzers argument with how the default fuzzers are used within the generate() function as a preset list.

Original output sample:

$ python dnstwist.py --fuzzers --format list contoso.com
usage: dnstwist.py [OPTION]... DOMAIN
dnstwist.py: error: argument --fuzzers: expected one argument

New output:

$ python dnstwist.py --fuzzers --format list contoso.com
usage: dnstwist.py [OPTION]... DOMAIN
dnstwist.py: error: argument --fuzzers requires a comma-separated list of fuzzers.
Available fuzzers: addition, bitsquatting, cyrillic, homoglyph, hyphenation, insertion, omission, repetition, replacement, subdomain, transposition, vowel-swap, dictionary, tld-swap, various

I intentionally did not wrap the docstring error output to a specific width, as I didn't see that as a behavior in other parts of the code. However, I found that Python's stdlib has a textwrap module going back to 2.7, so if that's something of interest, I will wrap this output appropriately.

Forgive the double PR, I blew up my forked repo and had to resubmit a PR from a clean state.

- If used with no arguments, prints available fuzzers
- default fuzzer list matches with generate() function's possible defaults
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

Successfully merging this pull request may close these issues.

None yet

1 participant