Ejemplo n.º 1
0
def get_card(reader):
    # create connection
    connection = reader.createConnection()
    connection.connect()

    # do stuff with CAC
    card = CAC(connection)
    card.select_nist_piv()
    return card
Ejemplo n.º 2
0
    # Let the user the select a reader
    if len(reader_list) > 1:
        print "Please select a reader"
        idx = 0
        for r in reader_list:
            print "  %d - %s" % (idx, r)
            idx += 1

        reader_idx = -1
        while reader_idx < 0 or reader_idx > len(reader_list) - 1:
            reader_idx = int(
                raw_input("Reader[%d-%d]: " % (0, len(reader_list) - 1)))

        reader = reader_list[reader_idx]
    else:
        reader = reader_list[0]

    print "Using: %s" % reader

    # create connection
    connection = reader.createConnection()
    connection.connect()

    # do stuff with CAC
    card = CAC(connection)
    card.select_nist_piv()

    # Call our fuzzer
    fuzzer(card)
Ejemplo n.º 3
0
    
    # Let the user the select a reader
    if len(reader_list) > 1:
        print "Please select a reader"
        idx = 0
        for r in reader_list:
            print "  %d - %s"%(idx,r)
            idx += 1
            
        reader_idx = -1
        while reader_idx < 0 or reader_idx > len(reader_list)-1:
            reader_idx = int(raw_input("Reader[%d-%d]: "%(0,len(reader_list)-1)))
        
        reader = reader_list[reader_idx]
    else:
        reader = reader_list[0]
    
    print "Using: %s" % reader
    
    # create connection
    connection = reader.createConnection()
    connection.connect()
    
    # do stuff with CAC
    card = CAC(connection)
    card.select_nist_piv()

    # Call our fuzzer
    fuzzer(card)