(authentication-filter handler options)
Checks that the request is carrying CAS credentials (but does not validate them)
Checks that the request is carrying CAS credentials (but does not validate them)
(BYU-CAS-service s)
Returns a function that returns s because functions are required
Returns a function that returns s because functions are required
(is-logged-in? req)
Takes a request and determines whether the requesting user is logged in or not.
Takes a request and determines whether the requesting user is logged in or not.
(logout-resp)
(logout-resp redirect-url)
Produces a response map that logs user out of the application (by ending the session) and CAS (by redirecting to the CAS logout endpoint). Optionally takes a redirect URL which CAS uses to redirect the user (again!) after logout. Redirect URL should be the full URL, including "https:"
Produces a response map that logs user out of the application (by ending the session) and CAS (by redirecting to the CAS logout endpoint). Optionally takes a redirect URL which CAS uses to redirect the user (again!) after logout. Redirect URL should be the *full* URL, including "https:"
(set-timeout duration resp)
Takes a number of minutes and a response. Sets a time in :session, after which user will be logged out.
Takes a number of minutes and a response. Sets a time in :session, after which user will be logged out.
(user-principal-filter handler)
Takes username and cas-info from request, and moves them into :username and :cas-info keys in the top level of the request map (rather than being buried in :query-params or :session).
Takes username and cas-info from request, and moves them into :username and :cas-info keys in the top level of the request map (rather than being buried in :query-params or :session).
(wrap-cas & args)
Middleware that requires the user to authenticate with a CAS server. Is dependent on wrap-params and wrap-session; the general call will look something like (-> handler (wrap-cas :timeout 120) (wrap-session) (wrap-params)) The users's username is added to the request map under the :username key. Accepts the following options: :enabled - when false, the middleware does nothing :no-redirect? - if this predicate function returns true for a request, a 403 Forbidden response will be returned instead of a 302 Found redirect :server - the target cas server :timeout - takes a number representing the length (in minutes) of the timeout period. BYU recommends 120 (two hours), see README :host-override - host to redirect to after CAS authentication (if nil, host is obtained from request header)
Middleware that requires the user to authenticate with a CAS server. Is dependent on wrap-params and wrap-session; the general call will look something like (-> handler (wrap-cas :timeout 120) (wrap-session) (wrap-params)) The users's username is added to the request map under the :username key. Accepts the following options: :enabled - when false, the middleware does nothing :no-redirect? - if this predicate function returns true for a request, a 403 Forbidden response will be returned instead of a 302 Found redirect :server - the target cas server :timeout - takes a number representing the length (in minutes) of the timeout period. BYU recommends 120 (two hours), see README :host-override - host to redirect to after CAS authentication (if nil, host is obtained from request header)
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close