I went back to betabug and reran the rule generator. I was able to use
the rules for http connections... but not for https connection.<br>
<br>
I thought the two rules might be conflicting some how so I commented
out the rules for http connections and the https connections still
don't work, ie I still get the 404 error.<br>
<br>
Here is what I have now.<br>
<br>
<span style="font-family: courier new,monospace;"># see <a href="http://betabug.ch/zope/witch">http://betabug.ch/zope/witch</a></span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"># RewriteRule ^/z2$ \</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"># <a href="http://127.0.0.1:9080/VirtualHostBase/\">http://127.0.0.1:9080/VirtualHostBase/\</a></span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"># http/%{SERVER_NAME}:80/VirtualHostRoot/_vh_z2/ [L,P]</span><br style="font-family: courier new,monospace;">
<br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"># RewriteRule ^/z2/(.*) \</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"># <a href="http://127.0.0.1:9080/VirtualHostBase/\">http://127.0.0.1:9080/VirtualHostBase/\</a></span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"># http/%{SERVER_NAME}:80/VirtualHostRoot/_vh_z2/$1 [L,P]</span><br style="font-family: courier new,monospace;">
<br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;">#</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;">RewriteRule ^/z2$ \</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"><a href="http://127.0.0.1:9080/VirtualHostBase/\">http://127.0.0.1:9080/VirtualHostBase/\</a></span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;">https/%{SERVER_NAME}:443/VirtualHostRoot/_vh_z2/ [L,P]</span><br style="font-family: courier new,monospace;">
<br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;">RewriteRule ^/z2/(.*) \</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"><a href="http://127.0.0.1:9080/VirtualHostBase/\">http://127.0.0.1:9080/VirtualHostBase/\</a></span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;">https/%{SERVER_NAME}:443/VirtualHostRoot/_vh_z2/$1 [L,P]</span><br style="font-family: courier new,monospace;">
<br>
<br>I can uncomment the http rules and they work. But whats the point
of using apache if I can get it to do https? (aside from legacy files
and other apps that depend on it...)<br>
<br>
There must be a better way..<br>
<br><div><span class="gmail_quote">On 5/25/06, <b class="gmail_sendername">Sascha Welter</b> &lt;<a href="mailto:zopelist@betabug.ch">zopelist@betabug.ch</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
(Wed, May 24, 2006 at 12:00:09PM -0400) <a href="mailto:zope-request@zope.org">zope-request@zope.org</a> wrote/schrieb/egrapse:<br>&gt; From: &quot;David Bear&quot; &lt;<a href="mailto:dwbear75@gmail.com">dwbear75@gmail.com
</a>&gt;<br><br>&gt; # see <a href="http://betabug.ch/zope/witch">http://betabug.ch/zope/witch</a><br>&gt; RewriteRule ^/z2$ <a href="http://127.0.0.1:9080/VirtualHostBase/\">http://127.0.0.1:9080/VirtualHostBase/\</a><br>
&gt; https/%SERVER_NAME}:80/VirtualHostRoot/_vh_z2/ [L,P]<br>&gt;<br>&gt; RewriteRule ^/z2/(.*) <a href="http://127.0.0.1:9080/VirtualHostBase/\">http://127.0.0.1:9080/VirtualHostBase/\</a><br>&gt; https/%{SERVER_NAME}:80/VirtualHostRoot/_vh_z2/$1 [L,P]
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
^^<br>Just telling the witch to use &quot;https&quot; isn't enough, you have to tell it<br>the port too (usually 443).<br><br>This isn't the most obvious thing from th form, but it should be a cluee<br>that the port doesn't change when you select https.
<br><br>&gt; I also found the following rule from scanning through zope-list postings, to<br>&gt; force any logon authentication requests to go over https. However, since the<br>&gt; above rules fail, the following does nothing.
<br>&gt;<br>&gt; RewriteRule ^/login_form(.*) https://%{SERVER_NAME}/login_form$1 [NE,L]<br><br>This is a redirect and once your https-rewriterule works, it should too.<br><br>&gt; From: Chris Withers &lt;<a href="mailto:chris@simplistix.co.uk">
chris@simplistix.co.uk</a>&gt;<br>&gt; In both cases, I see no need for two rules, just the one should suffice:<br>&gt;<br>&gt; RewriteRule ^/z2(.*) <a href="http://127.0.0.1:9080/VirtualHostBase/\">http://127.0.0.1:9080/VirtualHostBase/\
</a><br>&gt; http/%{SERVER_NAME}:80/VirtualHostRoot/_vh_z2$1 [L,P]<br><br>Yes, that will work too, unless of course you happen to have a URL that<br>goes something like <a href="http://www.host.tld/z2thisisnotzope/index.html">
http://www.host.tld/z2thisisnotzope/index.html</a> and apache<br>will happily rewrite it for you, resulting in a 404.<br><br>The two rules of the witch could likely be rewritten to one, but two<br>rules cover the two possibilities easy in a form that humans can grasp:
<br>Either the URL ends there, or else it has a slash and then as much as<br>there is.<br><br>Regards,<br><br>Sascha<br><br>_______________________________________________<br>Zope maillist&nbsp;&nbsp;-&nbsp;&nbsp;<a href="mailto:Zope@zope.org">
Zope@zope.org</a><br><a href="http://mail.zope.org/mailman/listinfo/zope">http://mail.zope.org/mailman/listinfo/zope</a><br>**&nbsp;&nbsp; No cross posts or HTML encoding!&nbsp;&nbsp;**<br>(Related lists -<br> <a href="http://mail.zope.org/mailman/listinfo/zope-announce">
http://mail.zope.org/mailman/listinfo/zope-announce</a><br> <a href="http://mail.zope.org/mailman/listinfo/zope-dev">http://mail.zope.org/mailman/listinfo/zope-dev</a> )<br></blockquote></div><br><br clear="all"><br>-- <br>
David Bear<br>What's the difference between private knowledge and public knowledge?<br>