summaryrefslogtreecommitdiff
path: root/lisp/service/logout-service.lisp
diff options
context:
space:
mode:
authorckonstanski <carlos.konstanski@olo.com>2021-11-27 10:20:12 -0700
committerckonstanski <carlos.konstanski@olo.com>2021-11-27 10:20:12 -0700
commit31657f6854edc116946a099be889440fb3e92e53 (patch)
treebe32747cfaf2f19f59857349438d62fb4a4a25b6 /lisp/service/logout-service.lisp
parent41ca4dcf8a18a76c48734a5fca4c56afb735a66e (diff)
moved everything under lisp/
Diffstat (limited to 'lisp/service/logout-service.lisp')
-rw-r--r--lisp/service/logout-service.lisp14
1 files changed, 14 insertions, 0 deletions
diff --git a/lisp/service/logout-service.lisp b/lisp/service/logout-service.lisp
new file mode 100644
index 0000000..59a9968
--- /dev/null
+++ b/lisp/service/logout-service.lisp
@@ -0,0 +1,14 @@
+;;; -*- Mode: Lisp; Syntax: ANSI-Common-Lisp; Base: 10 -*-
+(declaim (optimize (speed 0) (safety 3) (debug 3)))
+
+(in-package :ldapadmin)
+
+(defclass logout-service (rest-service)
+ ((location-p :initform nil))
+ (:documentation ""))
+
+(defun logout-json ()
+ (with-noauth (instance logout-service)
+ (setf (session-value :permissions) "anonymous")
+ (setf (location instance) "/home")
+ (setf (message instance) "You are now logged out.")))