From 7a7f12a0c126522cb067de692af0950d46bf15fc Mon Sep 17 00:00:00 2001 From: Lukas Reschke Date: Wed, 31 Oct 2012 18:37:59 +0100 Subject: Create only one CSRF token per session Before, the CSRF token expired every hour. We had a script in place which should refresh the token but this don't worked in every case. (Laptop sleeping etc.) With this commit, the token will only get once created for every session so that the "Token expired" warning shouldn't appear. --- lib/template.php | 2 -- 1 file changed, 2 deletions(-) (limited to 'lib/template.php') diff --git a/lib/template.php b/lib/template.php index 1ad47cbe52c..caac6891cb8 100644 --- a/lib/template.php +++ b/lib/template.php @@ -172,7 +172,6 @@ class OC_Template{ $this->application = $app; $this->vars = array(); $this->vars['requesttoken'] = OC_Util::callRegister(); - $this->vars['requestlifespan'] = OC_Util::$callLifespan; $parts = explode('/', $app); // fix translation when app is something like core/lostpassword $this->l10n = OC_L10N::get($parts[0]); @@ -391,7 +390,6 @@ class OC_Template{ $page = new OC_TemplateLayout($this->renderas); if($this->renderas == 'user') { $page->assign('requesttoken', $this->vars['requesttoken']); - $page->assign('requestlifespan', $this->vars['requestlifespan']); } // Add custom headers -- cgit v1.2.3