summaryrefslogtreecommitdiff
path: root/Utility/WebApp.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Utility/WebApp.hs')
-rw-r--r--Utility/WebApp.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/Utility/WebApp.hs b/Utility/WebApp.hs
index ce6a61c42..1a068a9b2 100644
--- a/Utility/WebApp.hs
+++ b/Utility/WebApp.hs
@@ -185,7 +185,7 @@ fromAuthToken = TE.decodeLatin1 . toBytes
fromAuthToken = id
#endif
-{- Generates a random sha512 string, encapsulated in a SecureMem,
+{- Generates a random sha2_512 string, encapsulated in a SecureMem,
- suitable to be used for an authentication secret. -}
genAuthToken :: IO AuthToken
genAuthToken = do
@@ -193,7 +193,7 @@ genAuthToken = do
return $
case genBytes 512 g of
Left e -> error $ "failed to generate auth token: " ++ show e
- Right (s, _) -> toAuthToken $ T.pack $ show $ sha512 $ L.fromChunks [s]
+ Right (s, _) -> toAuthToken $ T.pack $ show $ sha2_512 $ L.fromChunks [s]
{- A Yesod isAuthorized method, which checks the auth cgi parameter
- against a token extracted from the Yesod application.