{-# 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 #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.StorageGateway.DescribeSMBSettings
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Gets a description of a Server Message Block (SMB) file share settings
-- from a file gateway. This operation is only supported for file gateways.
module Amazonka.StorageGateway.DescribeSMBSettings
  ( -- * Creating a Request
    DescribeSMBSettings (..),
    newDescribeSMBSettings,

    -- * Request Lenses
    describeSMBSettings_gatewayARN,

    -- * Destructuring the Response
    DescribeSMBSettingsResponse (..),
    newDescribeSMBSettingsResponse,

    -- * Response Lenses
    describeSMBSettingsResponse_activeDirectoryStatus,
    describeSMBSettingsResponse_domainName,
    describeSMBSettingsResponse_fileSharesVisible,
    describeSMBSettingsResponse_gatewayARN,
    describeSMBSettingsResponse_sMBGuestPasswordSet,
    describeSMBSettingsResponse_sMBLocalGroups,
    describeSMBSettingsResponse_sMBSecurityStrategy,
    describeSMBSettingsResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.StorageGateway.Types

-- | /See:/ 'newDescribeSMBSettings' smart constructor.
data DescribeSMBSettings = DescribeSMBSettings'
  { DescribeSMBSettings -> Text
gatewayARN :: Prelude.Text
  }
  deriving (DescribeSMBSettings -> DescribeSMBSettings -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeSMBSettings -> DescribeSMBSettings -> Bool
$c/= :: DescribeSMBSettings -> DescribeSMBSettings -> Bool
== :: DescribeSMBSettings -> DescribeSMBSettings -> Bool
$c== :: DescribeSMBSettings -> DescribeSMBSettings -> Bool
Prelude.Eq, ReadPrec [DescribeSMBSettings]
ReadPrec DescribeSMBSettings
Int -> ReadS DescribeSMBSettings
ReadS [DescribeSMBSettings]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeSMBSettings]
$creadListPrec :: ReadPrec [DescribeSMBSettings]
readPrec :: ReadPrec DescribeSMBSettings
$creadPrec :: ReadPrec DescribeSMBSettings
readList :: ReadS [DescribeSMBSettings]
$creadList :: ReadS [DescribeSMBSettings]
readsPrec :: Int -> ReadS DescribeSMBSettings
$creadsPrec :: Int -> ReadS DescribeSMBSettings
Prelude.Read, Int -> DescribeSMBSettings -> ShowS
[DescribeSMBSettings] -> ShowS
DescribeSMBSettings -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeSMBSettings] -> ShowS
$cshowList :: [DescribeSMBSettings] -> ShowS
show :: DescribeSMBSettings -> String
$cshow :: DescribeSMBSettings -> String
showsPrec :: Int -> DescribeSMBSettings -> ShowS
$cshowsPrec :: Int -> DescribeSMBSettings -> ShowS
Prelude.Show, forall x. Rep DescribeSMBSettings x -> DescribeSMBSettings
forall x. DescribeSMBSettings -> Rep DescribeSMBSettings x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DescribeSMBSettings x -> DescribeSMBSettings
$cfrom :: forall x. DescribeSMBSettings -> Rep DescribeSMBSettings x
Prelude.Generic)

-- |
-- Create a value of 'DescribeSMBSettings' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'gatewayARN', 'describeSMBSettings_gatewayARN' - Undocumented member.
newDescribeSMBSettings ::
  -- | 'gatewayARN'
  Prelude.Text ->
  DescribeSMBSettings
newDescribeSMBSettings :: Text -> DescribeSMBSettings
newDescribeSMBSettings Text
pGatewayARN_ =
  DescribeSMBSettings' {$sel:gatewayARN:DescribeSMBSettings' :: Text
gatewayARN = Text
pGatewayARN_}

