hello list,
I have some questions for modperl before using them.
what's the difference for mp1 and mp2? Does mp2 have large improvement
on performance?what's better for these choices below?
apache1.3 + mp1
apache2.0 + mp2
apache2.2 + mp2
Thanks!
Hello members,
I would config/write a modperl module to do this thing.
When someone access a file which is located on special directory,say it was,
/download/test.flv
we would do some auth check.If his IP or request time were
reasonable,we could let him access this file.Otherwise we would return
2007/6/14, Foo JH <[EMAIL PROTECTED]>:
Otherwise it will load the file specified in the uri and
send it back.
Then how can I "load the file and send it back" under modperl?Do I
need to call some routines like socket read/write?
Please show me more details.Thanks a lot.
2007/6/14, Clinton Gormley <[EMAIL PROTECTED]>:
What you're after is a PerlAccessHandler
http://perl.apache.org/docs/2.0/user/handlers/http.html#PerlAccessHandler
Yes I know whether I would return an OK or a FORBIDDEN under different
conditions.
My questions is,when return OK,what should I do
2007/6/14, Clinton Gormley <[EMAIL PROTECTED]>:
By using a PerlAccessHandler, you are adding a step into the standard
apache process.
So:
- the user goes to: /path/file.xyz
- your access handler performs its checks
- Allowed?
- Y :
- return OK
- file served by standard apache means
2007/6/14, Clinton Gormley <[EMAIL PROTECTED]>:
>
> mhh,I understood for your meanings.but my real question is how I can
> send the file to clients after returning OK.here is my apache config
> and modperl script,please give more helps.thanks!
>
> from httpd.conf:
>
> PerlModule DLAuth
>
>
>
2007/6/14, Clinton Gormley <[EMAIL PROTECTED]>:
If this is a new project in mod_perl, have you considered using Apache 2
and mod_perl 2?
Yes I did also consider using mp2.But when I searched on this list and
found many guys mentioned they install/run mp2 unsucessfully,so I
picked the easy way
Hello members,
I meet a problem about getting client's original IP.
Some clients use proxy servers to access our sites,and I need to get
their original IPs instead of proxy servers' IPs.
In CGI I can write it like:
my $ip = $ENV{'HTTP_X_FORWARDED_FOR'} ? $ENV{'HTTP_X_FORWARDED_FOR'} :
$c->remote
Thank you all guys.I've known this issue and know how to handle it.
Thanks again.
--jen
No.Here both PHP and CGI scripts can get the X_FORWARDED_FOR ip,but
modperl can't.Is the %ENV hash not useful under modperl?
2007/8/3, Torsten Foertsch <[EMAIL PROTECTED]>:
> On Friday 03 August 2007 12:29, Jen mlists wrote:
>
> > I meet a problem about getting client&
Hello,
In my mp1 script I wrote some info to apache's error_log:
} elsif ($ip_int != $ip_int2) {
$r->log_error("[$ip FORBIDDEN] Request IP was not matched");
return FORBIDDEN;
But I saw it wrote many times for same error item,like:
[Tue Aug 7 16:24:08 2007] [error] [219.12
Hello list,
Is it possible to write speed limit module (for file downloading) by
modperl rather than using Apache's official module?
Thanks.
I saw this document on perl.apache.com site,
When a mod_perl hook is called for a given phase, the glue code has an
index into the array of handlers, so it knows to return DECLINED right
away if no handlers are configured, without entering the Perl runtime
as 1.0 did. The handlers are also now sto
13 matches
Mail list logo