Skip to content

The core logic for handling CAS requests independent of any particular storage or web presentation technology.

License

Notifications You must be signed in to change notification settings

bebraven/rubycas-server-core

 
 

Repository files navigation

rubycas-server-core

Circle CI

The core logic for handling CAS requests independent of any particular storage or web presentation technology.

Requirements

  • ruby 1.9.x

Adapters

Currently available adapters are:

If you want to create a new adapter check these 2 adapters how they are implemented. Essentially you need to implement the following methods for each ticket:

class XXXTicket
  def initialize(options = {})
  end
  
  #deprecated
  def self.find_by_ticket(ticket)
    #returns the ticket based on the ticket id
    #it will be removed soon
  end
  
  def self.find_by(opts = {})
    #returns the ticket based on the constraints in the hash (activerecord-style)
  end
  
  def save!
    #saves the ticket in the storage
    #throws an exception in case of an error
  end
  
  def save
    #saves the ticket in the storage
  end

  def consumed?
    #returns true if ticket is already consumed
  end

  def consume!
    #consumes the ticket
  end

  def expired?(max_lifetime = 100)
    #checks if the ticket is already expired
  end

end

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

Coding conventions

  1. String object as a hash key for all settings from Setting class.

About

The core logic for handling CAS requests independent of any particular storage or web presentation technology.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 100.0%