Opened 13 years ago

Last modified 3 years ago

#97 accepted defect

try_files and alias problems — at Initial Version

Reported by: Maxim Dounin Owned by: somebody
Priority: minor Milestone:
Component: nginx-core Version:
Keywords: try_files alias Cc:
uname -a: na
nginx -V: na

Description

# bug: request to "/test/x" will try "/tmp/x" (good) and
# "/tmp//test/y" (bad?)
location /test/ {
    alias /tmp/;
    try_files $uri /test/y =404;
}
# bug: request to "/test/x" will try "/tmp/test/x" instead of "/tmp/x"
location ~ /test/(.*) {
    alias /tmp/$1;
    try_files $uri =403;
}
# bug: request "/foo/test.gif" will try "/tmp//foo/test.gif"
location /foo/ {
    alias /tmp/;
    location ~ gif {
        try_files $uri =405;
    }
}

Change History (0)

Note: See TracTickets for help on using tickets.