Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Prevent using of review from other urls or tru browser?

Quote Reply
Prevent using of review from other urls or tru browser?
Hi all,
we have some parts only accessable for special members, some of the infos we share there are passed tru review.cgi.

For some reasons i cant change the path for the review.cgi, so is there a secure and with every normal browser useably way to protect the script like with add.cgi?
Quote Reply
Re: [Robert] Prevent using of review from other urls or tru browser? In reply to
Ok, found some code and make this:

Code:
if ($ENV{'HTTP_REFERER'}) {
foreach (@{$CFG->{db_referers}}) { $ENV{'HTTP_REFERER'} =~ /\Q$_\E/i and $found++ and last; }
}


The problem now. While i have defined db_referers as www.homepage.com and the url from to click is something like http://www.homepage.com/lala/lala.php the if-clause is still not true.

What makes =~ /\Q$_\E/i ?

It should do something like take the http_referer like http://www.homepage.com/lala ... /
and compare from start with http://www.homepage.com

Seems not to do it. Any idea?


Quote Reply
Re: [Robert] Prevent using of review from other urls or tru browser? In reply to
Smile. Found it. I really should divide parts of an aray with a ",".