Return-Path: X-Original-To: apmail-httpd-users-archive@www.apache.org Delivered-To: apmail-httpd-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id C63756A57 for ; Mon, 25 Jul 2011 19:15:22 +0000 (UTC) Received: (qmail 16232 invoked by uid 500); 25 Jul 2011 19:15:19 -0000 Delivered-To: apmail-httpd-users-archive@httpd.apache.org Received: (qmail 16153 invoked by uid 500); 25 Jul 2011 19:15:19 -0000 Mailing-List: contact users-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: users@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@httpd.apache.org Received: (qmail 16145 invoked by uid 99); 25 Jul 2011 19:15:18 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Jul 2011 19:15:18 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [83.163.129.117] (HELO xs.adaptr.nl) (83.163.129.117) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 25 Jul 2011 19:15:13 +0000 Received: from [10.10.10.128] (c2d.adaptr.nl [10.10.10.128]) by xs.adaptr.nl (Postfix) with ESMTPSA id 202F31D8007 for ; Mon, 25 Jul 2011 21:13:04 +0200 (CEST) Message-ID: <4E2DC0AD.7060807@adaptr.nl> Date: Mon, 25 Jul 2011 21:14:53 +0200 From: Jeroen Geilman User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:5.0) Gecko/20110624 Thunderbird/5.0 MIME-Version: 1.0 To: users@httpd.apache.org References: <4E2DB9D6.8090603@sohnen-moe.com> In-Reply-To: <4E2DB9D6.8090603@sohnen-moe.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [users@httpd] RewriteRule acts differently for different browsers On 2011-07-25 20:45, James Moe wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Hello, > apache v2.0 > > The reason for this redirection is that when I purchased the SSL > certificate, I did not know to get one for than the domain's URL, > . A secure connection to brings up > the warning about a possibly "untrusted site." You should not use rewriting for this, it is entirely unnecessary and only adds complexity. Instead, you add a new vhost for www.sohnen-moe.com, and do a blank redirect to HTTPS. > RewriteEngine on > RewriteCond %{HTTP_HOST} =www.sohnen-moe.com > RewriteRule ^/(.*)$ https://sohnen-moe.com/$1 [L,R] > > For the browsers Firefox v5 linux, Chrome v12.0 linux, Opera v11.5 > linux, Semaonkey v2.1 os/2, Safari v5.0 windows, Internet Explorer v8, I > get different redirections for the URL. > Firefox: http://sohnen-moe.com/////////////////////<--Not a typo! > Chrome: https://sohnen-moe.com/ > Opera: http://www.sohnen-moe.com/ > Seamonkey: http://www.sohnen-moe.com/ > Safari: http://www.sohnen-moe.com/ > IExplorer: http://www.sohnen-moe.com/ > > Only Chrome redirected like I thought the rule indicates. > Is this to be expected? It seems rather arbitrary. I suspect that the above is using the highly dubious VirtualHost * construct, which should die and burn in hell. If so, you are not taking into account the possibility that the request is coming in over HTTPS. Add another rewritecond that checks for it. -- J. --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See for more info. To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org " from the digest: users-digest-unsubscribe@httpd.apache.org For additional commands, e-mail: users-help@httpd.apache.org