Knowledgebase
Rutgers University-Newark SASN > RU-N SASN-IT AskMe Support Ticket System > Knowledgebase

Search help:


RUCAS / PHP CAS

Solution

RUCAS is an open source cas for within the university which acts as a decorator to the open source project apereo/phpCAS. Both RUCAS and phpCAS (for Php version 5 and 7 are available to download here. Please note that RUCAS inherits all of phpCAS's functions but was created to reduce amount of reconfiguration and functions ran by letting RUCAS handle the configurations.

 RUCAS will need to be configured either by changing the $default_config of the file or creating an ini file that is ran through RUCAS' parse_ini_file. RUCAS will need to be saved into the same directory as CAS.php. Afterwards, RUCAS.php can be included

include_once $LF_DIR."page.class.php";

Then, RUCAS and all the required functions that needed to be run can be invoked by

$rucas = new RUCAS();
$rucas->cas_authenticate();

 The CAS library will create a sassion variable $_SESSION['phpCAS']['user'] which your php code may be able to pick up and identify the user's NetID. If the page is behind a cas login, you may invoke

$rucas->getUser();

which will read the same variable but will ensure that the user is logged in.

Attachments:
CASforPhp5.zip CASforPhp5.zip
phpCASfor7-master.zip phpCASfor7-master.zip
RUCAS.zip RUCAS.zip

 
Was this article helpful? yes / no
Article details
Article ID: 11
Category: PHP Code
Date added: 2019-11-22 21:37:04
Views: 1161
Rating (Votes): Article not rated yet (0)

 
« Go back

 
Powered by Help Desk Software HESK, in partnership with SysAid Technologies