-- | Undocumented member.
describeSMBSettings_gatewayARN :: Lens.Lens' DescribeSMBSettings Prelude.Text
describeSMBSettings_gatewayARN :: Lens' DescribeSMBSettings Text
describeSMBSettings_gatewayARN = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettings' {Text
gatewayARN :: Text
$sel:gatewayARN:DescribeSMBSettings' :: DescribeSMBSettings -> Text
gatewayARN} -> Text
gatewayARN) (\s :: DescribeSMBSettings
s@DescribeSMBSettings' {} Text
a -> DescribeSMBSettings
s {$sel:gatewayARN:DescribeSMBSettings' :: Text
gatewayARN = Text
a} :: DescribeSMBSettings)

instance Core.AWSRequest DescribeSMBSettings where
  type
    AWSResponse DescribeSMBSettings =
      DescribeSMBSettingsResponse
  request :: (Service -> Service)
-> DescribeSMBSettings -> Request DescribeSMBSettings
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 DescribeSMBSettings
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse DescribeSMBSettings)))
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 ActiveDirectoryStatus
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Maybe SMBLocalGroups
-> Maybe SMBSecurityStrategy
-> Int
-> DescribeSMBSettingsResponse
DescribeSMBSettingsResponse'
            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
"ActiveDirectoryStatus")
            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
"DomainName")
            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
"FileSharesVisible")
            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
"GatewayARN")
            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
"SMBGuestPasswordSet")
            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
"SMBLocalGroups")
            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
"SMBSecurityStrategy")
            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 DescribeSMBSettings where
  hashWithSalt :: Int -> DescribeSMBSettings -> Int
hashWithSalt Int
_salt DescribeSMBSettings' {Text
gatewayARN :: Text
$sel:gatewayARN:DescribeSMBSettings' :: DescribeSMBSettings -> Text
..} =
    Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
gatewayARN

instance Prelude.NFData DescribeSMBSettings where
  rnf :: DescribeSMBSettings -> ()
rnf DescribeSMBSettings' {Text
gatewayARN :: Text
$sel:gatewayARN:DescribeSMBSettings' :: DescribeSMBSettings -> Text
..} = forall a. NFData a => a -> ()
Prelude.rnf Text
gatewayARN

instance Data.ToHeaders DescribeSMBSettings where
  toHeaders :: DescribeSMBSettings -> 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
"StorageGateway_20130630.DescribeSMBSettings" ::
                          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 DescribeSMBSettings where
  toJSON :: DescribeSMBSettings -> Value
toJSON DescribeSMBSettings' {Text
gatewayARN :: Text
$sel:gatewayARN:DescribeSMBSettings' :: DescribeSMBSettings -> Text
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [forall a. a -> Maybe a
Prelude.Just (Key
"GatewayARN" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
gatewayARN)]
      )

instance Data.ToPath DescribeSMBSettings where
  toPath :: DescribeSMBSettings -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"

instance Data.ToQuery DescribeSMBSettings where
  toQuery :: DescribeSMBSettings -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newDescribeSMBSettingsResponse' smart constructor.
