where is web path 发表于 2017-10-16 where is web path (from wooyun zone)123456find / -name "*.php"find . -name "*.类型" | xargs grep "关键字"find / -name nginx.conffind / -name httpd.conffind robots.txtlocate robots.txt 12345.bash_historyhttpd,nginx,tomcat,jboss的error_log/proc/self/cmdline/proc/self/mapsweb容器路径-->配置文件 12win: findstr /s /i /n /d:C:\ "htmlString" *.*linux: find / -name "*.*" | xargs grep "htmlString" 1cat /etc/nginx/conf/vhost/web.conf | grep root 1echo "-----------------------start---------------------";find /etc -maxdepth 3 -name "*" 2>&1|xargs grep -s -i 'root /'| grep -s -i 'nginx\|apache';echo "-----------------------done----------------------" 12For I in (curl http://localhost |grep -oP ([a-Z]{1-6})[\.js]));do for d in $(find / -name "*.js");do grep $i $d;done;done没实验,意思是打开首页匹配js文件。系统内搜索所有文件js文件,匹配js文件名 123456win:wmic datafile where "filename='123' and extension='avi'" get captiondir /s/a-d/b d:\*重复度较低的文件名(支持通配符)*where /r c: *.php 123history | grep cd | grep -v grep | grep -E 'www|html|nginx|apache|php|lighttp|web' -ihistory | grep -E 'cd|vi|ed|nano|et|mkdir|rm|find|ls|mv' | grep -v grep | grep -E 'www|html|nginx|apache|php|lighttp|web' -i 1234567891、netstat -anp | grep [port] --> PID2、ps -p [PID] -o cmd ww --> PID对应的启动命令(假设存在反向代理,则为bin目录)3、cd ../conf --> 寻找nginx.conf/httpd.conf4、通过反向代理ProxyPass/ProxyPassReverse找到对应的webapp端口号port25、netstat -anp | grep [port2] --> PID2(web app的进程)6、ps -p [PID2] -o cmd ww --> PID2的“Catalina.base”7、cd 到“Catalina.base” --> server.xml8、从server.xml中找到appBase 和 docBase9、cd 到 $docBase/$appBase,即为当前web app路径。