• I’m using CAS Maestro to authenticated against our university’s CAS system, from an application running on a third-party web host (Pantheon). Recently Pantheon has changed some of the way they handle server provisioning and DNS, and that’s broken my CAS authentication because of the way the HTTP GET URL is built before it’s passed to the CAS server.

    The problem is that the environment variable $SERVER[‘SERVER_NAME’] and $SERVER[‘HTTP_HOST’] are not the same. $SERVER[‘SERVER_NAME’] is the internal Pantheon host name; $SERVER[‘HTTP_HOST’] is the public URL of the site. When our CAS server sees the internal Pantheon host name, it rejects the authentication request.

    I was able to work around this by changing line 3094 in phpCAS/CAS/Client.php to always use HTTP_HOST in preference to SERVER_NAME, but I’m not sure that’s a robust solution; I’d expect a CAS Maestro update to break the hack I just made. Is there a way to make this a parameter within CAS Maestro, or to use the WordPress site address instead of the server environment variable or something?

    https://wordpress.org/plugins/cas-maestro/

  • The topic ‘Getting own url for HTTP string’ is closed to new replies.