Return-Path: Delivered-To: apmail-httpd-modules-dev-archive@minotaur.apache.org Received: (qmail 72253 invoked from network); 1 Jan 2011 18:03:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 1 Jan 2011 18:03:37 -0000 Received: (qmail 8437 invoked by uid 500); 31 Dec 2010 23:16:57 -0000 Delivered-To: apmail-httpd-modules-dev-archive@httpd.apache.org Received: (qmail 8409 invoked by uid 500); 31 Dec 2010 23:16:57 -0000 Mailing-List: contact modules-dev-help@httpd.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: modules-dev@httpd.apache.org Delivered-To: mailing list modules-dev@httpd.apache.org Received: (qmail 8401 invoked by uid 99); 31 Dec 2010 23:16:57 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 31 Dec 2010 23:16:57 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of jmarantz@google.com designates 74.125.121.67 as permitted sender) Received: from [74.125.121.67] (HELO smtp-out.google.com) (74.125.121.67) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 31 Dec 2010 23:16:53 +0000 Received: from kpbe16.cbf.corp.google.com (kpbe16.cbf.corp.google.com [172.25.105.80]) by smtp-out.google.com with ESMTP id oBVNGUZ4029676 for ; Fri, 31 Dec 2010 15:16:31 -0800 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=google.com; s=beta; t=1293837391; bh=9ogJvUdRyu+5vcWMWifDY0mFSeA=; h=MIME-Version:In-Reply-To:References:From:Date:Message-ID:Subject: To:Content-Type; b=Plv62Pr5rZH8W7grMW6DEil5FpV5vHWE2dErgaa7AMRm8pA/t8sdLEJlqgcU8L4w/ ozic3YjtANujFpHr81PCQ== Received: from iyj18 (iyj18.prod.google.com [10.241.51.82]) by kpbe16.cbf.corp.google.com with ESMTP id oBVNGT4P001382 for ; Fri, 31 Dec 2010 15:16:29 -0800 Received: by iyj18 with SMTP id 18so10995550iyj.34 for ; Fri, 31 Dec 2010 15:16:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=beta; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:content-type; bh=KQQnbVhCYXoSVvtkJoE5Hf0A5PLUQn55U1T8yFqbL8o=; b=PH/oMBsmAXdr4cRkO5lNEd5GeBMs/HrwWQd6A4c9iaeYDF9WTiImPCxAMVac/JxdCy JpkEBq9x9acXGqFZyFLA== DomainKey-Signature: a=rsa-sha1; c=nofws; d=google.com; s=beta; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; b=wWI/nrXIJHs+1x1AsogymA+xVrPEaOKfhZDVU+Ga39YWNlUa0fPltAZogkp2zVZt0l eoH4VCgVtSUl4WXEyAMw== Received: by 10.231.32.130 with SMTP id c2mr1937834ibd.35.1293837388882; Fri, 31 Dec 2010 15:16:28 -0800 (PST) MIME-Version: 1.0 Received: by 10.231.40.11 with HTTP; Fri, 31 Dec 2010 15:16:08 -0800 (PST) In-Reply-To: References: From: Joshua Marantz Date: Fri, 31 Dec 2010 18:16:08 -0500 Message-ID: Subject: Re: Overriding mod_rewrite from another module To: modules-dev@httpd.apache.org Content-Type: multipart/alternative; boundary=002215048fb7f6248c0498bcfd66 X-System-Of-Record: true --002215048fb7f6248c0498bcfd66 Content-Type: text/plain; charset=ISO-8859-1 Thanks for the quick response and the promising idea for a hack. Looking at mod_rewrite.c this does indeed look a lot more surgical, if, perhaps, fragile, as mod_rewrite.c doesn't expose that string-constant in any formal interface (even as a #define in a .h). Nevertheless the solution is easy-to-implement and easy-to-test, so...thanks! I'm also still wondering if there's a good source of official documentation for the detailed semantics of interfaces like ap_hook_translate_name. Neither a Google Search, a stackoverflow.com search, nor the Apache Modulesbook offer much detail. code.google.com fares a little better but just points to 4 existing usages. -Josh On Fri, Dec 31, 2010 at 1:50 PM, Ben Noordhuis wrote: > On Fri, Dec 31, 2010 at 18:17, Joshua Marantz wrote: > > Is there a better way to solve the original problem: preventing > mod_rewrite > > from corrupting mod_pagespeed's resources? > > From memory and from a quick peek at mod_rewrite.c: in your > translate_name hook, set a "mod_rewrite_rewritten" note in r->notes > with value "0" and return DECLINED. That'll trick mod_rewrite into > thinking that it has already processed the request. > --002215048fb7f6248c0498bcfd66--