Skip to Content.
Sympa Menu

lyceum-users - Re: [Lyceum-users] Error message: "Your tokens have timed out...."

lyceum-users AT lists.ibiblio.org

Subject: Lyceum-users mailing list

List archive

Chronological Thread  
  • From: "Liu Xuefeng" <xfliu.math AT gmail.com>
  • To: "bai.xiaoyu AT gmail.com" <bai.xiaoyu AT gmail.com>, lyceum-users AT lists.ibiblio.org
  • Subject: Re: [Lyceum-users] Error message: "Your tokens have timed out...."
  • Date: Tue, 24 Jul 2007 09:43:03 +0900

Hi, Mr. Bai,

Yes,  I mean the /tmp folder on linux server, which saves the session files in my case.

I have tried to debug the code and got to know sth behind wordpress. Here I can give you some advice:

1) Check weather your server saves session data in /tmp, or find the right one.
2) This error seems only be related with time expiration check. Wordpress saves this data not by cookie but by session.
You see, cookie is on terminal but session on server. When the session lost the data that records the beginning time of edit,
the code below
    $token_age = time() - $_SESSION['formtokens'][$key][$token]; 
will run  like this:
   $token_age = time()
which just leads the $token_age to be very large.

Good luck!


(Please find it at <wordpress>/lib/functions.php )

function tokenIsValid ($token, $targetscript, $action="'default'," $id=0, $keep=false) {
    global $userdata;
    $key = sha1($targetscript.$action.$id.$userdata->ID);
    if (!array_key_exists($token, $_SESSION['formtokens'][$key]))    {
        return false;
    }

    $token_age = time() - $_SESSION['formtokens'][$key][$token];

    if ($token_age >= 86400)//86400 seconds = 24 hours    {
        return false;
    }
   
    if (!$keep)
        unset($_SESSION['formtokens'][$key][$token]);
    return true;
}

P.S.
Attached is the error info.
Error: "Your tokens have timed out. Reload the page to reset your tokens."

 

On 7/24/07, bai.xiaoyu AT gmail.com <bai.xiaoyu AT gmail.com> wrote:


On 7/22/07, Liu Xuefeng < xfliu.math AT gmail.com> wrote:

In my case, this error comes because the "token" info  is lost in the $_SESSION variable. I check the
code system and found that the "/tmp" folder is full and no space for server to write sesseion data into it.
So just delete the old session files in "/tmp" then everything works well!


Which /tmp folder? The one in the file system root?

I had same problem many many times, so would you please be more specific? My /tmp is certainly not full when I had the problem.




--
Liu Xuefeng
----------------------------------------------------------------------
  The Gradschool of Mathematics,
  The University of Tokyo,
  Tokyo, Japan, 153-8902
  Email: xfliu AT ms.u-tokyo.ac.jp
  Life handbook: http://jp-life.org  
----------------------------------------------------------------------


Archive powered by MHonArc 2.6.24.

Top of Page