clear tmp for burp
This commit is contained in:
@@ -2,18 +2,29 @@ import pyautogui
|
|||||||
import time
|
import time
|
||||||
import os
|
import os
|
||||||
import subprocess
|
import subprocess
|
||||||
|
import glob
|
||||||
|
|
||||||
BURP_JAR = "/headless/burpsuite_community.jar"
|
BURP_JAR = "/headless/burpsuite_community.jar"
|
||||||
CONFIG_FILE = "/app/burp/project_options.json"
|
CONFIG_FILE = "/app/burp/project_options.json"
|
||||||
|
|
||||||
print("Waiting for vnc to start up...")
|
def start_burp():
|
||||||
time.sleep(10)
|
|
||||||
print("Starting Burp Suite...")
|
for filepath in glob.glob('/tmp/burp*'):
|
||||||
burp_process = subprocess.Popen([
|
try:
|
||||||
"java", "-jar", BURP_JAR,
|
if os.path.isfile(filepath):
|
||||||
f"--config-file={CONFIG_FILE}"
|
os.remove(filepath)
|
||||||
])
|
print(f"Deleted: {filepath}")
|
||||||
|
except Exception as e:
|
||||||
|
print(f"Error deleting {filepath}: {e}")
|
||||||
|
|
||||||
|
burp_process = subprocess.Popen([
|
||||||
|
"java", "-jar", BURP_JAR,
|
||||||
|
f"--config-file={CONFIG_FILE}"
|
||||||
|
])
|
||||||
|
return burp_process
|
||||||
|
|
||||||
|
print("Starting Burp Suite...")
|
||||||
|
burp_process = start_burp()
|
||||||
button = None
|
button = None
|
||||||
while True:
|
while True:
|
||||||
try:
|
try:
|
||||||
@@ -62,9 +73,5 @@ while True:
|
|||||||
time.sleep(60)
|
time.sleep(60)
|
||||||
burp_process.terminate()
|
burp_process.terminate()
|
||||||
print("Starting Burp Suite...")
|
print("Starting Burp Suite...")
|
||||||
burp_process = subprocess.Popen([
|
burp_process = start_burp()
|
||||||
"java", "-jar", BURP_JAR,
|
|
||||||
f"--config-file={CONFIG_FILE}"
|
|
||||||
])
|
|
||||||
button = None
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user