This plugin for YOURLS enables the use of Central Authentication Service for user authentication. CAS is commonly used at higher-ed institutions to provide faculty, staff, and students with SSO (Single Sign-On) capability for web services.
- Download phpCAS and give your webserver (eg. Apache) read permissions on it
- Download the latest release of yourls-cas-plugin.
- Copy the plugin folder into your user/plugins folder for YOURLS.
- Set up the parameters for phpCAS (details below)
- Activate the plugin with the plugin manager in the admin interface.
When yourls-cas-plugin is enabled, the login screen will never be shown. Instead, you will be immediately redirected to the CAS server. If CAS login is successful, then you will immediately go to the admin interface.
PHPCAS_PATHThe path to where you installed the phpCAS library. This should be an absolute path ending with CAS.php.
PHPCAS_HOSTThe hostname of your CAS server
PHPCAS_CONTEXTThe webapp subdirectory of your CAS server (typically /cas)
PHPCAS_CERTCHAIN_PATHYou need a local copy of the certificate chain from the CAS server. That's the only way for phpCAS to verify the server's authenticity. Also, you can concatenate multiple certs into a single PEM file.
Check all of your error logs.
- PHP error log usually at
- phpCAS error log usually at
- And your Apache error_log, of course.
Copyright 2013 Nicholas Waller (firstname.lastname@example.org)
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.