yesod-auth-hashdb 1.6.1 → 1.6.2
raw patch · 4 files changed
+14/−10 lines, 4 filesdep −pwstore-fastdep ~yesod-auth
Dependencies removed: pwstore-fast
Dependency ranges changed: yesod-auth
Files
- ChangeLog.md +4/−0
- Yesod/Auth/HashDB.hs +5/−5
- stack.yaml +3/−2
- yesod-auth-hashdb.cabal +2/−3
ChangeLog.md view
@@ -1,3 +1,7 @@+## 1.6.2++* Use `PasswordStore` from `yesod-auth` instead of `pwstore-fast` (uses `cryptonite` instead of `cryptohash`)+ ## 1.6.1 * Relax upper bound on persistent
Yesod/Auth/HashDB.hs view
@@ -69,7 +69,7 @@ -- password hash as follows: -- -- > ghci -XOverloadedStrings--- > > import Crypto.PasswordStore+-- > > import Yesod.Auth.Util.PasswordStore -- > > makePassword "MyPassword" 17 -- -- where \"17\" is the default strength parameter ('defaultStrength') used@@ -169,7 +169,7 @@ #if __GLASGOW_HASKELL__ < 710 import Control.Applicative ((<$>), (<*>), pure) #endif-import Crypto.PasswordStore (makePassword, strengthenPassword,+import Yesod.Auth.Util.PasswordStore (makePassword, strengthenPassword, verifyPassword, passwordStrength) import Data.Aeson ((.:?)) import qualified Data.ByteString.Char8 as BS (pack, unpack)@@ -186,8 +186,8 @@ defaultCsrfParamName = "_token" #endif --- | Default strength used for passwords (see "Crypto.PasswordStore" for--- details).+-- | Default strength used for passwords (see "Yesod.Auth.Util.PasswordStore"+-- for details). defaultStrength :: Int defaultStrength = 17 @@ -209,7 +209,7 @@ {-# MINIMAL userPasswordHash, setPasswordHash #-} --- | Calculate a new-style password hash using "Crypto.PasswordStore".+-- | Calculate a new-style password hash using "Yesod.Auth.Util.PasswordStore". passwordHash :: MonadIO m => Int -> Text -> m Text passwordHash strength pwd = do h <- liftIO $ makePassword (BS.pack $ unpack pwd) strength
stack.yaml view
@@ -1,4 +1,5 @@-resolver: lts-6.6+resolver: lts-8.24 packages: - .-extra-deps: []+extra-deps:+- yesod-auth-1.4.18
yesod-auth-hashdb.cabal view
@@ -1,5 +1,5 @@ name: yesod-auth-hashdb-version: 1.6.1+version: 1.6.2 license: MIT license-file: LICENSE author: Patrick Brisbin, later changes Paul Rouse@@ -35,12 +35,11 @@ build-depends: base >= 4 && < 5 , bytestring >= 0.9.1.4 , yesod-core >= 1.4 && < 1.5- , yesod-auth >= 1.4 && < 1.5+ , yesod-auth >= 1.4.18 && < 1.5 , text >= 0.7 , yesod-persistent >= 1.2 , persistent >= 2.1 && < 2.8 , yesod-form >= 1.4 && < 1.5- , pwstore-fast >= 2.2 , aeson exposed-modules: Yesod.Auth.HashDB