Server IP : 104.244.120.118  /  Your IP : 216.73.216.198
Web Server : Apache
System : Linux ded5817.inmotionhosting.com 5.14.0-741.22.1.el9_9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Nov 12 14:34:46 UTC 2026 x86_64
User : persoanlinjuryla ( 1006)
PHP Version : 8.5.13
Disable Function : exec,passthru,shell_exec,system
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF
Directory (0555) :  /../../opt/dedrads/python/../python/../mailparse/../python/../python/../python/../

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : //../../opt/dedrads/python/../python/../mailparse/../python/../python/../python/../check_dns
#!/usr/lib/rads/venv/bin/python3
# written by ChaseS
import argparse
from python import audit_dns, humanize


def get_args():
    parser = argparse.ArgumentParser(description=__doc__)
    usergroup = parser.add_mutually_exclusive_group()
    usergroup.add_argument(
        '-u',
        '--user',
        action='store',
        dest='User',
        default=False,
        help='Define your User',
    )

    usergroup.add_argument(
        '-s',
        '--server',
        action='store_true',
        dest='Server',
        default=False,
        help='Check DNS for full server rather than one domain',
    )

    usergroup.add_argument(
        '-d',
        '--domain',
        action='store',
        dest='Domain',
        default=False,
        help='Audit dns by domain',
    )

    parser.add_argument(
        '-l',
        '--long',
        action='store_true',
        default=False,
        dest='longview',
        help='Show full rather than parsed results',
    )

    parser.add_argument('--version', action='version', version='%(prog)s 1.0')

    results = parser.parse_args()
    return results


def print_humanized(args):
    print('Please be patient. This takes a while.')
    if args.Server is True:
        humanize.h_check_dns(
            data=audit_dns.server(), external_check=True, longview=args.longview
        )
    elif args.Domain is not False:
        humanize.h_check_dns(
            data=audit_dns.domain(args.Domain),
            external_check=True,
            longview=args.longview,
        )
    elif args.User is not False:
        humanize.h_check_dns(
            data=audit_dns.user(args.User),
            external_check=True,
            longview=args.longview,
        )


def main():
    args = get_args()
    print_humanized(args)


if __name__ == "__main__":
    main()