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

Domain does not gets formatted automatically due to which command fails #66

Open
0cirius0 opened this issue Dec 15, 2020 · 2 comments
Open

Comments

@0cirius0
Copy link

I tried to execute it from within a python code but it kept failing. I tried took the DEBUG output and matched it wih when the command is run directly from shell.
I tcame out to be that when I provide a list of domains from within another python code then the domains aren't being converted from google.com to http://google.com:80 due to which the command fails.

Screenshot when ran inside python
Screenshot from 2020-12-15 19-23-54

Screenshot when ran directly
Screenshot from 2020-12-15 19-24-52

@maaaaz
Copy link
Owner

maaaaz commented Dec 15, 2020

Hello @hellrider9,

It fails because the list of targets you pass (through lines variable) is not properly parsed and formatted. You should pass lines like http://google.com and not google.com :

  • Look at the url_list items' format in the sample code
  • When you run through CLI, the inputs are first parsed with this function, that explains why it is successful in your case
    url_list = parse_targets(options)

In a next release, I will upgrade the parse_targets function to be able to accept to parse a programmatic list as parameter, not only the options parameter, and then update the wiki.
Basically after this change:

  • This url_list = ['http://google.fr', 'http://google.com']
  • Will then become url_list = parse_targets(custom_list=['http://google.fr', 'http://google.com'])

Cheers.

@0cirius0
Copy link
Author

Thanks.

Just for the heads up, when can I expect then next release.

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

2 participants