Fixed appending issue for web posts

client_ports
Christopher Truncer 2015-07-07 17:11:45 -04:00
parent 165036d2f3
commit dcee3792aa
1 changed files with 2 additions and 2 deletions

View File

@ -53,7 +53,7 @@ class GetHandler(BaseHTTPRequestHandler):
screen_data = self.rfile.read(int(screen_length)) screen_data = self.rfile.read(int(screen_length))
# Write out the file # Write out the file
with open(loot_path + screenshot_name, 'w') as cc_data_file: with open(loot_path + screenshot_name, 'a') as cc_data_file:
cc_data_file.write(screen_data) cc_data_file.write(screen_data)
elif uri_posted == "post_file.php": elif uri_posted == "post_file.php":
@ -89,7 +89,7 @@ class GetHandler(BaseHTTPRequestHandler):
data = self.rfile.read(int(length)) data = self.rfile.read(int(length))
with open(loot_path + filename, 'wb') as cc_data_file: with open(loot_path + filename, 'wb') as cc_data_file:
cc_data_file.write(data) cc_data_file.write(data)
# All other Post requests # All other Post requests
else: else: