1
abdow
how to turn off the referrer check for xoops 2.2.3 final
  • 2005/11/29 22:54

  • abdow

  • Just popping in

  • Posts: 10

  • Since: 2005/11/29


As many users of my site use puplic internet coffee I want to turn off the referre check. I have searched the Forum and FAQ. I get only how to turn off for XOOPS 2.0.13.2. and not for XOOPS 2.2.3 final


for XOOPS 2.0.13.2 can man use the following hack to turn off

function xoops_refcheck($docheck=1)
{
return true;#*#DISABLE_REFERER_CHECK#
$ref = xoops_getenv('HTTP_REFERER');
if ($docheck == 0) {
return true;
}
if ($ref == '') {
return false;
}
if (strpos($ref, XOOPS_URL) !== 0 ) {
return false;
}
return true;
}

But this function is different for XOOPS2.2.3 final.

I am using XOOPS 2.2.3 final.

Thanks
abdow

2
abdow
Re: how to turn off the referrer check for xoops 2.2.3 final
  • 2005/11/29 23:30

  • abdow

  • Just popping in

  • Posts: 10

  • Since: 2005/11/29


I found it. For XOOPS 2.2.3 final The function moved to class/xoopssecurity.php.

3
m.de.koning
Re: how to turn off the referrer check for xoops 2.2.3 final
  • 2005/12/7 0:18

  • m.de.koning

  • Just popping in

  • Posts: 4

  • Since: 2005/12/6


Hi!

I have this same problem. In my XOOPS 2.2.3 I edited the following line, but the change did not take effect.

function checkReferer($docheck=0)

Did you apply some more modifications?

Hope to hear from you,

Greetings,

Marc

4
m.de.koning
Re: how to turn off the referrer check for xoops 2.2.3 final
  • 2005/12/7 11:08

  • m.de.koning

  • Just popping in

  • Posts: 4

  • Since: 2005/12/6


In connection to my former reaction, this is the complete code concerning the referer-check (I guess..)


function checkReferer($docheck=0)
{
if ($docheck == 0) {
return true;
}
$ref = xoops_getenv('HTTP_REFERER');
if ($ref == '') {
return false;
}
$pref = parse_url($ref);
if ( $pref['host'] != $_SERVER['HTTP_HOST']
// PORT might be appended to $_SERVER['HTTP_HOST'] by some browsers
&& $pref['host'].":".$pref['port'] != $_SERVER['HTTP_HOST']
) {
return false;
}
return true;
}


Does somebody know why browsers still refuse to load my XOOPS 2.2.3 site?

5
abdow
Re: how to turn off the referrer check for xoops 2.2.3 final
  • 2005/12/7 22:19

  • abdow

  • Just popping in

  • Posts: 10

  • Since: 2005/11/29


Marc The only thing I changed is to make return true see below :

Origin:
$ref = xoops_getenv('HTTP_REFERER');
if ($ref == '') {
return false;}

change to

$ref = xoops_getenv('HTTP_REFERER');
if ($ref == '') {
return true;}

Hope that helps

Abdow

6
m.de.koning
Re: how to turn off the referrer check for xoops 2.2.3 final
  • 2005/12/12 22:40

  • m.de.koning

  • Just popping in

  • Posts: 4

  • Since: 2005/12/6


Thank you very much Abdow,

I tried the modification you mentioned, and tried some variants of it... unfortunately with no succes..

But I guess this problem should occur to everybody who's installing it right?

I use a dutch Firefox browser saying: "de verwijzingslimiet voor deze URL is overschreden. Niet in staat de verzochte pagina te laden. Dit kan veroorzaakt worden door geblokkeerde cookies." while loading the page. It means (in my 'best' english...):

"De referer-limit for this URL has exeeded. Unable to load the page. It could have been caused by blocked cookies"

It's sure not a browser-thing. it's not running anywhere..

Any ideas??

Marc

7
toddherrold
Re: how to turn off the referrer check for xoops 2.2.3 final

Thanks for the info here. I've been getting the referrer error pages as well as invalid security tokens on my wordpress blogs and am trying all kinds of different things to get it to resolve. I've re-instated this change since upgrading to 2.2.3 and hope it helps.

8
Will_H
Re: how to turn off the referrer check for xoops 2.2.3 final
  • 2005/12/18 10:32

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


none of your steps worked for me. after trying all of them I found that changing

Quote:

function checkReferer($docheck=1)
{
if ($docheck == 0) {
return true;
}


to

Quote:

function checkReferer($docheck=1)
{
if ($docheck == 0) {
return false;
}


Seems to work in all browsers... if the browser matters

9
Daethian
Re: how to turn off the referrer check for xoops 2.2.3 final
  • 2005/12/18 17:51

  • Daethian

  • Quite a regular

  • Posts: 305

  • Since: 2005/3/4 1


Which file are we editing here and where is it located in the directory tree?
hhttp://www.artfire.com/daethian
My Artfire store- Vintage Jewelry and New Bead Jewelry

10
m.de.koning
Re: how to turn off the referrer check for xoops 2.2.3 final
  • 2005/12/21 11:07

  • m.de.koning

  • Just popping in

  • Posts: 4

  • Since: 2005/12/6


Quote:

Daethian wrote:
Which file are we editing here and where is it located in the directory tree?


as mentioned: class/xoopssecurity.php.


Unfortunately none of above solutions worked for me. Has it something to do with permissions? (CHMOD)

Hope to hear from you!

Greetingz,

Marc

Login

Who's Online

434 user(s) are online (384 user(s) are browsing Support Forums)


Members: 0


Guests: 434


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits