public function initCsrfValidator() { $cookieKey = $this->getCookieKey(); if ($cookieKey == null) { $cookieKey = Application_Model_Cookie::generateRandomKey(); } $mapper = new Application_Model_CsrfhashMapper(); $rightHashes = $mapper->findAllCsrfForUser($cookieKey); $validator = new Application_Form_WebaceCSRFValidator($rightHashes); $this->addValidator($validator, true); return $this; }