Sha256: 93a912887b03121c7a88592dc84a88ad4896d13ed68b3c5dc98c482399631a5e

Contents?: true

Size: 1.1 KB

Versions: 1

Compression:

Stored size: 1.1 KB

Contents

require 'glue'

# Auth provides authentication and authorization for Nitro.
module Auth
    Version = '0.2.0'

    #--
    # Things I wish were settings, but setting doesn't appear to do
    # what I'm needing...
    # FIXME:  Figure out some sane way to put these in config.
    #
    # setting :admin_role, :default => 'admin',
    #     :doc => 'The administrative/superuser role name.'
    # setting :user_role, :default => 'user',
    #     :doc => 'The default role name (all users get this by default).'
    # setting :session_key_expiration, :default => 60 * 60 * 24 * 30,
    #     :doc => 'Number of seconds session keys last before expiring.'
    #++

    # The administrative/superuser role name.
    def self.admin_role
        'admin'
    end

    # The default role name (all users get this by default).
    def self.user_role
        'user'
    end

    # Number of seconds session keys last before expiring.
    def self.session_key_expiration
        60*60*24*30
    end
end

require 'nitro/auth/util/crypt'

require 'nitro/auth/model/user'

require 'nitro/auth/controller'
require 'nitro/auth/auth_controller'

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
nitro-auth-0.2.0 lib/nitro/auth.rb