PHPackages                             csi-uksw/laravel-cas - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. csi-uksw/laravel-cas

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

csi-uksw/laravel-cas
====================

UKSW CAS auth module for Laravel 5.1

1.0.1(9y ago)31361[1 issues](https://github.com/csi-uksw/laravel-cas/issues)MITPHPPHP &gt;=5.5.9

Since Nov 19Pushed 9y ago2 watchersCompare

[ Source](https://github.com/csi-uksw/laravel-cas)[ Packagist](https://packagist.org/packages/csi-uksw/laravel-cas)[ RSS](/packages/csi-uksw-laravel-cas/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (1)Dependencies (2)Versions (3)Used By (0)

Installation
============

[](#installation)

Versions
--------

[](#versions)

Version 1.0 requires PHP 5.5.9+.

Laravel 5.1
-----------

[](#laravel-51)

To install this package pull it in through Composer.

```
composer require csi-uksw/laravel-cas
```

After Composer is done, you need to tell your application to use the CAS service provider.

Open `config/app.php` and add the service provider

`CSI_UKSW\Laravel\CAS\CASServiceProvider::class`

after

`Illuminate\Auth\AuthServiceProvider::class`

As well the Facade :

`'CAS' => CSI_UKSW\Laravel\CAS\Facades\CAS::class`

Configuration
=============

[](#configuration)

#### Basic

[](#basic)

To set up your CAS for connections you have to publish CAS config. This will provide all the configuration values for your connection.

```
php artisan vendor:publish --provider="CSI_UKSW\Laravel\CAS\CASServiceProvider"

```

After that please edit your `app/cas.php`. Using the `.env` file will allow you to have different environments without even touching the `app/cas.php` config file.

#### Middleware

[](#middleware)

Optionally you can use provided Auth Middleware.

After publishing please edit your `app/Http/Kernel.php`

```
protected $routeMiddleware = [
    'auth.cas' => \CSI_UKSW\Laravel\CAS\Http\Middleware\CASAuthMiddleware::class
];
```

Usage
=====

[](#usage)

Authenticate:

`CAS::authenticate()`

Logout:

`CAS::logout()`

Get username:

`CAS::getUser()`

Get user attributes:

`CAS::getAttributes()`

Check if is authenticated:

`CAS::isAuthenticated()`

Route middleware:

```
Route::group(['middleware' => 'auth.cas'], function () {
   get('cas', function(){
       echo 'authorized only';
   });
});
```

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance13

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community5

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~517 days

Total

2

Last Release

3356d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/67e9ee33cd2325ac0f90121fa0a09aa21ba9ed2a519b3b0ab2f34e4156f2a368?d=identicon)[csi-uksw](/maintainers/csi-uksw)

---

Tags

casCSIUKSW

### Embed Badge

![Health badge](/badges/csi-uksw-laravel-cas/health.svg)

```
[![Health](https://phpackages.com/badges/csi-uksw-laravel-cas/health.svg)](https://phpackages.com/packages/csi-uksw-laravel-cas)
```

###  Alternatives

[directorytree/ldaprecord-laravel

LDAP Authentication &amp; Management for Laravel.

5742.2M17](/packages/directorytree-ldaprecord-laravel)[illuminate/auth

The Illuminate Auth package.

9327.9M1.2k](/packages/illuminate-auth)[xavrsl/cas

Add CAS server SSO authentication to Laravel 4 and 5

7637.1k](/packages/xavrsl-cas)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
