Beispiel #1
0
def get(args):
    import processing
    password = getPassword(args)
    t = token(args.username, password, args.server)
    if args.__dict__.get('search'):
        keyword = args.search
    else:
        keyword = ''
    if args.__dict__.get('domain'):
        domain = args.domain
        processing.getZone(args.server, t, domain, keyword)
    else:
        processing.getAllZone(args.server, t)
Beispiel #2
0
def get(args):
    import processing
    password = getPassword(args)
    t = token(args.username, password, args.server)

    # When using '--search' option
    if args.__dict__.get('search'):
        keyword = args.search

    else:
        keyword = ''

    # When specified zone
    if args.__dict__.get('domain'):
        domain = args.domain
        processing.getZone(args.server, t, domain, keyword)

    # When get all zones
    else:
        processing.getAllZone(args.server, t)