CAS redirects to last "page not found" error on login
kevee - March 2, 2009 - 23:22
| Project: | CAS |
| Version: | 6.x-1.0 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
If a user is within our site and hits a resource, say an image, that is not found, then logs out and logs back in again, they get redirected to a "page not found" page with the url of the missing resource from their previous session.
This only occurs if we have the 'Force Redirect on login' option turned on.

#1
Can you tell me whether you're using private files or public (does apache handle image files or drupal)?
#2
Good question...
we are using public files. I have tried to turn that opion on and off in our devel environment and can still reproduce the error.
Once I get back home from DrupalCon, I'll start working through the module to find the cause....
#3
I'm seeing some occasional behavior somewhat like your seeing. I'm planning a major CAS code sprint in the next month or so, so I'll likely get to it then.
#4
Found the problem: the CAS cas_save_page() function sets the session variable 'cas_goto' for every item on the page which is not found, and therefore subsequently overrides the cas_goto page for the currently loaded page. Will look into if this can be overridden by having a custom 404 page and adding it to the exception list of redirected pages.
The module should probably check that the page exists before adding it to the session.