You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2013/02/23 19:52:39 UTC

[Bug 53794] Problem on rewrite

https://issues.apache.org/bugzilla/show_bug.cgi?id=53794

--- Comment #6 from koumes@centrum.cz ---
I have the same problem with mod_rewrite + mod_dir (also similar bug
https://issues.apache.org/bugzilla/show_bug.cgi?id=53929). A mod_dir call
undesirable subrequest and override a previous rewrited URL.

.htaccess:

DirectoryIndex index1.html index2.html

RewriteEngine On
RewriteRule !\.html$ /index3.html [L]


URL: http://localhost/

Bad result (Apache 2.4.3, 2.4.4): index1.html or index2.html
Expected result (Apache 2.2.22): index3.html


Rewritelog:

[Sat Feb 23 19:46:28.683232 2013] [rewrite:trace3] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid
#7fe007bdda60][rid#7fe007acc0a0/initial] [perdir /var/www/default/] strip
per-dir prefix: /var/www/default/ -> 
[Sat Feb 23 19:46:28.683286 2013] [rewrite:trace3] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007acc0a0/initial] [perdir
/var/www/default/] applying pattern '\\.html$' to uri ''
[Sat Feb 23 19:46:28.683307 2013] [rewrite:trace2] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007acc0a0/initial] [perdir
/var/www/default/] rewrite '' -> 'index3.html'
[Sat Feb 23 19:46:28.683324 2013] [rewrite:trace3] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007acc0a0/initial] [perdir
/var/www/default/] add per-dir prefix: index3.html ->
/var/www/default/index3.html
[Sat Feb 23 19:46:28.683342 2013] [rewrite:trace2] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007acc0a0/initial] [perdir
/var/www/default/] strip document_root prefix: /var/www/default/index3.html ->
/index3.html
[Sat Feb 23 19:46:28.683351 2013] [rewrite:trace1] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007acc0a0/initial] [perdir
/var/www/default/] internal redirect with /index3.html [INTERNAL REDIRECT]
[Sat Feb 23 19:46:28.683403 2013] [rewrite:trace3] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007ac10a0/subreq] [perdir
/var/www/default/] strip per-dir prefix: /var/www/default/index1.html ->
index1.html
[Sat Feb 23 19:46:28.683421 2013] [rewrite:trace3] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007ac10a0/subreq] [perdir
/var/www/default/] applying pattern '\\.html$' to uri 'index1.html'
[Sat Feb 23 19:46:28.683432 2013] [rewrite:trace1] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007ac10a0/subreq] [perdir
/var/www/default/] pass through /var/www/default/index1.html
[Sat Feb 23 19:46:28.683458 2013] [rewrite:trace3] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007ac10a0/subreq] [perdir
/var/www/default/] strip per-dir prefix: /var/www/default/index2.html ->
index2.html
[Sat Feb 23 19:46:28.683472 2013] [rewrite:trace3] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007ac10a0/subreq] [perdir
/var/www/default/] applying pattern '\\.html$' to uri 'index2.html'
[Sat Feb 23 19:46:28.683487 2013] [rewrite:trace1] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid
[Sat Feb 23 19:46:28.683487 2013] [rewrite:trace1] [pid 28647:tid
140599957112576] mod_rewrite.c(468): [client 127.0.0.1:8813] 127.0.0.1 - -
[localhost/sid#7fe007bdda60][rid#7fe007ac10a0/subreq] [perdir
/var/www/default/] pass through /var/www/default/index2.html

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org