Skip to content

creativecommons/rubycas-client-rails

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code
This branch is 5 commits ahead of rubycas:master.

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
lib
 
 
 
 
 
 
 
 
 
 
 
 

RubyCAS-Client-Rails

Rails plugin for using the RubyCAS-Client as a controller filter.

This uses a Railtie, so will only work with Rails 3.0 and up.

Installation

Add the following to your Gemfile:

gem 'rubycas-client-rails'

Then run bundler in your Rails app's root directory:

bundle install

Once the necessary gems have been installed, in your application.rb add:

config.rubycas.cas_base_url = 'https://cas.example.com/'

Finally, to enable the CAS filter for a controller:

class MyController < ApplicationController

  before_filter RubyCAS::Filter

If you want authentication to be optional, use the GatewayFilter instead:

  before_filter RubyCAS::GatewayFilter

Many other configuration options are available. For example you can instruct the client to log its actions to the default Rails logger using:

config.rubycas.logger = Rails.logger

See the (outdated) documentation at http://rubycas-client.rubyforge.org/ for a full list of config options.

Copyright (c) 2011 University of Toronto, released under the MIT license

About

Rails plugin for the RubyCAS-Client

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 100.0%