remove Byteable in one module
This commit is contained in:
parent
65780e38cb
commit
28e64ec8d3
@ -11,9 +11,9 @@ module Crypto.Cipher.Types.AEAD where
|
|||||||
|
|
||||||
import Data.ByteString (ByteString)
|
import Data.ByteString (ByteString)
|
||||||
import qualified Data.ByteString as B
|
import qualified Data.ByteString as B
|
||||||
import Data.Byteable
|
|
||||||
import Crypto.Cipher.Types.Base
|
import Crypto.Cipher.Types.Base
|
||||||
import Crypto.Cipher.Types.Block
|
import Crypto.Cipher.Types.Block
|
||||||
|
import Crypto.Internal.ByteArray
|
||||||
|
|
||||||
-- | Append associated data into the AEAD state
|
-- | Append associated data into the AEAD state
|
||||||
aeadAppendHeader :: BlockCipher a => AEAD a -> ByteString -> AEAD a
|
aeadAppendHeader :: BlockCipher a => AEAD a -> ByteString -> AEAD a
|
||||||
@ -59,5 +59,5 @@ aeadSimpleDecrypt aeadIni header input authTag
|
|||||||
| otherwise = Nothing
|
| otherwise = Nothing
|
||||||
where aead = aeadAppendHeader aeadIni header
|
where aead = aeadAppendHeader aeadIni header
|
||||||
(output, aeadFinal) = aeadDecrypt aead input
|
(output, aeadFinal) = aeadDecrypt aead input
|
||||||
tag = aeadFinalize aeadFinal (byteableLength authTag)
|
tag = aeadFinalize aeadFinal (byteArrayLength authTag)
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user