diff options
author | Joram Wilander <jwawilander@gmail.com> | 2017-05-09 07:48:57 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-09 07:48:57 -0500 |
commit | 202c383d8dc23ff3c0633fff99bd7da95397fe3a (patch) | |
tree | b9f06ca4dd84a90fd53676347820898c951829ef /api4/user.go | |
parent | fb4d72bd8a3a9b533571e42cfb1b7e2d1702f6be (diff) | |
download | chat-202c383d8dc23ff3c0633fff99bd7da95397fe3a.tar.gz chat-202c383d8dc23ff3c0633fff99bd7da95397fe3a.tar.bz2 chat-202c383d8dc23ff3c0633fff99bd7da95397fe3a.zip |
Fix MFA enforcement on login and page load (#6356)
Diffstat (limited to 'api4/user.go')
-rw-r--r-- | api4/user.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/api4/user.go b/api4/user.go index 1436808cd..d06dd2882 100644 --- a/api4/user.go +++ b/api4/user.go @@ -41,8 +41,8 @@ func InitUser() { BaseRoutes.Users.Handle("/email/verify/send", ApiHandler(sendVerificationEmail)).Methods("POST") BaseRoutes.Users.Handle("/mfa", ApiHandler(checkUserMfa)).Methods("POST") - BaseRoutes.User.Handle("/mfa", ApiSessionRequired(updateUserMfa)).Methods("PUT") - BaseRoutes.User.Handle("/mfa/generate", ApiSessionRequired(generateMfaSecret)).Methods("POST") + BaseRoutes.User.Handle("/mfa", ApiSessionRequiredMfa(updateUserMfa)).Methods("PUT") + BaseRoutes.User.Handle("/mfa/generate", ApiSessionRequiredMfa(generateMfaSecret)).Methods("POST") BaseRoutes.Users.Handle("/login", ApiHandler(login)).Methods("POST") BaseRoutes.Users.Handle("/login/switch", ApiHandler(switchAccountType)).Methods("POST") |