CAS - query string dropped from URL upon redirect

john.davies.nau - April 13, 2009 - 19:15
Project:CAS
Version:6.x-1.0
Component:Miscellaneous
Category:support request
Priority:normal
Assigned:Unassigned
Status:active
Description

Drupal 6.10
CAS module 6.x-1.0
Module settings

I have CAS set up and working on my Drupal install. However, when I am viewing a module that has a query string in the URL and requires CAS authentication, I am redirected to the CAS server, authenticated, redirected back to the original page with the query string and ticket in the URL, then redirected to the same module page WITHOUT the query string. Like this:

  1. http://www.example.com/drupal/mymodule/?categories=photoshop
  2. https://cas.example.com:443/cas/login?service=http%3A%2F%2Fwww.example.c...
  3. http://www.example.com/drupal/mymodule/?categories=photoshop&ticket=ST-X...
  4. http://www.example.com/drupal/mymodule/

I have set the "Specific Pages" option to
mymodule
mymodule/*

Is this a bug in the code or a setting I missed somewhere?

#1

metzlerd - April 13, 2009 - 20:34

Yes, I think the CAS Server can't really handle adding the q back on. Is it possible for you to enable clean urls for your site? That's the way that most of mine run.

Dave

#2

john.davies.nau - April 14, 2009 - 15:50

Thanks, Dave, but I already have clean URLs turned on. This module uses query strings instead of clean URLs, tho. One important thing to note, though, is that the CAS server correctly handled the request and sends me back to the correct originating URL (AFAIK) and then the CAS module strips the ticket param AND the other query params off of the query string.

In the interest of time, I don't want to have to rewrite the module to use clean urls. But if I did rewrite it, what would I need to do to my .htaccess to get it to work?

 
 

Drupal is a registered trademark of Dries Buytaert.