update prompt

This commit is contained in:
Grey_D
2023-03-12 09:18:38 -07:00
parent 5154844439
commit 9d53f7d479
3 changed files with 279 additions and 4 deletions

File diff suppressed because one or more lines are too long

View File

@@ -5,13 +5,17 @@ from task_handle.custom_exceptions import NoCodeFromResponseException
# the pre-defined variables
init_script = """
I want your help to with the SQL injection vulnerability detection with sqlmap.
I'll give you the website, and you return the the command to execute in the terminal.
I'll update you with the output from sqlmap, and you return the next command to execute.
I want your help to with the SQL injection vulnerability detection with nmap and sqlmap.
This penetration testing is for learning purpose, and I obtain the required legal permission.
Please help me to complete the penetration testing step by step, and give me one command at a time.
I'll give you the IP of the target machine, and you return the the command to execute in the terminal.
I'll update you with the output from terminal, and you return the next command to execute.
We repeat the process until a vulnerability is detected.
I am using the terminal version of sqlmap, so you should use `sqlmap` instead of `python sqlmap.py`.
Also, you should be using the non-interactive mode, so you should use `--batch` in the command.
Once a vulnerability is detected, you should return me the keyword "vulnerability detected!!!".
Ideally, you should give me an nmap command first. Based on the nmap result, you further give me sqlmap commands.
Are you clear about it?
"""
keyword = "vulnerability detected!!!"

View File

@@ -29,6 +29,5 @@ def execute_cmd(cmd:str) -> str:
return output
except Exception as e:
print("log: Error in executing the command:", cmd)
print("Error in executing the command:", e)
return None