dhall-1.42.1: A configuration language guaranteed to terminate

Safe Haskell | Safe-Inferred
Language | Haskell2010

Dhall.Crypto

Description

This module provides implementations of cryptographic utilities that only work for GHC (as opposed to GHCJS)

Synopsis

- newtype SHA256Digest = SHA256Digest {
  - unSHA256Digest :: ByteString
  }
- sha256DigestFromByteString :: ByteString -> Maybe SHA256Digest
- sha256Hash :: ByteString -> SHA256Digest
- toString :: SHA256Digest -> String

# Documentation

newtype SHA256Digest Source #

A SHA256 digest

Constructors

SHA256Digest |

Fields

- unSHA256Digest :: ByteString

#### Instances

Instances details

Data SHA256Digest Source # |

Instance details

Defined in Dhall.Crypto

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SHA256Digest -> c SHA256Digest Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SHA256Digest Source #

toConstr :: SHA256Digest -> Constr Source #

dataTypeOf :: SHA256Digest -> DataType Source #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c SHA256Digest) Source #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SHA256Digest) Source #

gmapT :: (forall b. Data b => b -> b) -> SHA256Digest -> SHA256Digest Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SHA256Digest -> r Source #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SHA256Digest -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> SHA256Digest -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SHA256Digest -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SHA256Digest -> m SHA256Digest Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SHA256Digest -> m SHA256Digest Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SHA256Digest -> m SHA256Digest Source #

Generic SHA256Digest Source # |
Instance details Defined in Dhall.Crypto Associated Types type Rep SHA256Digest :: Type -> Type Source # Methods from :: SHA256Digest -> Rep SHA256Digest x Source # to :: Rep SHA256Digest x -> SHA256Digest Source #
Show SHA256Digest Source # |
Instance details Defined in Dhall.Crypto Methods showsPrec :: Int -> SHA256Digest -> ShowS Source # show :: SHA256Digest -> String Source # showList :: [SHA256Digest] -> ShowS Source #
NFData SHA256Digest Source # |
Instance details Defined in Dhall.Crypto Methods rnf :: SHA256Digest -> () Source #
Eq SHA256Digest Source # |
Instance details Defined in Dhall.Crypto Methods (==) :: SHA256Digest -> SHA256Digest -> Bool Source # (/=) :: SHA256Digest -> SHA256Digest -> Bool Source #
Ord SHA256Digest Source # |

Instance details

Defined in Dhall.Crypto

Methods

compare :: SHA256Digest -> SHA256Digest -> Ordering Source #

(<) :: SHA256Digest -> SHA256Digest -> Bool Source #

(<=) :: SHA256Digest -> SHA256Digest -> Bool Source #

(>) :: SHA256Digest -> SHA256Digest -> Bool Source #

(>=) :: SHA256Digest -> SHA256Digest -> Bool Source #

max :: SHA256Digest -> SHA256Digest -> SHA256Digest Source #

min :: SHA256Digest -> SHA256Digest -> SHA256Digest Source #

type Rep SHA256Digest Source # |
Instance details Defined in Dhall.Crypto type Rep SHA256Digest = D1 ('MetaData "SHA256Digest" "Dhall.Crypto" "dhall-1.42.1-7b0ByofrhTXEEGXFFBDlY2" 'True) (C1 ('MetaCons "SHA256Digest" 'PrefixI 'True) (S1 ('MetaSel ('Just "unSHA256Digest") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ByteString)))

sha256DigestFromByteString :: ByteString -> Maybe SHA256Digest Source #

Attempt to interpret a `ByteString` as a `SHA256Digest`, returning `Nothing` if the conversion fails

sha256Hash :: ByteString -> SHA256Digest Source #

Hash a `ByteString` and return the hash as a `SHA256Digest`

toString :: SHA256Digest -> String Source #

`String` representation of a `SHA256Digest`