Bug 57999 - ap_getparents() may remove start slash of uri
Summary: ap_getparents() may remove start slash of uri
Status: NEW
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: Core (show other bugs)
Version: 2.4.12
Hardware: PC Linux
: P2 normal (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
Depends on:
Reported: 2015-06-04 07:26 UTC by xudong
Modified: 2015-06-04 07:26 UTC (History)
0 users


Note You need to log in before you can comment on or make changes to this bug.
Description xudong 2015-06-04 07:26:05 UTC
When I send a request like this:
GET /test/../../etc/passwd HTTP/1.0

Apache will report an error:
AH00126: Invalid URI in request GET /test/../../etc/passwd HTTP/1.0

In file server/request.c line 154
ap_getparents() change r->uri from /test/../../etc/passwd to etc/passwd
and etc/passwd is an invalid uri.