Welcome to Geeklog, Anonymous Saturday, November 26 2022 @ 06:57 am EST

Geeklog Forums

Geeklog booting me off my own site


Nic

Anonymous
I am having login issues with my geeklog site (www.studentwire.net). I am repeatedly being logged in and booted out of the admin section while my profile remains logged in but without providing me with admin access.

Does anyone have any clue??
 Quote

Status: offline

mevans

Forum User
Full Member
Registered: 02/08/04
Posts: 393
Location:Texas
Nic,

This is caused by a small bug in the lib-custom.php that shows up when you turn on custom registration (like if you implement CAPTCHA).

The fix is simple edit the lib-custom.php file (located in system/).

Not sure of the exact line number but search for:

Text Formatted Code

/* Function called when saving the user profile. */
/* This function can now update any extra fields  */
function custom_usersave($uid)
{
    global $_CONF, $_TABLES;

    DB_query("UPDATE {$_TABLES['users']} SET cookietimeout='{$_POST["cooktime"]}'");

}
 
 

and make it look like this:
Text Formatted Code

function CUSTOM_userSave($uid)
{
    global $_CONF, $_TABLES;

    $cooktime = 0;
    if (isset ($_POST['cooktime'])) {
        $cooktime = COM_applyFilter ($_POST['cooktime'], true);
        if ($cooktime < 0) {
            $cooktime = 0;
        }

        DB_query("UPDATE {$_TABLES['users']} SET cookietimeout = $cooktime WHERE uid = $uid");
    }
}

 

Basically replace the CUSTOM_userSave() function with the new code above and that should take care of it. You might want to go into your profile and make sure you have the "Remember Me For" setting to something other than don't.

Let me know if this takes care of the issue.

Thanks!
Mark
 Quote

Nic

Anonymous
Thank you so much for the help. I have just implimented the Captcha system, last night!!

Much appreciated!

 Quote

Status: offline

PWR

Forum User
Junior
Registered: 04/02/06
Posts: 21
This worked for me... for a while... until the very next valid user registration. At that point I began getting bumped from my site again, even after making the changes suggested above.

After the user reg, I noticed the User Functions / Account Info / Remember Me setting had once again been reset to "don't", but this time, after resetting it to "1 month" yet again I continue to be bounced out.

This is very disturbing and distracting.

More help, please Wink

 Quote

Status: offline

mevans

Forum User
Full Member
Registered: 02/08/04
Posts: 393
Location:Texas
PWR,

Tell me a little more about your environment like which version of Geeklog you are running, are there any other custom registration items besides the CAPTCHA?

Thanks!
Mark
 Quote

Status: offline

PWR

Forum User
Junior
Registered: 04/02/06
Posts: 21
mevans, I'm running 1.4.0sr2, and CAPTCHA is the only custom registration item.

My logs indicate CAPTCHA is doing a wonderful job, refusing hundreds of attempts daily. I do suspect it's involved in this situation somehow though, because this problem never occurred until the day of CAPTCHA installation.

 Quote

Status: offline

PWR

Forum User
Junior
Registered: 04/02/06
Posts: 21
mevans,
Ah, I was a bit mistaken above. My revision to lib-custom.php wasn't exactly what you offered above, but what was offered to me a week or so ago in a similar thread.

I'm re-revising to the above code now, will report back if the problems continue.

Thanks,

PWR
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Maybe this will make it clearer what has to be changed.

We'll have to sort out the issues with 1.4.1 first, but after that we will probably release a small update for 1.4.0 which will contain the above change.

bye, Dirk
 Quote

All times are EST. The time is now 06:57 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content