data DescribeSMBSettingsResponse = DescribeSMBSettingsResponse'
  { -- | Indicates the status of a gateway that is a member of the Active
    -- Directory domain.
    --
    -- -   @ACCESS_DENIED@: Indicates that the @JoinDomain@ operation failed
    --     due to an authentication error.
    --
    -- -   @DETACHED@: Indicates that gateway is not joined to a domain.
    --
    -- -   @JOINED@: Indicates that the gateway has successfully joined a
    --     domain.
    --
    -- -   @JOINING@: Indicates that a @JoinDomain@ operation is in progress.
    --
    -- -   @NETWORK_ERROR@: Indicates that @JoinDomain@ operation failed due to
    --     a network or connectivity error.
    --
    -- -   @TIMEOUT@: Indicates that the @JoinDomain@ operation failed because
    --     the operation didn\'t complete within the allotted time.
    --
    -- -   @UNKNOWN_ERROR@: Indicates that the @JoinDomain@ operation failed
    --     due to another type of error.
    DescribeSMBSettingsResponse -> Maybe ActiveDirectoryStatus
activeDirectoryStatus :: Prelude.Maybe ActiveDirectoryStatus,
    -- | The name of the domain that the gateway is joined to.
    DescribeSMBSettingsResponse -> Maybe Text
domainName :: Prelude.Maybe Prelude.Text,
    -- | The shares on this gateway appear when listing shares. Only supported
    -- for S3 File Gateways.
    DescribeSMBSettingsResponse -> Maybe Bool
fileSharesVisible :: Prelude.Maybe Prelude.Bool,
    DescribeSMBSettingsResponse -> Maybe Text
gatewayARN :: Prelude.Maybe Prelude.Text,
    -- | This value is @true@ if a password for the guest user @smbguest@ is set,
    -- otherwise @false@. Only supported for S3 File Gateways.
    --
    -- Valid Values: @true@ | @false@
    DescribeSMBSettingsResponse -> Maybe Bool
sMBGuestPasswordSet :: Prelude.Maybe Prelude.Bool,
    -- | A list of Active Directory users and groups that have special
    -- permissions for SMB file shares on the gateway.
    DescribeSMBSettingsResponse -> Maybe SMBLocalGroups
sMBLocalGroups :: Prelude.Maybe SMBLocalGroups,
    -- | The type of security strategy that was specified for file gateway.
    --
    -- -   @ClientSpecified@: If you use this option, requests are established
    --     based on what is negotiated by the client. This option is
    --     recommended when you want to maximize compatibility across different
    --     clients in your environment. Only supported for S3 File Gateways.
    --
    -- -   @MandatorySigning@: If you use this option, file gateway only allows
    --     connections from SMBv2 or SMBv3 clients that have signing enabled.
    --     This option works with SMB clients on Microsoft Windows Vista,
    --     Windows Server 2008 or newer.
    --
    -- -   @MandatoryEncryption@: If you use this option, file gateway only
    --     allows connections from SMBv3 clients that have encryption enabled.
    --     This option is highly recommended for environments that handle
    --     sensitive data. This option works with SMB clients on Microsoft
    --     Windows 8, Windows Server 2012 or newer.
    DescribeSMBSettingsResponse -> Maybe SMBSecurityStrategy
sMBSecurityStrategy :: Prelude.Maybe SMBSecurityStrategy,
    -- | The response's http status code.
    DescribeSMBSettingsResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (DescribeSMBSettingsResponse -> DescribeSMBSettingsResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeSMBSettingsResponse -> DescribeSMBSettingsResponse -> Bool
$c/= :: DescribeSMBSettingsResponse -> DescribeSMBSettingsResponse -> Bool
== :: DescribeSMBSettingsResponse -> DescribeSMBSettingsResponse -> Bool
$c== :: DescribeSMBSettingsResponse -> DescribeSMBSettingsResponse -> Bool
Prelude.Eq, ReadPrec [DescribeSMBSettingsResponse]
ReadPrec DescribeSMBSettingsResponse
Int -> ReadS DescribeSMBSettingsResponse
ReadS [DescribeSMBSettingsResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeSMBSettingsResponse]
$creadListPrec :: ReadPrec [DescribeSMBSettingsResponse]
readPrec :: ReadPrec DescribeSMBSettingsResponse
$creadPrec :: ReadPrec DescribeSMBSettingsResponse
readList :: ReadS [DescribeSMBSettingsResponse]
$creadList :: ReadS [DescribeSMBSettingsResponse]
readsPrec :: Int -> ReadS DescribeSMBSettingsResponse
$creadsPrec :: Int -> ReadS DescribeSMBSettingsResponse
Prelude.Read, Int -> DescribeSMBSettingsResponse -> ShowS
[DescribeSMBSettingsResponse] -> ShowS
DescribeSMBSettingsResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeSMBSettingsResponse] -> ShowS
$cshowList :: [DescribeSMBSettingsResponse] -> ShowS
show :: DescribeSMBSettingsResponse -> String
$cshow :: DescribeSMBSettingsResponse -> String
showsPrec :: Int -> DescribeSMBSettingsResponse -> ShowS
$cshowsPrec :: Int -> DescribeSMBSettingsResponse -> ShowS
Prelude.Show, forall x.
Rep DescribeSMBSettingsResponse x -> DescribeSMBSettingsResponse
forall x.
DescribeSMBSettingsResponse -> Rep DescribeSMBSettingsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeSMBSettingsResponse x -> DescribeSMBSettingsResponse
$cfrom :: forall x.
DescribeSMBSettingsResponse -> Rep DescribeSMBSettingsResponse x
Prelude.Generic)

