Skip to content

Instantly share code, notes, and snippets.

@holman
Created February 3, 2011 00:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save holman/808790 to your computer and use it in GitHub Desktop.
Save holman/808790 to your computer and use it in GitHub Desktop.
CAS and OmniAuth
require 'rubygems'
require 'sinatra'
require 'net/https'
require 'omniauth/enterprise'
use OmniAuth::Builder do
provider :CAS, :cas_server => "http://localhost:8080/cas-server-webapp-3.4.5"
end
enable :sessions
enable :run
get '/' do
end
get '/auth/:name/callback' do
auth = request.env['omniauth.auth']
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment