Exemplo n.º 1
0
def init_device(dev):
    reset_device(dev)

    #install everythings!

    #install rilcap, if not root ERROR
    if not superuserutils.install_rilcap_shell(dev):
        exit()

    #install eircar
    install('eicar', dev)

    #install BusyBox
    adb.install_busybox('assets/busybox-android', dev)
Exemplo n.º 2
0
def init_device(dev):
    reset_device(dev)

    #install everythings!

    #install rilcap, if not root ERROR
    if not superuserutils.install_rilcap_shell(dev):
        exit()

    #install eircar
    install('eicar', dev)

    #install BusyBox
    adb.install_busybox('assets/busybox-android', dev)
Exemplo n.º 3
0
def pre_test(device):
    print "###########################################"
    print "##### STAGE 0: PREPARING TEST         #####"
    print "###########################################"
    dev = device.serialno

    #STEP 0.1: uninstall agent
    print "#STEP 0.1: uninstall agent"
    apk_instance = apk_dataLoader.get_apk('agent')
    apk_instance.clean(dev)

    #STEP 0.2: delete wifimanager!
    print "#STEP 0.2: delete wifimanager!"
    apk_instance = apk_dataLoader.get_apk('wifi_enabler')
    apk_instance.clean(dev)


    #STEP 0.3: delete ALL the avs!
    print "#STEP 0.3: delete ALL the avs!"
    for av_to_delete in avs_all:
        av_instance = apk_dataLoader.get_apk_av(av_to_delete)
        av_instance.clean(dev)

    #STEP 0.4: delete EICAR virus
    print "#STEP 0.6: installing EICAR virus"
    eicar_instance = apk_dataLoader.get_apk('eicar')
    eicar_instance.clean(dev)

    #STEP 0.5: install rilcap
    print "#STEP 0.4: install rilcap using: %s"
    if not superuserutils.install_rilcap_shell(dev):
        exit()

    #STEP 0.6: set wifi to 'protected' network with no access to internet
    print "#STEP 0.5: set wifi to 'protected' network with no access to internet"
    wifiutils.start_wifi_av_network(dev)

    #STEP 0.7: installing EICAR virus
    print "#STEP 0.6: installing EICAR virus"
    eicar_instance = apk_dataLoader.get_apk('eicar')
    eicar_instance.install(dev)

    #STEP 0.8: installing BusyBox
    print "#STEP 0.8: installing BusyBox"
    adb.install_busybox('assets/busybox-android')
Exemplo n.º 4
0
def pre_test(device):
    print "###########################################"
    print "##### STAGE 0: PREPARING TEST         #####"
    print "###########################################"
    dev = device.serialno

    #STEP 0.1: uninstall agent
    print "#STEP 0.1: uninstall agent"
    apk_instance = apk_dataLoader.get_apk('agent')
    apk_instance.clean(dev)

    #STEP 0.2: delete wifimanager!
    print "#STEP 0.2: delete wifimanager!"
    apk_instance = apk_dataLoader.get_apk('wifi_enabler')
    apk_instance.clean(dev)

    #STEP 0.3: delete ALL the avs!
    print "#STEP 0.3: delete ALL the avs!"
    for av_to_delete in avs_all:
        av_instance = apk_dataLoader.get_apk_av(av_to_delete)
        av_instance.clean(dev)

    #STEP 0.4: delete EICAR virus
    print "#STEP 0.6: installing EICAR virus"
    eicar_instance = apk_dataLoader.get_apk('eicar')
    eicar_instance.clean(dev)

    #STEP 0.5: install rilcap
    print "#STEP 0.4: install rilcap using: %s"
    if not superuserutils.install_rilcap_shell(dev):
        exit()

    #STEP 0.6: set wifi to 'protected' network with no access to internet
    print "#STEP 0.5: set wifi to 'protected' network with no access to internet"
    wifiutils.start_wifi_av_network(dev)

    #STEP 0.7: installing EICAR virus
    print "#STEP 0.6: installing EICAR virus"
    eicar_instance = apk_dataLoader.get_apk('eicar')
    eicar_instance.install(dev)

    #STEP 0.8: installing BusyBox
    print "#STEP 0.8: installing BusyBox"
    adb.install_busybox('assets/busybox-android')