-- |
-- Create a value of 'DescribeSMBSettingsResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'activeDirectoryStatus', 'describeSMBSettingsResponse_activeDirectoryStatus' - Indicates the status of a gateway that is a member of the Active
-- Directory domain.
--
-- -   @ACCESS_DENIED@: Indicates that the @JoinDomain@ operation failed
--     due to an authentication error.
--
-- -   @DETACHED@: Indicates that gateway is not joined to a domain.
--
-- -   @JOINED@: Indicates that the gateway has successfully joined a
--     domain.
--
-- -   @JOINING@: Indicates that a @JoinDomain@ operation is in progress.
--
-- -   @NETWORK_ERROR@: Indicates that @JoinDomain@ operation failed due to
--     a network or connectivity error.
--
-- -   @TIMEOUT@: Indicates that the @JoinDomain@ operation failed because
--     the operation didn\'t complete within the allotted time.
--
-- -   @UNKNOWN_ERROR@: Indicates that the @JoinDomain@ operation failed
--     due to another type of error.
--
-- 'domainName', 'describeSMBSettingsResponse_domainName' - The name of the domain that the gateway is joined to.
--
-- 'fileSharesVisible', 'describeSMBSettingsResponse_fileSharesVisible' - The shares on this gateway appear when listing shares. Only supported
-- for S3 File Gateways.
--
-- 'gatewayARN', 'describeSMBSettingsResponse_gatewayARN' - Undocumented member.
--
-- 'sMBGuestPasswordSet', 'describeSMBSettingsResponse_sMBGuestPasswordSet' - This value is @true@ if a password for the guest user @smbguest@ is set,
-- otherwise @false@. Only supported for S3 File Gateways.
--
-- Valid Values: @true@ | @false@
--
-- 'sMBLocalGroups', 'describeSMBSettingsResponse_sMBLocalGroups' - A list of Active Directory users and groups that have special
-- permissions for SMB file shares on the gateway.
--
-- 'sMBSecurityStrategy', 'describeSMBSettingsResponse_sMBSecurityStrategy' - The type of security strategy that was specified for file gateway.
--
-- -   @ClientSpecified@: If you use this option, requests are established
--     based on what is negotiated by the client. This option is
--     recommended when you want to maximize compatibility across different
--     clients in your environment. Only supported for S3 File Gateways.
--
-- -   @MandatorySigning@: If you use this option, file gateway only allows
--     connections from SMBv2 or SMBv3 clients that have signing enabled.
--     This option works with SMB clients on Microsoft Windows Vista,
--     Windows Server 2008 or newer.
--
-- -   @MandatoryEncryption@: If you use this option, file gateway only
--     allows connections from SMBv3 clients that have encryption enabled.
--     This option is highly recommended for environments that handle
--     sensitive data. This option works with SMB clients on Microsoft
--     Windows 8, Windows Server 2012 or newer.
--
-- 'httpStatus', 'describeSMBSettingsResponse_httpStatus' - The response's http status code.
newDescribeSMBSettingsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  DescribeSMBSettingsResponse
newDescribeSMBSettingsResponse :: Int -> DescribeSMBSettingsResponse
newDescribeSMBSettingsResponse Int
pHttpStatus_ =
  DescribeSMBSettingsResponse'
    { $sel:activeDirectoryStatus:DescribeSMBSettingsResponse' :: Maybe ActiveDirectoryStatus
activeDirectoryStatus =
        forall a. Maybe a
Prelude.Nothing,
      $sel:domainName:DescribeSMBSettingsResponse' :: Maybe Text
domainName = forall a. Maybe a
Prelude.Nothing,
      $sel:fileSharesVisible:DescribeSMBSettingsResponse' :: Maybe Bool
fileSharesVisible = forall a. Maybe a
Prelude.Nothing,
      $sel:gatewayARN:DescribeSMBSettingsResponse' :: Maybe Text
gatewayARN = forall a. Maybe a
Prelude.Nothing,
      $sel:sMBGuestPasswordSet:DescribeSMBSettingsResponse' :: Maybe Bool
sMBGuestPasswordSet = forall a. Maybe a
Prelude.Nothing,
      $sel:sMBLocalGroups:DescribeSMBSettingsResponse' :: Maybe SMBLocalGroups
sMBLocalGroups = forall a. Maybe a
Prelude.Nothing,
      $sel:sMBSecurityStrategy:DescribeSMBSettingsResponse' :: Maybe SMBSecurityStrategy
sMBSecurityStrategy = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:DescribeSMBSettingsResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | Indicates the status of a gateway that is a member of the Active
-- Directory domain.
--
-- -   @ACCESS_DENIED@: Indicates that the @JoinDomain@ operation failed
--     due to an authentication error.
--
-- -   @DETACHED@: Indicates that gateway is not joined to a domain.
--
-- -   @JOINED@: Indicates that the gateway has successfully joined a
--     domain.
--
-- -   @JOINING@: Indicates that a @JoinDomain@ operation is in progress.
--
-- -   @NETWORK_ERROR@: Indicates that @JoinDomain@ operation failed due to
--     a network or connectivity error.
--
-- -   @TIMEOUT@: Indicates that the @JoinDomain@ operation failed because
--     the operation didn\'t complete within the allotted time.
--
-- -   @UNKNOWN_ERROR@: Indicates that the @JoinDomain@ operation failed
--     due to another type of error.
describeSMBSettingsResponse_activeDirectoryStatus :: Lens.Lens' DescribeSMBSettingsResponse (Prelude.Maybe ActiveDirectoryStatus)
describeSMBSettingsResponse_activeDirectoryStatus :: Lens' DescribeSMBSettingsResponse (Maybe ActiveDirectoryStatus)
describeSMBSettingsResponse_activeDirectoryStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettingsResponse' {Maybe ActiveDirectoryStatus
activeDirectoryStatus :: Maybe ActiveDirectoryStatus
$sel:activeDirectoryStatus:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe ActiveDirectoryStatus
activeDirectoryStatus} -> Maybe ActiveDirectoryStatus
activeDirectoryStatus) (\s :: DescribeSMBSettingsResponse
s@DescribeSMBSettingsResponse' {} Maybe ActiveDirectoryStatus
a -> DescribeSMBSettingsResponse
s {$sel:activeDirectoryStatus:DescribeSMBSettingsResponse' :: Maybe ActiveDirectoryStatus
activeDirectoryStatus = Maybe ActiveDirectoryStatus
a} :: DescribeSMBSettingsResponse)

