From 74113fad490ccdaa00961c5818eaa107781dfd79 Mon Sep 17 00:00:00 2001 From: Quentin Dufour Date: Fri, 15 Sep 2023 14:32:44 +0200 Subject: WIP auth API --- main.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'main.go') diff --git a/main.go b/main.go index 92fd2dc..1402ff2 100644 --- a/main.go +++ b/main.go @@ -130,6 +130,8 @@ func main() { r.HandleFunc("/", handleHome) r.HandleFunc("/logout", handleLogout) + r.HandleFunc("/api/unstable/garage/bucket/{b}", handleAPIGarageBucket) + r.HandleFunc("/profile", handleProfile) r.HandleFunc("/passwd", handlePasswd) r.HandleFunc("/picture/{name}", handleDownloadPicture) @@ -198,9 +200,6 @@ func logRequest(handler http.Handler) http.Handler { func checkLogin(w http.ResponseWriter, r *http.Request) *LoginStatus { var login_info *LoginInfo - //@FIXME check authentication header - - session, err := store.Get(r, SESSION_NAME) if err == nil { username, ok := session.Values["login_username"] -- cgit v1.2.3