Benzene/login-commons
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|
Repository files navigation
A very simple way to handle user authentication in Sinatra. Use with "require 'loginHandler'" The users are stored in a sqlite3 db. The path is hard-coded to 'users.db'. Schema is given by 'initLoginHandler.sql' file. Use given helpers (require_auth, require_non_auth, is_authed?) to check for authentication, and session[:user] to access the current username.