Xaraya 1.0 RC4: Privilege Error ReadGallery2

Danny

Joined: 2003-03-24
Posts: 90
Posted: Sun, 2005-10-23 10:38

Hello,

after upgrading to Xaraya 1.0 RC4 and Gallery2 2.0.1 and newest Integration code (21.10.2005) I got a Privilege Error, when not logged in at my site. The Privilige is OK, I disabled Anonymous access to my Gallery2 Installation.

My big question is, how to get rid of this Privilege Error Message? My site was OK during the last months. The Privilege Error message, just poped up after upgrading.

Thanks in Advance,

Danny

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Sun, 2005-10-23 13:18
Quote:
The Privilige is OK, I disabled Anonymous access to my Gallery2 Installation.

so anonymous xaraya users don't have permission to visit G2 in xaraya?
so it makes sense that anonymous users get a privilege error, right?

or do logged in users get this error too?

 
Danny

Joined: 2003-03-24
Posts: 90
Posted: Sun, 2005-10-23 13:59

Hello Valiant,

thanks for your reply.

>so anonymous xaraya users don't have permission to visit G2 in xaraya?

Thats correct.

>so it makes sense that anonymous users get a privilege error, right?

It makes sense from a programmers view of sight, that a privilege error is shown. But not from a designer point of view. I just want to have the normal Xaraya site without the nasty error code.

Valiant you helped me in the past with this problem. It was in Modules\gallery2\xarblocks\image.php xarsecuritycheck was set the second argument to 0.

I have checked it, image.php xarsecuritycheck is also in your newest integration code set to 0. But I can't image why the privilege error is shown anyways.

Was there a change in the Gallery2 integration code? Have I missed an extra xarsecuritycheck in another file?

Danny

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Sun, 2005-10-23 14:06

ya, i remember our discussion. i was just not sure if this is about the same issue.
let me see:

xarblocks/sidebar.php: if (!xarSecurityCheck('ReadGallery2', 1, 'Block', $blockinfo['title'])) {return;}
xaruser/main.php: if (!xarSecurityCheck('ReadGallery2')) return;
xaruser/search.php: if(!xarSecurityCheck('ReadGallery2')) return;

if you change that to 0, does it fix it?
xarblocks/sidebar.php: if (!xarSecurityCheck('ReadGallery2', 0, 'Block', $blockinfo['title'])) {return;}
xaruser/main.php: if (!xarSecurityCheck('ReadGallery2', 0)) return;
xaruser/search.php: if(!xarSecurityCheck('ReadGallery2', 0)) return;

don't ask me why i didn't add the 0 there, maybe i just forgot. if it works, let me know and i'll change it.
thanks!

 
Danny

Joined: 2003-03-24
Posts: 90
Posted: Sun, 2005-10-23 14:21

Hi Valiant,

thank you for your reply. Please forgot this thread. Image.php with 0 is correct. I missed only sidebar.php. After changing it from 1 to 0 it worked perfect.

Thanks for your help,

Danny