# Überauth CAS Strategy


Central Authentication Service strategy for Überauth.

## Installation

1. Add `ueberauth` and `ueberauth_cas` to your list of dependencies in `mix.exs`:

   def deps do
       {:ueberauth, "~> 0.2"},
       {:ueberauth_cas, "~> 2.0.0"}

2. Ensure `ueberauth_cas` is started before your application:

   def application do
     [applications: [:ueberauth_cas]]

3. Configure the CAS integration in `config/config.exs`:

   config :ueberauth, Ueberauth,
     providers: [cas: {Ueberauth.Strategy.CAS, [
       base_url: "",
       callback_url: "",

4. Include the Überauth plug in your controller:

   defmodule MyApp.AuthController do
     use MyApp.Web, :controller
     plug Ueberauth

5. Create the request and callback routes if you haven't already:

   scope "/auth", MyApp do
     pipe_through :browser

     get "/:provider", AuthController, :request
     get "/:provider/callback", AuthController, :callback

6. Your controller needs to implement callbacks to deal with `Ueberauth.Auth` and `Ueberauth.Failure` responses.

## Compatibility

Überauth CAS was tested with the [Casino]( CAS server
implementation. Please let me know if Überauth CAS is incompatible with your CAS
server, and why.

The docs contain more information about protocol specifics.