如何使用dotdotslash检测目录遍历漏洞

admin 2023年5月11日01:00:51评论40 views字数 1672阅读5分34秒阅读模式

如何使用dotdotslash检测目录遍历漏洞

 关于dotdotslash 

 

dotdotslash是一款功能强大的目录遍历漏洞检测工具,在该工具的帮助下,广大研究人员可以轻松检测目标应用程序中的目录遍历漏洞。

 已测试的平台 

当前版本的dotdotslash已在下列平台上进行过测试:

1、DVWA(低/中/高);

2、bWAPP(低/中/高);

 

 工具安装 

 

由于该工具基于Python 3开发,因此我们首先需要在本地设备上安装并配置好Python 3环境。接下来,广大研究人员可以使用下列命令将该项目源码克隆至本地:

git clone https://github.com/jcesarstef/dotdotslash.git

(向右滑动,查看更多)

然后切换到项目目录中,使用pip3命令和项目提供的requirements.txt安装该工具所需的依赖组件:

cd dotdotslashpip3 install requirements.txt

 

 工具使用 


工具帮助信息

> python3 dotdotslash.py --helpusage: dotdotslash.py [-h] --url URL --string STRING [--cookie COOKIE]                      [--depth DEPTH] [--verbose]dot dot slash - A automated Path Traversal Tester. Created by @jcesrstef.optional arguments:  -h, --help            show this help message and exit  --url URL, -u URL     Url to attack.  --string STRING, -s STRING                        String in --url to attack. Ex: document.pdf  --cookie COOKIE, -c COOKIE                        Document cookie.  --depth DEPTH, -d DEPTH                        How deep we will go?  --verbose, -v         Show requests

(向右滑动,查看更多)

 

 工具参数 

-h, --help                        显示工具帮助信息和退出--url URL, -u URL                设置目标url地址--string STRING, -s STRING       --url中需要测试的字符串,例如document.pdf--cookie COOKIE, -c COOKIE     设置文档Cookie--depth DEPTH, -d DEPTH       设置目录遍历深度--verbose, -v                    开启Verbose模式

(向右滑动,查看更多)

 

 工具使用样例 

python3 dotdotslash.py --url "http://192.168.58.101/bWAPP/directory_traversal_1.php?page=a.txt" --string "a.txt" --cookie "PHPSESSID=089b49151627773d699c277c769d67cb; security_level=3"

(向右滑动,查看更多)

 

 工具运行截图 

如何使用dotdotslash检测目录遍历漏洞

如何使用dotdotslash检测目录遍历漏洞

如何使用dotdotslash检测目录遍历漏洞

 项目地址 

 

dotdotslash

https://github.com/jcesarstef/dotdotslash

参考资料:

https://twitter.com/jcesarstef

https://www.linkedin.com/in/jcesarstef

http://www.inseguro.com.br/

https://github.com/ethicalhack3r/DVWA

http://www.itsecgames.com/

原文始发于微信公众号(FreeBuf):如何使用dotdotslash检测目录遍历漏洞

  • 左青龙
  • 微信扫一扫
  • weinxin
  • 右白虎
  • 微信扫一扫
  • weinxin
admin
  • 本文由 发表于 2023年5月11日01:00:51
  • 转载请保留本文链接(CN-SEC中文网:感谢原作者辛苦付出):
                   如何使用dotdotslash检测目录遍历漏洞http://cn-sec.com/archives/1725043.html

发表评论

匿名网友 填写信息