{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.KMS.Decrypt
(
Decrypt (..),
newDecrypt,
decrypt_encryptionAlgorithm,
decrypt_encryptionContext,
decrypt_grantTokens,
decrypt_keyId,
decrypt_ciphertextBlob,
DecryptResponse (..),
newDecryptResponse,
decryptResponse_encryptionAlgorithm,
decryptResponse_keyId,
decryptResponse_plaintext,
decryptResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.KMS.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data Decrypt = Decrypt'
{
Decrypt -> Maybe EncryptionAlgorithmSpec
encryptionAlgorithm :: Prelude.Maybe EncryptionAlgorithmSpec,
Decrypt -> Maybe (HashMap Text Text)
encryptionContext :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
Decrypt -> Maybe [Text]
grantTokens :: Prelude.Maybe [Prelude.Text],
Decrypt -> Maybe Text
keyId :: Prelude.Maybe Prelude.Text,
Decrypt -> Base64
ciphertextBlob :: Data.Base64
}
deriving (Decrypt -> Decrypt -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Decrypt -> Decrypt -> Bool
$c/= :: Decrypt -> Decrypt -> Bool
== :: Decrypt -> Decrypt -> Bool
$c== :: Decrypt -> Decrypt -> Bool
Prelude.Eq, ReadPrec [Decrypt]
ReadPrec Decrypt
Int -> ReadS Decrypt
ReadS [Decrypt]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Decrypt]
$creadListPrec :: ReadPrec [Decrypt]
readPrec :: ReadPrec Decrypt
$creadPrec :: ReadPrec Decrypt
readList :: ReadS [Decrypt]
$creadList :: ReadS [Decrypt]
readsPrec :: Int -> ReadS Decrypt
$creadsPrec :: Int -> ReadS Decrypt
Prelude.Read, Int -> Decrypt -> ShowS
[Decrypt] -> ShowS
Decrypt -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Decrypt] -> ShowS
$cshowList :: [Decrypt] -> ShowS
show :: Decrypt -> String
$cshow :: Decrypt -> String
showsPrec :: Int -> Decrypt -> ShowS
$cshowsPrec :: Int -> Decrypt -> ShowS
Prelude.Show, forall x. Rep Decrypt x -> Decrypt
forall x. Decrypt -> Rep Decrypt x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep Decrypt x -> Decrypt
$cfrom :: forall x. Decrypt -> Rep Decrypt x
Prelude.Generic)
newDecrypt ::
Prelude.ByteString ->
Decrypt
newDecrypt :: ByteString -> Decrypt
newDecrypt ByteString
pCiphertextBlob_ =
Decrypt'
{ $sel:encryptionAlgorithm:Decrypt' :: Maybe EncryptionAlgorithmSpec
encryptionAlgorithm = forall a. Maybe a
Prelude.Nothing,
$sel:encryptionContext:Decrypt' :: Maybe (HashMap Text Text)
encryptionContext = forall a. Maybe a
Prelude.Nothing,
$sel:grantTokens:Decrypt' :: Maybe [Text]
grantTokens = forall a. Maybe a
Prelude.Nothing,
$sel:keyId:Decrypt' :: Maybe Text
keyId = forall a. Maybe a
Prelude.Nothing,
$sel:ciphertextBlob:Decrypt' :: Base64
ciphertextBlob =
Iso' Base64 ByteString
Data._Base64 forall t b. AReview t b -> b -> t
Lens.# ByteString
pCiphertextBlob_
}
decrypt_encryptionAlgorithm :: Lens.Lens' Decrypt (Prelude.Maybe EncryptionAlgorithmSpec)
decrypt_encryptionAlgorithm :: Lens' Decrypt (Maybe EncryptionAlgorithmSpec)
decrypt_encryptionAlgorithm = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Decrypt' {Maybe EncryptionAlgorithmSpec
encryptionAlgorithm :: Maybe EncryptionAlgorithmSpec
$sel:encryptionAlgorithm:Decrypt' :: Decrypt -> Maybe EncryptionAlgorithmSpec
encryptionAlgorithm} -> Maybe EncryptionAlgorithmSpec
encryptionAlgorithm) (\s :: Decrypt
s@Decrypt' {} Maybe EncryptionAlgorithmSpec
a -> Decrypt
s {$sel:encryptionAlgorithm:Decrypt' :: Maybe EncryptionAlgorithmSpec
encryptionAlgorithm = Maybe EncryptionAlgorithmSpec
a} :: Decrypt)
decrypt_encryptionContext :: Lens.Lens' Decrypt (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
decrypt_encryptionContext :: Lens' Decrypt (Maybe (HashMap Text Text))
decrypt_encryptionContext = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Decrypt' {Maybe (HashMap Text Text)
encryptionContext :: Maybe (HashMap Text Text)
$sel:encryptionContext:Decrypt' :: Decrypt -> Maybe (HashMap Text Text)
encryptionContext} -> Maybe (HashMap Text Text)
encryptionContext) (\s :: Decrypt
s@Decrypt' {} Maybe (HashMap Text Text)
a -> Decrypt
s {$sel:encryptionContext:Decrypt' :: Maybe (HashMap Text Text)
encryptionContext = Maybe (HashMap Text Text)
a} :: Decrypt) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
decrypt_grantTokens :: Lens.Lens' Decrypt (Prelude.Maybe [Prelude.Text])
decrypt_grantTokens :: Lens' Decrypt (Maybe [Text])
decrypt_grantTokens = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Decrypt' {Maybe [Text]
grantTokens :: Maybe [Text]
$sel:grantTokens:Decrypt' :: Decrypt -> Maybe [Text]
grantTokens} -> Maybe [Text]
grantTokens) (\s :: Decrypt
s@Decrypt' {} Maybe [Text]
a -> Decrypt
s {$sel:grantTokens:Decrypt' :: Maybe [Text]
grantTokens = Maybe [Text]
a} :: Decrypt) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
decrypt_keyId :: Lens.Lens' Decrypt (Prelude.Maybe Prelude.Text)
decrypt_keyId :: Lens' Decrypt (Maybe Text)
decrypt_keyId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Decrypt' {Maybe Text
keyId :: Maybe Text
$sel:keyId:Decrypt' :: Decrypt -> Maybe Text
keyId} -> Maybe Text
keyId) (\s :: Decrypt
s@Decrypt' {} Maybe Text
a -> Decrypt
s {$sel:keyId:Decrypt' :: Maybe Text
keyId = Maybe Text
a} :: Decrypt)
decrypt_ciphertextBlob :: Lens.Lens' Decrypt Prelude.ByteString
decrypt_ciphertextBlob :: Lens' Decrypt ByteString
decrypt_ciphertextBlob = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Decrypt' {Base64
ciphertextBlob :: Base64
$sel:ciphertextBlob:Decrypt' :: Decrypt -> Base64
ciphertextBlob} -> Base64
ciphertextBlob) (\s :: Decrypt
s@Decrypt' {} Base64
a -> Decrypt
s {$sel:ciphertextBlob:Decrypt' :: Base64
ciphertextBlob = Base64
a} :: Decrypt) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Iso' Base64 ByteString
Data._Base64
instance Core.AWSRequest Decrypt where
type AWSResponse Decrypt = DecryptResponse
request :: (Service -> Service) -> Decrypt -> Request Decrypt
request Service -> Service
overrides =
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy Decrypt
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse Decrypt)))
response =
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe EncryptionAlgorithmSpec
-> Maybe Text -> Maybe (Sensitive Base64) -> Int -> DecryptResponse
DecryptResponse'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"EncryptionAlgorithm")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"KeyId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"Plaintext")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable Decrypt where
hashWithSalt :: Int -> Decrypt -> Int
hashWithSalt Int
_salt Decrypt' {Maybe [Text]
Maybe Text
Maybe (HashMap Text Text)
Maybe EncryptionAlgorithmSpec
Base64
ciphertextBlob :: Base64
keyId :: Maybe Text
grantTokens :: Maybe [Text]
encryptionContext :: Maybe (HashMap Text Text)
encryptionAlgorithm :: Maybe EncryptionAlgorithmSpec
$sel:ciphertextBlob:Decrypt' :: Decrypt -> Base64
$sel:keyId:Decrypt' :: Decrypt -> Maybe Text
$sel:grantTokens:Decrypt' :: Decrypt -> Maybe [Text]
$sel:encryptionContext:Decrypt' :: Decrypt -> Maybe (HashMap Text Text)
$sel:encryptionAlgorithm:Decrypt' :: Decrypt -> Maybe EncryptionAlgorithmSpec
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe EncryptionAlgorithmSpec
encryptionAlgorithm
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (HashMap Text Text)
encryptionContext
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
grantTokens
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
keyId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Base64
ciphertextBlob
instance Prelude.NFData Decrypt where
rnf :: Decrypt -> ()
rnf Decrypt' {Maybe [Text]
Maybe Text
Maybe (HashMap Text Text)
Maybe EncryptionAlgorithmSpec
Base64
ciphertextBlob :: Base64
keyId :: Maybe Text
grantTokens :: Maybe [Text]
encryptionContext :: Maybe (HashMap Text Text)
encryptionAlgorithm :: Maybe EncryptionAlgorithmSpec
$sel:ciphertextBlob:Decrypt' :: Decrypt -> Base64
$sel:keyId:Decrypt' :: Decrypt -> Maybe Text
$sel:grantTokens:Decrypt' :: Decrypt -> Maybe [Text]
$sel:encryptionContext:Decrypt' :: Decrypt -> Maybe (HashMap Text Text)
$sel:encryptionAlgorithm:Decrypt' :: Decrypt -> Maybe EncryptionAlgorithmSpec
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe EncryptionAlgorithmSpec
encryptionAlgorithm
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (HashMap Text Text)
encryptionContext
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
grantTokens
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
keyId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Base64
ciphertextBlob
instance Data.ToHeaders Decrypt where
toHeaders :: Decrypt -> ResponseHeaders
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# (ByteString
"TrentService.Decrypt" :: Prelude.ByteString),
HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Data.ToJSON Decrypt where
toJSON :: Decrypt -> Value
toJSON Decrypt' {Maybe [Text]
Maybe Text
Maybe (HashMap Text Text)
Maybe EncryptionAlgorithmSpec
Base64
ciphertextBlob :: Base64
keyId :: Maybe Text
grantTokens :: Maybe [Text]
encryptionContext :: Maybe (HashMap Text Text)
encryptionAlgorithm :: Maybe EncryptionAlgorithmSpec
$sel:ciphertextBlob:Decrypt' :: Decrypt -> Base64
$sel:keyId:Decrypt' :: Decrypt -> Maybe Text
$sel:grantTokens:Decrypt' :: Decrypt -> Maybe [Text]
$sel:encryptionContext:Decrypt' :: Decrypt -> Maybe (HashMap Text Text)
$sel:encryptionAlgorithm:Decrypt' :: Decrypt -> Maybe EncryptionAlgorithmSpec
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"EncryptionAlgorithm" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EncryptionAlgorithmSpec
encryptionAlgorithm,
(Key
"EncryptionContext" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
encryptionContext,
(Key
"GrantTokens" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
grantTokens,
(Key
"KeyId" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
keyId,
forall a. a -> Maybe a
Prelude.Just
(Key
"CiphertextBlob" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Base64
ciphertextBlob)
]
)
instance Data.ToPath Decrypt where
toPath :: Decrypt -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery Decrypt where
toQuery :: Decrypt -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data DecryptResponse = DecryptResponse'
{
DecryptResponse -> Maybe EncryptionAlgorithmSpec
encryptionAlgorithm :: Prelude.Maybe EncryptionAlgorithmSpec,
DecryptResponse -> Maybe Text
keyId :: Prelude.Maybe Prelude.Text,
DecryptResponse -> Maybe (Sensitive Base64)
plaintext :: Prelude.Maybe (Data.Sensitive Data.Base64),
DecryptResponse -> Int
httpStatus :: Prelude.Int
}
deriving (DecryptResponse -> DecryptResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DecryptResponse -> DecryptResponse -> Bool
$c/= :: DecryptResponse -> DecryptResponse -> Bool
== :: DecryptResponse -> DecryptResponse -> Bool
$c== :: DecryptResponse -> DecryptResponse -> Bool
Prelude.Eq, Int -> DecryptResponse -> ShowS
[DecryptResponse] -> ShowS
DecryptResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DecryptResponse] -> ShowS
$cshowList :: [DecryptResponse] -> ShowS
show :: DecryptResponse -> String
$cshow :: DecryptResponse -> String
showsPrec :: Int -> DecryptResponse -> ShowS
$cshowsPrec :: Int -> DecryptResponse -> ShowS
Prelude.Show, forall x. Rep DecryptResponse x -> DecryptResponse
forall x. DecryptResponse -> Rep DecryptResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DecryptResponse x -> DecryptResponse
$cfrom :: forall x. DecryptResponse -> Rep DecryptResponse x
Prelude.Generic)
newDecryptResponse ::
Prelude.Int ->
DecryptResponse
newDecryptResponse :: Int -> DecryptResponse
newDecryptResponse Int
pHttpStatus_ =
DecryptResponse'
{ $sel:encryptionAlgorithm:DecryptResponse' :: Maybe EncryptionAlgorithmSpec
encryptionAlgorithm =
forall a. Maybe a
Prelude.Nothing,
$sel:keyId:DecryptResponse' :: Maybe Text
keyId = forall a. Maybe a
Prelude.Nothing,
$sel:plaintext:DecryptResponse' :: Maybe (Sensitive Base64)
plaintext = forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:DecryptResponse' :: Int
httpStatus = Int
pHttpStatus_
}
decryptResponse_encryptionAlgorithm :: Lens.Lens' DecryptResponse (Prelude.Maybe EncryptionAlgorithmSpec)
decryptResponse_encryptionAlgorithm :: Lens' DecryptResponse (Maybe EncryptionAlgorithmSpec)
decryptResponse_encryptionAlgorithm = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DecryptResponse' {Maybe EncryptionAlgorithmSpec
encryptionAlgorithm :: Maybe EncryptionAlgorithmSpec
$sel:encryptionAlgorithm:DecryptResponse' :: DecryptResponse -> Maybe EncryptionAlgorithmSpec
encryptionAlgorithm} -> Maybe EncryptionAlgorithmSpec
encryptionAlgorithm) (\s :: DecryptResponse
s@DecryptResponse' {} Maybe EncryptionAlgorithmSpec
a -> DecryptResponse
s {$sel:encryptionAlgorithm:DecryptResponse' :: Maybe EncryptionAlgorithmSpec
encryptionAlgorithm = Maybe EncryptionAlgorithmSpec
a} :: DecryptResponse)
decryptResponse_keyId :: Lens.Lens' DecryptResponse (Prelude.Maybe Prelude.Text)
decryptResponse_keyId :: Lens' DecryptResponse (Maybe Text)
decryptResponse_keyId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DecryptResponse' {Maybe Text
keyId :: Maybe Text
$sel:keyId:DecryptResponse' :: DecryptResponse -> Maybe Text
keyId} -> Maybe Text
keyId) (\s :: DecryptResponse
s@DecryptResponse' {} Maybe Text
a -> DecryptResponse
s {$sel:keyId:DecryptResponse' :: Maybe Text
keyId = Maybe Text
a} :: DecryptResponse)
decryptResponse_plaintext :: Lens.Lens' DecryptResponse (Prelude.Maybe Prelude.ByteString)
decryptResponse_plaintext :: Lens' DecryptResponse (Maybe ByteString)
decryptResponse_plaintext = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DecryptResponse' {Maybe (Sensitive Base64)
plaintext :: Maybe (Sensitive Base64)
$sel:plaintext:DecryptResponse' :: DecryptResponse -> Maybe (Sensitive Base64)
plaintext} -> Maybe (Sensitive Base64)
plaintext) (\s :: DecryptResponse
s@DecryptResponse' {} Maybe (Sensitive Base64)
a -> DecryptResponse
s {$sel:plaintext:DecryptResponse' :: Maybe (Sensitive Base64)
plaintext = Maybe (Sensitive Base64)
a} :: DecryptResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping (forall a. Iso' (Sensitive a) a
Data._Sensitive forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Iso' Base64 ByteString
Data._Base64)
decryptResponse_httpStatus :: Lens.Lens' DecryptResponse Prelude.Int
decryptResponse_httpStatus :: Lens' DecryptResponse Int
decryptResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DecryptResponse' {Int
httpStatus :: Int
$sel:httpStatus:DecryptResponse' :: DecryptResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DecryptResponse
s@DecryptResponse' {} Int
a -> DecryptResponse
s {$sel:httpStatus:DecryptResponse' :: Int
httpStatus = Int
a} :: DecryptResponse)
instance Prelude.NFData DecryptResponse where
rnf :: DecryptResponse -> ()
rnf DecryptResponse' {Int
Maybe Text
Maybe (Sensitive Base64)
Maybe EncryptionAlgorithmSpec
httpStatus :: Int
plaintext :: Maybe (Sensitive Base64)
keyId :: Maybe Text
encryptionAlgorithm :: Maybe EncryptionAlgorithmSpec
$sel:httpStatus:DecryptResponse' :: DecryptResponse -> Int
$sel:plaintext:DecryptResponse' :: DecryptResponse -> Maybe (Sensitive Base64)
$sel:keyId:DecryptResponse' :: DecryptResponse -> Maybe Text
$sel:encryptionAlgorithm:DecryptResponse' :: DecryptResponse -> Maybe EncryptionAlgorithmSpec
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe EncryptionAlgorithmSpec
encryptionAlgorithm
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
keyId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (Sensitive Base64)
plaintext
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus