Safe Haskell | Safe-Inferred |
---|---|
Language | GHC2021 |
Synopsis
- data Password
- data PasswordStatus
- genPassword :: MonadIO m => m PlainTextPassword8
- mkSafePasswordScrypt :: MonadIO m => PlainTextPassword' t -> m Password
- mkSafePasswordArgon2id :: MonadIO m => PlainTextPassword' t -> m Password
- verifyPassword :: PlainTextPassword' t -> Password -> Bool
- verifyPasswordWithStatus :: PlainTextPassword' t -> Password -> (Bool, PasswordStatus)
- unsafeMkPassword :: Text -> Password
- hashPasswordArgon2idWithSalt :: ByteString -> ByteString -> Text
- hashPasswordArgon2idWithOptions :: Argon2idOptions -> ByteString -> ByteString -> Text
- newtype PasswordReqBody = PasswordReqBody {}
Documentation
A derived, stretched password that can be safely stored.
data PasswordStatus Source #
Instances
Show PasswordStatus Source # | |
Defined in Wire.API.Password showsPrec :: Int -> PasswordStatus -> ShowS # show :: PasswordStatus -> String # showList :: [PasswordStatus] -> ShowS # | |
Eq PasswordStatus Source # | |
Defined in Wire.API.Password (==) :: PasswordStatus -> PasswordStatus -> Bool # (/=) :: PasswordStatus -> PasswordStatus -> Bool # |
genPassword :: MonadIO m => m PlainTextPassword8 Source #
mkSafePasswordScrypt :: MonadIO m => PlainTextPassword' t -> m Password Source #
mkSafePasswordArgon2id :: MonadIO m => PlainTextPassword' t -> m Password Source #
verifyPassword :: PlainTextPassword' t -> Password -> Bool Source #
Verify a plaintext password from user input against a stretched password from persistent storage.
verifyPasswordWithStatus :: PlainTextPassword' t -> Password -> (Bool, PasswordStatus) Source #
unsafeMkPassword :: Text -> Password Source #
hashPasswordArgon2idWithOptions :: Argon2idOptions -> ByteString -> ByteString -> Text Source #
newtype PasswordReqBody Source #
Instances
FromJSON PasswordReqBody Source # | |
Defined in Wire.API.Password parseJSON :: Value -> Parser PasswordReqBody Source # parseJSONList :: Value -> Parser [PasswordReqBody] Source # | |
ToJSON PasswordReqBody Source # | |
Defined in Wire.API.Password toJSON :: PasswordReqBody -> Value Source # toEncoding :: PasswordReqBody -> Encoding Source # toJSONList :: [PasswordReqBody] -> Value Source # toEncodingList :: [PasswordReqBody] -> Encoding Source # | |
Show PasswordReqBody Source # | |
Defined in Wire.API.Password showsPrec :: Int -> PasswordReqBody -> ShowS # show :: PasswordReqBody -> String # showList :: [PasswordReqBody] -> ShowS # | |
Eq PasswordReqBody Source # | |
Defined in Wire.API.Password (==) :: PasswordReqBody -> PasswordReqBody -> Bool # (/=) :: PasswordReqBody -> PasswordReqBody -> Bool # | |
ToSchema PasswordReqBody Source # | |
Defined in Wire.API.Password | |
ToSchema PasswordReqBody Source # | |
Defined in Wire.API.Password |