Пример #1
0
        # remove old startup
        if os.path.isfile("/etc/init.d/tap"): os.remove("/etc/init.d/tap")

        # startup script here
        fileopen = open("src/core/startup_tap", "r")
        config = fileopen.read()
        filewrite = open("/etc/init.d/tap", "w")
        filewrite.write(config)
        filewrite.close()
        print("[*] Triggering update-rc.d on TAP to automatic start...")
        subprocess.Popen("chmod +x /etc/init.d/tap", shell=True).wait()
        subprocess.Popen("update-rc.d tap defaults", shell=True).wait()

    # setting background
    print("[*] Setting background..")
    set_background()

    # install git and update everything
    print("[*] Updating everything beforehand...")
    subprocess.Popen(
        "apt-get update && apt-get --force-yes -y upgrade && apt-get --force-yes -y dist-upgrade",
        shell=True).wait()
    subprocess.Popen(
        "apt-get --force-yes -y install git python-crypto python-pexpect openssh-server",
        shell=True).wait()
    from Crypto.Cipher import AES
    choice = input(
        "Do you want to keep TAP updated? (requires internet) [y/n]: ")
    if choice == "y" or choice == "yes":
        print("[*] Checking out latest TAP to /usr/share/tap")
        # if old files are there
Пример #2
0
                                # remove old startup
                                if os.path.isfile("/etc/init.d/tap"): os.remove("/etc/init.d/tap")

                                # startup script here
                                fileopen = file("src/core/startup_tap", "r")
                                config = fileopen.read()
                                filewrite = file("/etc/init.d/tap", "w")
                                filewrite.write(config)
                                filewrite.close()
                                print "[*] Triggering update-rc.d on TAP to automatic start..."
                                subprocess.Popen("chmod +x /etc/init.d/tap", shell=True).wait()
                                subprocess.Popen("update-rc.d tap defaults", shell=True).wait()

		# setting background
		print "[*] Setting background.."
		set_background()
                
		# install git and update everything
		print "[*] Updating everything beforehand..."
		subprocess.Popen("apt-get update && apt-get --force-yes -y upgrade && apt-get --force-yes -y dist-upgrade", shell=True).wait()
		subprocess.Popen("apt-get --force-yes -y install git python-crypto python-pexpect openssh-server", shell=True).wait()
		from Crypto.Cipher import AES
                choice = raw_input("Do you want to keep TAP updated? (requires internet) [y/n]: ")
                if choice == "y" or choice == "yes":
                        print "[*] Checking out latest TAP to /usr/share/tap"
                        # if old files are there
                        if os.path.isdir("/usr/share/tap/"):
                                shutil.rmtree('/usr/share/tap')
                        if not os.path.isdir("/usr/share/tap"):
                            os.makedirs("/usr/share/tap")
			subprocess.Popen("cd /usr/share/;git clone https://github.com/trustedsec/tap tap/", shell=True).wait()