Bug #6875

survey access link with plugin CAS

Added by Joachim Lucas over 6 years ago. Updated about 6 years ago.

Bug resolved
Target version:
Start date:
Due date:
% Done:


Estimated time:
SCRUM pts - complexity:



When you activate CAS auth for chamilo, the direct access link survey for non-logged users doesn't work correctly.

For example, when a user receives a link by email offering to respond to a survey, it can be clicked and then it's correctly redirected to the survey, but it can't close it because in fact at every step no datas are posted.

I think the CAS plugin is involved and each page posted ("next question" button for example) is first redirected to CAS. So posted datas are lost !

[a fresh local install with no CAS auth hasn't this problem]


survey_bug1.jpg (15.8 KB) survey_bug1.jpg Kevin LEVRON, 17/01/2014 16:19

Associated revisions

Revision eecab136 (diff)
Added by baelmyhu about 6 years ago

Fill survey from email URL with code works with CAS enbled -ref #6875



Updated by Kevin LEVRON over 6 years ago


Same here, tested on 1.9.4 and 1.9.6.
You are right Joachim.


Updated by Yannick Warnier about 6 years ago

  • Category set to Survey
  • Assignee set to Hubert Borderiou
  • Target version set to 1.9.8

Hubert, you're the CAS-man, I think. Any chance you could look into this one?


Updated by Hubert Borderiou about 6 years ago

Ok, I confirm the bug.
I'll work on it.


Updated by Hubert Borderiou about 6 years ago

I've found the instruction that causes the problem.
It is in file main/auth/cas/lib/CAS/client.php
on function checkAuthentication()
line 892 unset($_SESSION['phpCAS']['auth_checked']);
(// the previous request has redirected the client to the CAS server with gateway=true)
If I comment this line it works fine, the page has the html code 302 Moved temporarely, and the survey is stored in the bdd.
I've tested my CAS with this line commented, and everything is fine for me.

Can you test it please, if it is ok for you, I guess we should comment this line... not proud of it...


Updated by Joachim Lucas about 6 years ago

It seems to be working very well !


Updated by Hubert Borderiou about 6 years ago

  • Status changed from New to Bug resolved
  • Assignee deleted (Hubert Borderiou)

Ok, thanks for your feedback Joachim
I close the task.

Also available in: Atom PDF