Git Product home page Git Product logo

fess_up's People

Contributors

donnchac avatar johnlunney avatar nosmo avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

fess_up's Issues

Missing install_requires=['pyyaml']

Steps to reproduce:

$ virtualenv /tmp/sandbox
$ /tmp/sandbox/bin/pip install fess_up
$ /tmp/sandbox/bin/fess_up.py
Traceback (most recent call last):
  File "/tmp/sandbox/bin/fess_up.py", line 20, in <module>
    import yaml
ImportError: No module named yaml

NameError: name 'codes' is not defined

When running fess-up.py

python fess-up.py   
Traceback (most recent call last):
  File "./fess-up.py", line 29, in <module>
    import dnsnames
  File "/home/l/documents/fess-up/src/dnsnames/__init__.py", line 15, in <module>
    dnsnames += set(codes)
NameError: name 'codes' is not defined

Search for common TXT records

This is an edge case and not part of the common scanning flow but fess-up needs to check for records like _domainkey

Get MX records before wildcard check

The nature of wildcard records messes up our scan for the most part, but it doesn't mean that we can't get TXT and MX records for @. Make sure these are queried before DomainScans return.

Script name conflicts with package name

Steps to reproduce:

$ virtualenv /tmp/sandbox
$ /tmp/sandbox/bin/pip install fess_up pyyaml
$ /tmp/sandbox/bin/fess_up.py
Traceback (most recent call last):
  File "/tmp/sandbox/bin/fess_up.py", line 23, in <module>
    from fess_up import dnsnames, DomainScan
  File "/tmp/sandbox/bin/fess_up.py", line 23, in <module>
    from fess_up import dnsnames, DomainScan
ImportError: cannot import name dnsnames

This happens because Python adds the directory containing the script to the beginning of sys.path, and then 'from fess_up import ...' finds fess_up.py in the script directory instead of finding fess_up/__init__.py in the site-packages directory.

Suggested fix: rename the script to not have the .py extension.

dns.name.EmptyLabel

 % python fess-up.py -c ../conf/fess-up.yaml google.ca
google.ca
  File "fess-up.py", line 159, in <module>
    main(args.domains, mysql_config)
  File "fess-up.py", line 131, in main
    domain_scanner.runScan()
  File "fess-up.py", line 63, in runScan
    for subdomain, record in self._scan("A").iteritems():
  File "fess-up.py", line 87, in _scan
    answers = dns.resolver.query("%s" % (query_str), record_type)
  File "/usr/lib/python2.7/dist-packages/dns/resolver.py", line 770, in query
    raise_on_no_answer)
  File "/usr/lib/python2.7/dist-packages/dns/resolver.py", line 602, in query
    qname = dns.name.from_text(qname, None)
  File "/usr/lib/python2.7/dist-packages/dns/name.py", line 637, in from_text
    raise EmptyLabel
dns.name.EmptyLabel

Seems to work OK if I add

            try:
                answers = dns.resolver.query("%s" % (query_str), record_type)
            except (dns.resolver.NXDOMAIN, dns.resolver.NoAnswer, dns.name.EmptyLabel):
                continue

Python DNS timeouts stop DNS record processing

Fess up will not return DNS records if resolving any domain results in a Timeout() exception being raised from the Python DNS library.

Traceback (most recent call last):
<!-- SNIP -->
  File "/usr/local/lib/python2.7/dist-packages/fess_up/domainscan.py",
line 36, in runScan
    for subdomain, record in self._scan("NS").iteritems():
  File "/usr/local/lib/python2.7/dist-packages/fess_up/domainscan.py",
line 64, in _scan
    answers = self.resolver.query("%s" % (query_str), record_type)
  File "/usr/lib/python2.7/dist-packages/dns/resolver.py", line 826, in
query
    timeout = self._compute_timeout(start)
  File "/usr/lib/python2.7/dist-packages/dns/resolver.py", line 739, in
_compute_timeout
    raise Timeout
Timeout

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.