-- | The name of the domain that the gateway is joined to.
describeSMBSettingsResponse_domainName :: Lens.Lens' DescribeSMBSettingsResponse (Prelude.Maybe Prelude.Text)
describeSMBSettingsResponse_domainName :: Lens' DescribeSMBSettingsResponse (Maybe Text)
describeSMBSettingsResponse_domainName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettingsResponse' {Maybe Text
domainName :: Maybe Text
$sel:domainName:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe Text
domainName} -> Maybe Text
domainName) (\s :: DescribeSMBSettingsResponse
s@DescribeSMBSettingsResponse' {} Maybe Text
a -> DescribeSMBSettingsResponse
s {$sel:domainName:DescribeSMBSettingsResponse' :: Maybe Text
domainName = Maybe Text
a} :: DescribeSMBSettingsResponse)

-- | The shares on this gateway appear when listing shares. Only supported
-- for S3 File Gateways.
describeSMBSettingsResponse_fileSharesVisible :: Lens.Lens' DescribeSMBSettingsResponse (Prelude.Maybe Prelude.Bool)
describeSMBSettingsResponse_fileSharesVisible :: Lens' DescribeSMBSettingsResponse (Maybe Bool)
describeSMBSettingsResponse_fileSharesVisible = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettingsResponse' {Maybe Bool
fileSharesVisible :: Maybe Bool
$sel:fileSharesVisible:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe Bool
fileSharesVisible} -> Maybe Bool
fileSharesVisible) (\s :: DescribeSMBSettingsResponse
s@DescribeSMBSettingsResponse' {} Maybe Bool
a -> DescribeSMBSettingsResponse
s {$sel:fileSharesVisible:DescribeSMBSettingsResponse' :: Maybe Bool
fileSharesVisible = Maybe Bool
a} :: DescribeSMBSettingsResponse)

-- | Undocumented member.
describeSMBSettingsResponse_gatewayARN :: Lens.Lens' DescribeSMBSettingsResponse (Prelude.Maybe Prelude.Text)
describeSMBSettingsResponse_gatewayARN :: Lens' DescribeSMBSettingsResponse (Maybe Text)
describeSMBSettingsResponse_gatewayARN = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettingsResponse' {Maybe Text
gatewayARN :: Maybe Text
$sel:gatewayARN:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe Text
gatewayARN} -> Maybe Text
gatewayARN) (\s :: DescribeSMBSettingsResponse
s@DescribeSMBSettingsResponse' {} Maybe Text
a -> DescribeSMBSettingsResponse
s {$sel:gatewayARN:DescribeSMBSettingsResponse' :: Maybe Text
gatewayARN = Maybe Text
a} :: DescribeSMBSettingsResponse)

-- | This value is @true@ if a password for the guest user @smbguest@ is set,
-- otherwise @false@. Only supported for S3 File Gateways.
--
-- Valid Values: @true@ | @false@
describeSMBSettingsResponse_sMBGuestPasswordSet :: Lens.Lens' DescribeSMBSettingsResponse (Prelude.Maybe Prelude.Bool)
describeSMBSettingsResponse_sMBGuestPasswordSet :: Lens' DescribeSMBSettingsResponse (Maybe Bool)
describeSMBSettingsResponse_sMBGuestPasswordSet = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettingsResponse' {Maybe Bool
sMBGuestPasswordSet :: Maybe Bool
$sel:sMBGuestPasswordSet:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe Bool
sMBGuestPasswordSet} -> Maybe Bool
sMBGuestPasswordSet) (\s :: DescribeSMBSettingsResponse
s@DescribeSMBSettingsResponse' {} Maybe Bool
a -> DescribeSMBSettingsResponse
s {$sel:sMBGuestPasswordSet:DescribeSMBSettingsResponse' :: Maybe Bool
sMBGuestPasswordSet = Maybe Bool
a} :: DescribeSMBSettingsResponse)

-- | A list of Active Directory users and groups that have special
-- permissions for SMB file shares on the gateway.
describeSMBSettingsResponse_sMBLocalGroups :: Lens.Lens' DescribeSMBSettingsResponse (Prelude.Maybe SMBLocalGroups)
describeSMBSettingsResponse_sMBLocalGroups :: Lens' DescribeSMBSettingsResponse (Maybe SMBLocalGroups)
describeSMBSettingsResponse_sMBLocalGroups = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettingsResponse' {Maybe SMBLocalGroups
sMBLocalGroups :: Maybe SMBLocalGroups
$sel:sMBLocalGroups:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe SMBLocalGroups
sMBLocalGroups} -> Maybe SMBLocalGroups
sMBLocalGroups) (\s :: DescribeSMBSettingsResponse
s@DescribeSMBSettingsResponse' {} Maybe SMBLocalGroups
a -> DescribeSMBSettingsResponse
s {$sel:sMBLocalGroups:DescribeSMBSettingsResponse' :: Maybe SMBLocalGroups
sMBLocalGroups = Maybe SMBLocalGroups
a} :: DescribeSMBSettingsResponse)

