[prev in list] [next in list] [prev in thread] [next in thread] 

List:       apache-modperl
Subject:    [MP2] Terminate / Redirect request in Input Filter
From:       Alex <maillist () liemen ! net>
Date:       2006-03-30 13:09:05
Message-ID: 442BD871.40604 () liemen ! net
[Download RAW message or body]

Spam detection software, running on the system "s001.funpic.de", has
identified this incoming email as possible spam.  The original message
has been attached to this so you can view it (if it isn't spam) or label
similar future email.  If you have any questions, see
the administrator of that system for details.

Content preview:  Hi, following scenario: - mod_perl2 Apache2 Input Filter
  - stream based - regex checks some stuff in GET/POST args + Referer - if
  it finds something -> log it -> terminate / redirect request [...] 

Content analysis details:   (6.1 points, 5.0 required)

 pts rule name              description
---- ---------------------- --------------------------------------------------
 0.0 BAYES_50               BODY: Bayesian spam probability is 40 to 60%
                            [score: 0.5000]
 2.0 RCVD_IN_SORBS_DUL      RBL: SORBS: sent directly from dynamic IP address
                            [88.73.214.52 listed in dnsbl.sorbs.net]
 1.9 RCVD_IN_NJABL_DUL      RBL: NJABL: dialup sender did non-local SMTP
                            [88.73.214.52 listed in combined.njabl.org]
 2.1 AWL                    AWL: From: address is in the auto white-list




Received: from unknown (HELO ?192.168.2.5?) (alexander@liemen.net@88.73.214.52)
  by s001.funpic.de with SMTP; 30 Mar 2006 13:09:07 -0000
Message-ID: <442BD871.40604@liemen.net>
Date: Thu, 30 Mar 2006 15:09:05 +0200
From: Alex <maillist@liemen.net>
User-Agent: Thunderbird 1.5 (Windows/20051201)
MIME-Version: 1.0
To:  modperl@perl.apache.org
Subject: [MP2] Terminate / Redirect request in Input Filter
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding: 7bit

Hi,

following scenario:

- mod_perl2 Apache2 Input Filter
- stream based
- regex checks some stuff in GET/POST args + Referer
- if it finds something -> log it -> terminate / redirect request


The problem:

I want to terminate further processing of the request or redirect it 
somewhere else in case certain regex checks match in the GET/POST args.

I tried to manipulate the headers with $r->uri, $r->internal_redirect 
but that didn't help. If i do an internal redirect both the new + old 
uri get processed by Apache.

How do I

1) either terminate the whole further processing by Apache -> client 
would get connection aborted / access denied / server error or whatever

2) or redirect the request to some other url / file

In both cases the orignal url should not be further processed by other 
filters / Apache.


Thank You
Alex


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic