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

Getting same error on 2 different machine on both python 2.7 & 3.6 #21

Closed
0xPrial opened this issue Jan 1, 2019 · 4 comments
Closed

Comments

@0xPrial
Copy link

0xPrial commented Jan 1, 2019

Traceback (most recent call last):
File "cloudflair.py", line 166, in
main(args.domain, args.output_file, censys_api_id, censys_api_secret)
File "cloudflair.py", line 137, in main
origins = find_origins(domain, hosts)
File "cloudflair.py", line 127, in find_origins
page_similarity = similarity(response.text, original_response.text)
File "/usr/local/lib/python2.7/site-packages/html_similarity/similarity.py", line 6, in similarity
return k * structural_similarity(document_1, document_2) + (1 - k) * style_similarity(document_1, document_2)
File "/usr/local/lib/python2.7/site-packages/html_similarity/structural_similarity.py", line 29, in structural_similarity
tags1 = get_tags(document_1)
File "/usr/local/lib/python2.7/site-packages/html_similarity/structural_similarity.py", line 10, in get_tags
for el in doc.getroot().iter():
AttributeError: 'NoneType' object has no attribute 'iter'

@0xPrial
Copy link
Author

0xPrial commented Jan 1, 2019

Tried with python 3.6 & 3.7 same error on different machine .

@christophetd
Copy link
Owner

Thank you for the report. Can you provide me with the domain you ran the scan on? You can DM it to me on Twitter, I'll keep it private and only use it to attempt to reproduce the issue.

@0xPrial
Copy link
Author

0xPrial commented Jan 3, 2019

Sure check your twitter :D

Also I get below error for python2.7 :-

[*] Retrieving Cloudflare IP ranges from https://www.cloudflare.com/ips-v4
Traceback (most recent call last):
  File "cloudflair.py", line 166, in <module>
    main(args.domain, args.output_file, censys_api_id, censys_api_secret)
  File "cloudflair.py", line 135, in main
    hosts = find_hosts(domain, censys_api_id, censys_api_secret)
  File "cloudflair.py", line 21, in find_hosts
    if not dns_utils.is_valid_domain(domain):
  File "/Users/CloudFlair/dns_utils.py", line 5, in is_valid_domain
    dns.resolver.query(domain, 'A')
  File "build/bdist.macosx-10.9-x86_64/egg/dns/resolver.py", line 1100, in query
  File "build/bdist.macosx-10.9-x86_64/egg/dns/resolver.py", line 911, in query
  File "build/bdist.macosx-10.9-x86_64/egg/dns/query.py", line 319, in udp
  File "build/bdist.macosx-10.9-x86_64/egg/dns/query.py", line 265, in receive_udp
  File "build/bdist.macosx-10.9-x86_64/egg/dns/message.py", line 821, in from_wire
  File "build/bdist.macosx-10.9-x86_64/egg/dns/message.py", line 744, in read
  File "build/bdist.macosx-10.9-x86_64/egg/dns/message.py", line 619, in _get_question
  File "build/bdist.macosx-10.9-x86_64/egg/dns/name.py", line 973, in from_wire
AttributeError: 'str' object has no attribute 'unwrap'

@christophetd
Copy link
Owner

Thanks, bug reproduced. Should be fixed in latest master.

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