Git Product home page Git Product logo

Comments (2)

ring04h avatar ring04h commented on August 14, 2024

dnsfunc.py get_ns_record() function 的定义如下,做过遍历处理

def get_ns_record(domain):
    domains = {'ns':[]}
    domains['is_zone_vul'] = False
    # print 'process domain ns record: %s' % domain
    try:
        ns = _res.query(domain, 'NS')
        for i in ns.response.answer:
            ns_record = []
            for j in i.items:
                ns_name = j.to_text().rstrip('.')
                if check_whitelist(ns_name):
                    print '* %s in whitelist' % ns_name
                else:
                    if is_zone_transfer_vul(ns_name, domain):
                        print '* %s zone_transfer_vul exist' % ns_name
                        print '-' * 50
                        if domains['is_zone_vul'] == True:
                            # 已经处理过一次域传送漏洞
                            pass
                        else:
                            domains['is_zone_vul'] = True
                            domains['zone'] = get_zone_record(ns_name, domain)
                    else:
                        print '* %s zone_transfer_vul not exist' % ns_name
                ns_record.append(ns_name)
        # NS解析记录写入总域名表
        domains['ns'] = ns_record
        return domains
    except Exception, e:
        # print e
        return domains

from wydomain.

s3y avatar s3y commented on August 14, 2024
dig +trace zju.edu.cn ns

通过从根服务器递归可以得到完整的 NS LIST

from wydomain.

Related Issues (20)

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.