simplecas

PHP5 CAS Authentication library
This is a PHP 5 client library for JA-SIG Central Authentication Service (CAS).
Compatible with servers using version 1 or 2 of the CAS protocol.

Quick Example:

<?php

require_once 'SimpleCAS/Autoload.php';
require_once 'HTTP/Request2.php';

$options = array('hostname' => 'login.unl.edu',
                 'port'     => 443,
                 'uri'      => 'cas');
$protocol = new SimpleCAS_Protocol_Version2($options);

$client = SimpleCAS::client($protocol);
$client->forceAuthentication();

if (isset($_GET['logout'])) {
    $client->logout();
}

if ($client->isAuthenticated()) {
    echo '<h1>Authentication Successful!</h1>
          <p>The user\'s login is '.$client->getUsername().'</p>
          <a href="?logout">Logout</a>';
}
?>
current version: 0.5.0
Date Added: Feb 8th, 2010
Filed in: projects » PHP Scripts » PHP Class Scripts » User Management
Publisher: jooria
Contact Info: Send a Message to jooria
the team: view the project Peoples
0 points ( 0% like it)

0 up votes 0 down votes

I Use It - simple:
0 person is using this project