<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:arial, helvetica, sans-serif;font-size:12pt"><DIV></DIV>
<DIV>Open a core issue on that. Since 6.16 is in the works, this&nbsp;could be good timing.<BR>&nbsp;</DIV>
<P><FONT face="bookman old style, new york, times, serif" color=#ff007f size=4><EM><STRONG>Nancy E. Wichmann, PMP</STRONG></EM></FONT></P>
<P><FONT face="arial, helvetica, sans-serif">Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.</FONT></P>
<DIV><BR></DIV>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: arial, helvetica, sans-serif"><BR>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: times new roman, new york, times, serif"><FONT face=Tahoma size=2>
<HR SIZE=1>
<B><SPAN style="FONT-WEIGHT: bold">From:</SPAN></B> Randy Fay &lt;randy@randyfay.com&gt;<BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B> development@drupal.org<BR><B><SPAN style="FONT-WEIGHT: bold">Sent:</SPAN></B> Wed, March 3, 2010 1:27:13 PM<BR><B><SPAN style="FONT-WEIGHT: bold">Subject:</SPAN></B> Re: [development] mod rewrite rules question<BR></FONT><BR>Just an FYI: Dreamhost recently disallowed FollowSymLinks on all their servers, so the standard Drupal .htaccess (and sites/default/files/.htaccess) will cause a 500 error. Replacing the instances of FollowSymLinks with SymlinksIfOwnerMatch resolves this on Dreamhost.<BR><BR>I only mention this because anybody who perked up at the mention of FollowSymLinks might want to know.<BR><BR>Apparently Dreamhost has encountered a security risk of using FollowSymLinks. I wonder if we should update the Drupal ..htaccess and sites/default/files/.htaccess in line with this. Any
 opinions?<BR><BR>-Randy<BR><BR>
<DIV class=gmail_quote>On Wed, Mar 3, 2010 at 11:03 AM, Ashraf Amayreh <SPAN dir=ltr>&lt;<A href="mailto:mistknight@gmail.com" target=_blank rel=nofollow ymailto="mailto:mistknight@gmail.com">mistknight@gmail.com</A>&gt;</SPAN> wrote:<BR>
<BLOCKQUOTE class=gmail_quote style="PADDING-LEFT: 1ex; MARGIN: 0pt 0pt 0pt 0.8ex; BORDER-LEFT: rgb(204,204,204) 1px solid">
<DIV dir=ltr>Well, the reason for the internal server error, awkwardly enough, is because I had FollowSymLinks inside the directory tags inside the virtual host tags<BR><BR>Options Indexes FollowSymLinks<BR><BR>Removing it solved the internal server error. In fact, I do use symlinks so I was puzzled on what to do. Adding Options +FollowSymLinks in the .htaccess file did it (it's already done in Drupal's .htaccess file). Strangely enough, you cannot declare this inside the directory tags but could through .htaccess and probably outside the directory tags too.<BR><BR>I also noted that "NULL" must be sent without a newline. For anyone who may try this in the future.<BR><BR>The final look for the rewrite rules are as follows: 
<DIV class=im><BR><BR>RewriteCond %{HTTP_HOST} !^<A href="http://apps.jeeran.com/" target=_blank rel=nofollow>apps.example.com</A><BR></DIV>RewriteCond %{REQUEST_FILENAME} !-f<BR>RewriteCond %{REQUEST_FILENAME} !-d 
<DIV class=im><BR>RewriteCond %{HTTP_HOST} ^(.*).<A href="http://jeeran.com/" target=_blank rel=nofollow>example.com</A><BR></DIV>RewriteRule ^(.*)$ ${res:%1}$1 [QSA]<BR><BR>RewriteCond %{REQUEST_FILENAME} !-f<BR>RewriteCond %{REQUEST_FILENAME} !-d<BR>RewriteCond %{REQUEST_URI} !=/favicon.ico<BR>RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]<BR clear=all><BR>I am bumping into the infinite loop problem though. And I'm not sure the proposed solution could work. In case the rewrite was transparent (app returns NULL), there's no way to know on future requests that I've done a previous rewrite. For example:<BR><BR>If <A href="http://abc.example.com/" target=_blank rel=nofollow>abc.example.com</A> returned a NULL, the URL will still be <A href="http://abc.example.com/" target=_blank rel=nofollow>abc.example.com</A> and not <A href="http://abc.example.com/members" target=_blank rel=nofollow>abc.example.com/members</A> so I can't check against "members" to prevent an
 infinite loop, unless I misunderstood the proposed solution. With the above rewrite rules, I'm getting a very strange phenomena for non-rewriteen URLs (when the app returns NULL):<BR><BR>http://abc.example.com/ar/members/abc/ar/members/abc/ar/members/abc/ar/members/abc/ar/members/abc/ar/abc/16474 (etc)<BR><BR>Of course it's too long to paste here. The error I get is 414 (Request-URI Too Large)<BR><BR>Any help still appreciated :) 
<DIV class=im><BR><BR>-- <BR>Best Regards,<BR>Ashraf Amayreh<BR>CEO | O-Minds<BR>Cell. 962 78 8099997<BR>Tel. 962 6 5655150<BR>Fax. 962 6 5675150<BR><BR><A href="http://o-minds.com/" target=_blank rel=nofollow>o-minds.com</A><BR>web development | web design<BR>user experience | branding design<BR></DIV></DIV></BLOCKQUOTE></DIV><BR><BR clear=all><BR>-- <BR>Randy Fay<BR>Drupal Development, troubleshooting, and debugging<BR><A href="mailto:randy@randyfay.com" target=_blank rel=nofollow ymailto="mailto:randy@randyfay.com">randy@randyfay.com</A><BR>+1 &nbsp;970.462.7450<BR><BR></DIV></DIV></div></body></html>