0.0
Repository is archived
No release in over 3 years
Low commit activity in last 3 years
Ruby client for mod_auth_tkt. See http://www.openfusion.com.au/labs/mod_auth_tkt/
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Development

>= 0
>= 0
 Project Readme

apache-authtkt-ruby

PLEASE NOTE: This library is deprecated and no longer supported.

Ruby client for mod_auth_tkt (http://www.openfusion.com.au/labs/mod_auth_tkt/).

Inspired by http://meso.net/mod_auth_tkt yet implemented as a full class with test coverage.

Inspired by https://github.com/yabawock/devise_ticketable yet fully configurable.

Mostly a clean port from the Apache_AuthTkt implementation at https://github.com/publicinsightnetwork/audience-insight-repository/blob/master/lib/shared/Apache_AuthTkt.php

Example usage:

require "apache_authtkt"
atkt = ApacheAuthTkt.new(secret: 'fee-fi-fo-fum')
# create a ticket to set as a cookie
tkt = atkt.create_ticket(
       user: 'myusername',
       tokens: 'foo,bar,baz',
       user_data: 'some payload'
)

# validate an existing cookie ticket
if (validated = atkt.validate_ticket(tkt))
    puts 'user ' + validated[:user] + ' is authenticated'
end

Licensed under Apache License 2.0.