mirror of
https://github.com/weyne85/PentestGPT.git
synced 2025-10-29 16:58:59 +00:00
update prompt
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -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!!!"
|
||||
|
||||
@@ -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
|
||||
Reference in New Issue
Block a user