store the payload in tmp directory, not my home directory

This commit is contained in:
Technomancer 2023-12-26 20:14:55 -06:00
parent 09f4f72db0
commit 2365131a25
No known key found for this signature in database
GPG Key ID: 33A12B0480AFC8E9

View File

@ -27,7 +27,7 @@ def deploy():
sshc.connect(cfg["server"],port=cfg["port"],key_filename=cfg["ssh-key"])
sftp = sshc.open_sftp() # after opening the ssh connection, we'll open a sftp connection.
sftp.put("./payload/payload.sh", "/home/system64/payload.sh") # upload the payload via SFTP.
sftp.put("./payload/payload.sh", "/payload.sh") # upload the payload via SFTP.
sshc.exec_command("chmod +x $HOME/payload.sh") # make it executable
sshc.exec_command("./payload.sh") # and finally, run the payload.