Treat JWT as a Secret, not String

This commit is contained in:
Joe Nelson
2015-11-19 09:58:41 -08:00
parent 2c3a52fc35
commit 87c946ef52
5 changed files with 12 additions and 9 deletions
+1 -1
View File
@@ -51,7 +51,7 @@ runWithClaims conf app req = do
where
stmt c = B.Stmt c V.empty True
hdrs = requestHeaders req
jwtSecret = (cs $ configJwtSecret conf) :: Text
jwtSecret = configJwtSecret conf
auth = fromMaybe "" $ lookup hAuthorization hdrs
anon = cs $ configAnonRole conf
setAnon = setRole anon