-- | The type of security strategy that was specified for file gateway.
--
-- -   @ClientSpecified@: If you use this option, requests are established
--     based on what is negotiated by the client. This option is
--     recommended when you want to maximize compatibility across different
--     clients in your environment. Only supported for S3 File Gateways.
--
-- -   @MandatorySigning@: If you use this option, file gateway only allows
--     connections from SMBv2 or SMBv3 clients that have signing enabled.
--     This option works with SMB clients on Microsoft Windows Vista,
--     Windows Server 2008 or newer.
--
-- -   @MandatoryEncryption@: If you use this option, file gateway only
--     allows connections from SMBv3 clients that have encryption enabled.
--     This option is highly recommended for environments that handle
--     sensitive data. This option works with SMB clients on Microsoft
--     Windows 8, Windows Server 2012 or newer.
describeSMBSettingsResponse_sMBSecurityStrategy :: Lens.Lens' DescribeSMBSettingsResponse (Prelude.Maybe SMBSecurityStrategy)
describeSMBSettingsResponse_sMBSecurityStrategy :: Lens' DescribeSMBSettingsResponse (Maybe SMBSecurityStrategy)
describeSMBSettingsResponse_sMBSecurityStrategy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettingsResponse' {Maybe SMBSecurityStrategy
sMBSecurityStrategy :: Maybe SMBSecurityStrategy
$sel:sMBSecurityStrategy:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe SMBSecurityStrategy
sMBSecurityStrategy} -> Maybe SMBSecurityStrategy
sMBSecurityStrategy) (\s :: DescribeSMBSettingsResponse
s@DescribeSMBSettingsResponse' {} Maybe SMBSecurityStrategy
a -> DescribeSMBSettingsResponse
s {$sel:sMBSecurityStrategy:DescribeSMBSettingsResponse' :: Maybe SMBSecurityStrategy
sMBSecurityStrategy = Maybe SMBSecurityStrategy
a} :: DescribeSMBSettingsResponse)

-- | The response's http status code.
describeSMBSettingsResponse_httpStatus :: Lens.Lens' DescribeSMBSettingsResponse Prelude.Int
describeSMBSettingsResponse_httpStatus :: Lens' DescribeSMBSettingsResponse Int
describeSMBSettingsResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeSMBSettingsResponse' {Int
httpStatus :: Int
$sel:httpStatus:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DescribeSMBSettingsResponse
s@DescribeSMBSettingsResponse' {} Int
a -> DescribeSMBSettingsResponse
s {$sel:httpStatus:DescribeSMBSettingsResponse' :: Int
httpStatus = Int
a} :: DescribeSMBSettingsResponse)

instance Prelude.NFData DescribeSMBSettingsResponse where
  rnf :: DescribeSMBSettingsResponse -> ()
rnf DescribeSMBSettingsResponse' {Int
Maybe Bool
Maybe Text
Maybe ActiveDirectoryStatus
Maybe SMBLocalGroups
Maybe SMBSecurityStrategy
httpStatus :: Int
sMBSecurityStrategy :: Maybe SMBSecurityStrategy
sMBLocalGroups :: Maybe SMBLocalGroups
sMBGuestPasswordSet :: Maybe Bool
gatewayARN :: Maybe Text
fileSharesVisible :: Maybe Bool
domainName :: Maybe Text
activeDirectoryStatus :: Maybe ActiveDirectoryStatus
$sel:httpStatus:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Int
$sel:sMBSecurityStrategy:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe SMBSecurityStrategy
$sel:sMBLocalGroups:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe SMBLocalGroups
$sel:sMBGuestPasswordSet:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe Bool
$sel:gatewayARN:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe Text
$sel:fileSharesVisible:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe Bool
$sel:domainName:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe Text
$sel:activeDirectoryStatus:DescribeSMBSettingsResponse' :: DescribeSMBSettingsResponse -> Maybe ActiveDirectoryStatus
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe ActiveDirectoryStatus
activeDirectoryStatus
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
domainName
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
fileSharesVisible
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
gatewayARN
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
sMBGuestPasswordSet
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SMBLocalGroups
sMBLocalGroups
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SMBSecurityStrategy
sMBSecurityStrategy
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus