module Raaz.V1.AuthEncrypt.Unsafe
( Locked
, unsafeLock, unsafeLockWith
, Cipher, AuthTag
, unsafeToNounce, unsafeToCipherText, unsafeToAuthTag
, unsafeLocked
) where
import Data.ByteString
import Raaz.Core
import qualified Raaz.AuthEncrypt.Unsafe.XChaCha20Poly1305 as AE
import Raaz.AuthEncrypt.Unsafe.XChaCha20Poly1305 ( Locked, Cipher, AuthTag
)
unsafeLockWith :: ( Encodable plain, Encodable aad)
=> aad
-> Key Cipher
-> Nounce Cipher
-> plain
-> Locked
unsafeLockWith :: aad -> Key Cipher -> Nounce Cipher -> plain -> Locked
unsafeLockWith = aad -> Key Cipher -> Nounce Cipher -> plain -> Locked
forall plain aad.
(Encodable plain, Encodable aad) =>
aad -> Key Cipher -> Nounce Cipher -> plain -> Locked
AE.unsafeLockWith
unsafeLock :: Encodable plain
=> Key Cipher
-> Nounce Cipher
-> plain
-> Locked
unsafeLock :: Key Cipher -> Nounce Cipher -> plain -> Locked
unsafeLock = Key Cipher -> Nounce Cipher -> plain -> Locked
forall plain.
Encodable plain =>
Key Cipher -> Nounce Cipher -> plain -> Locked
AE.unsafeLock
unsafeToCipherText :: Locked
-> ByteString
unsafeToCipherText :: Locked -> ByteString
unsafeToCipherText = Locked -> ByteString
forall c t. AEAD c t -> ByteString
AE.unsafeToCipherText
unsafeToAuthTag :: Locked -> AE.AuthTag
unsafeToAuthTag :: Locked -> AuthTag
unsafeToAuthTag = Locked -> AuthTag
forall c t. AEAD c t -> t
AE.unsafeToAuthTag
unsafeToNounce :: Locked -> Nounce Cipher
unsafeToNounce :: Locked -> Nounce Cipher
unsafeToNounce = Locked -> Nounce Cipher
forall c t. AEAD c t -> Nounce c
AE.unsafeToNounce
unsafeLocked :: Nounce Cipher
-> ByteString
-> AE.AuthTag
-> Locked
unsafeLocked :: Nounce Cipher -> ByteString -> AuthTag -> Locked
unsafeLocked = Nounce Cipher -> ByteString -> AuthTag -> Locked
AE.unsafeLocked