{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

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

-- |
-- Module      : Amazonka.SecurityHub.Types.AwsSecurityFinding
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.SecurityHub.Types.AwsSecurityFinding where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SecurityHub.Types.Action
import Amazonka.SecurityHub.Types.Compliance
import Amazonka.SecurityHub.Types.FindingProviderFields
import Amazonka.SecurityHub.Types.Malware
import Amazonka.SecurityHub.Types.Network
import Amazonka.SecurityHub.Types.NetworkPathComponent
import Amazonka.SecurityHub.Types.Note
import Amazonka.SecurityHub.Types.PatchSummary
import Amazonka.SecurityHub.Types.ProcessDetails
import Amazonka.SecurityHub.Types.RecordState
import Amazonka.SecurityHub.Types.RelatedFinding
import Amazonka.SecurityHub.Types.Remediation
import Amazonka.SecurityHub.Types.Resource
import Amazonka.SecurityHub.Types.Severity
import Amazonka.SecurityHub.Types.ThreatIntelIndicator
import Amazonka.SecurityHub.Types.VerificationState
import Amazonka.SecurityHub.Types.Vulnerability
import Amazonka.SecurityHub.Types.Workflow
import Amazonka.SecurityHub.Types.WorkflowState

-- | Provides consistent format for the contents of the Security
-- Hub-aggregated findings. @AwsSecurityFinding@ format enables you to
-- share findings between Amazon Web Services security services and
-- third-party solutions, and security standards checks.
--
-- A finding is a potential security issue generated either by Amazon Web
-- Services services or by the integrated third-party solutions and
-- standards checks.
--
-- /See:/ 'newAwsSecurityFinding' smart constructor.
data AwsSecurityFinding = AwsSecurityFinding'
  { -- | The name of the product that generated the finding.
    --
    -- Security Hub populates this attribute automatically for each finding.
    -- You cannot update it using @BatchImportFindings@ or
    -- @BatchUpdateFindings@. The exception to this is when you use a custom
    -- integration.
    --
    -- When you use the Security Hub console to filter findings by product
    -- name, you use this attribute.
    --
    -- When you use the Security Hub API to filter findings by product name,
    -- you use the @aws\/securityhub\/ProductName@ attribute under
    -- @ProductFields@.
    --
    -- Security Hub does not synchronize those two attributes.
    AwsSecurityFinding -> Maybe Text
productName :: Prelude.Maybe Prelude.Text,
    -- | The workflow state of a finding.
    AwsSecurityFinding -> Maybe WorkflowState
workflowState :: Prelude.Maybe WorkflowState,
    -- | The level of importance assigned to the resources associated with the
    -- finding.
    --
    -- A score of 0 means that the underlying resources have no criticality,
    -- and a score of 100 is reserved for the most critical resources.
    AwsSecurityFinding -> Maybe Int
criticality :: Prelude.Maybe Prelude.Int,
    -- | The record state of a finding.
    AwsSecurityFinding -> Maybe RecordState
recordState :: Prelude.Maybe RecordState,
    -- | A data type where security-findings providers can include additional
    -- solution-specific details that aren\'t part of the defined
    -- @AwsSecurityFinding@ format.
    --
    -- Can contain up to 50 key-value pairs. For each key-value pair, the key
    -- can contain up to 128 characters, and the value can contain up to 2048
    -- characters.
    AwsSecurityFinding -> Maybe (HashMap Text Text)
productFields :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | This data type is exclusive to findings that are generated as the result
    -- of a check run against a specific rule in a supported security standard,
    -- such as CIS Amazon Web Services Foundations. Contains security
    -- standard-related finding details.
    AwsSecurityFinding -> Maybe Compliance
compliance :: Prelude.Maybe Compliance,
    -- | In a @BatchImportFindings@ request, finding providers use
    -- @FindingProviderFields@ to provide and update their own values for
    -- confidence, criticality, related findings, severity, and types.
    AwsSecurityFinding -> Maybe FindingProviderFields
findingProviderFields :: Prelude.Maybe FindingProviderFields,
    -- | The name of the company for the product that generated the finding.
    --
    -- Security Hub populates this attribute automatically for each finding.
    -- You cannot be updated using @BatchImportFindings@ or
    -- @BatchUpdateFindings@. The exception to this is when you use a custom
    -- integration.
    --
    -- When you use the Security Hub console to filter findings by company
    -- name, you use this attribute.
    --
    -- When you use the Security Hub API to filter findings by company name,
    -- you use the @aws\/securityhub\/CompanyName@ attribute under
    -- @ProductFields@.
    --
    -- Security Hub does not synchronize those two attributes.
    AwsSecurityFinding -> Maybe Text
companyName :: Prelude.Maybe Prelude.Text,
    -- | A user-defined note added to a finding.
    AwsSecurityFinding -> Maybe Note
note :: Prelude.Maybe Note,
    -- | The details of process-related information about a finding.
    AwsSecurityFinding -> Maybe ProcessDetails
process :: Prelude.Maybe ProcessDetails,
    -- | A finding\'s severity.
    AwsSecurityFinding -> Maybe Severity
severity :: Prelude.Maybe Severity,
    -- | One or more finding types in the format of
    -- @namespace\/category\/classifier@ that classify a finding.
    --
    -- Valid namespace values are: Software and Configuration Checks | TTPs |
    -- Effects | Unusual Behaviors | Sensitive Data Identifications
    AwsSecurityFinding -> Maybe [Text]
types :: Prelude.Maybe [Prelude.Text],
    -- | Provides details about an action that affects or that was taken on a
    -- resource.
    AwsSecurityFinding -> Maybe Action
action :: Prelude.Maybe Action,
    -- | The details of network-related information about a finding.
    AwsSecurityFinding -> Maybe Network
network :: Prelude.Maybe Network,
    -- | A list of related findings.
    AwsSecurityFinding -> Maybe [RelatedFinding]
relatedFindings :: Prelude.Maybe [RelatedFinding],
    -- | Indicates when the security-findings provider first observed the
    -- potential security issue that a finding captured.
    --
    -- Uses the @date-time@ format specified in
    -- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
    -- The value cannot contain spaces. For example,
    -- @2020-03-22T13:22:13.933Z@.
    AwsSecurityFinding -> Maybe Text
firstObservedAt :: Prelude.Maybe Prelude.Text,
    -- | A list of malware related to a finding.
    AwsSecurityFinding -> Maybe [Malware]
malware :: Prelude.Maybe [Malware],
    -- | A finding\'s confidence. Confidence is defined as the likelihood that a
    -- finding accurately identifies the behavior or issue that it was intended
    -- to identify.
    --
    -- Confidence is scored on a 0-100 basis using a ratio scale, where 0 means
    -- zero percent confidence and 100 means 100 percent confidence.
    AwsSecurityFinding -> Maybe Int
confidence :: Prelude.Maybe Prelude.Int,
    -- | A data type that describes the remediation options for a finding.
    AwsSecurityFinding -> Maybe Remediation
remediation :: Prelude.Maybe Remediation,
    -- | Provides an overview of the patch compliance status for an instance
    -- against a selected compliance standard.
    AwsSecurityFinding -> Maybe PatchSummary
patchSummary :: Prelude.Maybe PatchSummary,
    -- | Provides a list of vulnerabilities associated with the findings.
    AwsSecurityFinding -> Maybe [Vulnerability]
vulnerabilities :: Prelude.Maybe [Vulnerability],
    -- | The Region from which the finding was generated.
    --
    -- Security Hub populates this attribute automatically for each finding.
    -- You cannot update it using @BatchImportFindings@ or
    -- @BatchUpdateFindings@.
    AwsSecurityFinding -> Maybe Text
region :: Prelude.Maybe Prelude.Text,
    -- | Provides information about a network path that is relevant to a finding.
    -- Each entry under @NetworkPath@ represents a component of that path.
    AwsSecurityFinding -> Maybe [NetworkPathComponent]
networkPath :: Prelude.Maybe [NetworkPathComponent],
    -- | Provides information about the status of the investigation into a
    -- finding.
    AwsSecurityFinding -> Maybe Workflow
workflow :: Prelude.Maybe Workflow,
    -- | Indicates the veracity of a finding.
    AwsSecurityFinding -> Maybe VerificationState
verificationState :: Prelude.Maybe VerificationState,
    -- | Threat intelligence details related to a finding.
    AwsSecurityFinding -> Maybe [ThreatIntelIndicator]
threatIntelIndicators :: Prelude.Maybe [ThreatIntelIndicator],
    -- | A URL that links to a page about the current finding in the
    -- security-findings provider\'s solution.
    AwsSecurityFinding -> Maybe Text
sourceUrl :: Prelude.Maybe Prelude.Text,
    -- | Indicates when the security-findings provider most recently observed the
    -- potential security issue that a finding captured.
    --
    -- Uses the @date-time@ format specified in
    -- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
    -- The value cannot contain spaces. For example,
    -- @2020-03-22T13:22:13.933Z@.
    AwsSecurityFinding -> Maybe Text
lastObservedAt :: Prelude.Maybe Prelude.Text,
    -- | A list of name\/value string pairs associated with the finding. These
    -- are custom, user-defined fields added to a finding.
    AwsSecurityFinding -> Maybe (HashMap Text Text)
userDefinedFields :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | The schema version that a finding is formatted for.
    AwsSecurityFinding -> Text
schemaVersion :: Prelude.Text,
    -- | The security findings provider-specific identifier for a finding.
    AwsSecurityFinding -> Text
id :: Prelude.Text,
    -- | The ARN generated by Security Hub that uniquely identifies a product
    -- that generates findings. This can be the ARN for a third-party product
    -- that is integrated with Security Hub, or the ARN for a custom
    -- integration.
    AwsSecurityFinding -> Text
productArn :: Prelude.Text,
    -- | The identifier for the solution-specific component (a discrete unit of
    -- logic) that generated a finding. In various security-findings
    -- providers\' solutions, this generator can be called a rule, a check, a
    -- detector, a plugin, etc.
    AwsSecurityFinding -> Text
generatorId :: Prelude.Text,
    -- | The Amazon Web Services account ID that a finding is generated in.
    AwsSecurityFinding -> Text
awsAccountId :: Prelude.Text,
    -- | Indicates when the security-findings provider created the potential
    -- security issue that a finding captured.
    --
    -- Uses the @date-time@ format specified in
    -- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
    -- The value cannot contain spaces. For example,
    -- @2020-03-22T13:22:13.933Z@.
    AwsSecurityFinding -> Text
createdAt :: Prelude.Text,
    -- | Indicates when the security-findings provider last updated the finding
    -- record.
    --
    -- Uses the @date-time@ format specified in
    -- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
    -- The value cannot contain spaces. For example,
    -- @2020-03-22T13:22:13.933Z@.
    AwsSecurityFinding -> Text
updatedAt :: Prelude.Text,
    -- | A finding\'s title.
    --
    -- In this release, @Title@ is a required property.
    AwsSecurityFinding -> Text
title :: Prelude.Text,
    -- | A finding\'s description.
    --
    -- In this release, @Description@ is a required property.
    AwsSecurityFinding -> Text
description :: Prelude.Text,
    -- | A set of resource data types that describe the resources that the
    -- finding refers to.
    AwsSecurityFinding -> [Resource]
resources :: [Resource]
  }
  deriving (AwsSecurityFinding -> AwsSecurityFinding -> Bool
(AwsSecurityFinding -> AwsSecurityFinding -> Bool)
-> (AwsSecurityFinding -> AwsSecurityFinding -> Bool)
-> Eq AwsSecurityFinding
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AwsSecurityFinding -> AwsSecurityFinding -> Bool
$c/= :: AwsSecurityFinding -> AwsSecurityFinding -> Bool
== :: AwsSecurityFinding -> AwsSecurityFinding -> Bool
$c== :: AwsSecurityFinding -> AwsSecurityFinding -> Bool
Prelude.Eq, ReadPrec [AwsSecurityFinding]
ReadPrec AwsSecurityFinding
Int -> ReadS AwsSecurityFinding
ReadS [AwsSecurityFinding]
(Int -> ReadS AwsSecurityFinding)
-> ReadS [AwsSecurityFinding]
-> ReadPrec AwsSecurityFinding
-> ReadPrec [AwsSecurityFinding]
-> Read AwsSecurityFinding
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AwsSecurityFinding]
$creadListPrec :: ReadPrec [AwsSecurityFinding]
readPrec :: ReadPrec AwsSecurityFinding
$creadPrec :: ReadPrec AwsSecurityFinding
readList :: ReadS [AwsSecurityFinding]
$creadList :: ReadS [AwsSecurityFinding]
readsPrec :: Int -> ReadS AwsSecurityFinding
$creadsPrec :: Int -> ReadS AwsSecurityFinding
Prelude.Read, Int -> AwsSecurityFinding -> ShowS
[AwsSecurityFinding] -> ShowS
AwsSecurityFinding -> String
(Int -> AwsSecurityFinding -> ShowS)
-> (AwsSecurityFinding -> String)
-> ([AwsSecurityFinding] -> ShowS)
-> Show AwsSecurityFinding
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AwsSecurityFinding] -> ShowS
$cshowList :: [AwsSecurityFinding] -> ShowS
show :: AwsSecurityFinding -> String
$cshow :: AwsSecurityFinding -> String
showsPrec :: Int -> AwsSecurityFinding -> ShowS
$cshowsPrec :: Int -> AwsSecurityFinding -> ShowS
Prelude.Show, (forall x. AwsSecurityFinding -> Rep AwsSecurityFinding x)
-> (forall x. Rep AwsSecurityFinding x -> AwsSecurityFinding)
-> Generic AwsSecurityFinding
forall x. Rep AwsSecurityFinding x -> AwsSecurityFinding
forall x. AwsSecurityFinding -> Rep AwsSecurityFinding x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AwsSecurityFinding x -> AwsSecurityFinding
$cfrom :: forall x. AwsSecurityFinding -> Rep AwsSecurityFinding x
Prelude.Generic)

-- |
-- Create a value of 'AwsSecurityFinding' 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:
--
-- 'productName', 'awsSecurityFinding_productName' - The name of the product that generated the finding.
--
-- Security Hub populates this attribute automatically for each finding.
-- You cannot update it using @BatchImportFindings@ or
-- @BatchUpdateFindings@. The exception to this is when you use a custom
-- integration.
--
-- When you use the Security Hub console to filter findings by product
-- name, you use this attribute.
--
-- When you use the Security Hub API to filter findings by product name,
-- you use the @aws\/securityhub\/ProductName@ attribute under
-- @ProductFields@.
--
-- Security Hub does not synchronize those two attributes.
--
-- 'workflowState', 'awsSecurityFinding_workflowState' - The workflow state of a finding.
--
-- 'criticality', 'awsSecurityFinding_criticality' - The level of importance assigned to the resources associated with the
-- finding.
--
-- A score of 0 means that the underlying resources have no criticality,
-- and a score of 100 is reserved for the most critical resources.
--
-- 'recordState', 'awsSecurityFinding_recordState' - The record state of a finding.
--
-- 'productFields', 'awsSecurityFinding_productFields' - A data type where security-findings providers can include additional
-- solution-specific details that aren\'t part of the defined
-- @AwsSecurityFinding@ format.
--
-- Can contain up to 50 key-value pairs. For each key-value pair, the key
-- can contain up to 128 characters, and the value can contain up to 2048
-- characters.
--
-- 'compliance', 'awsSecurityFinding_compliance' - This data type is exclusive to findings that are generated as the result
-- of a check run against a specific rule in a supported security standard,
-- such as CIS Amazon Web Services Foundations. Contains security
-- standard-related finding details.
--
-- 'findingProviderFields', 'awsSecurityFinding_findingProviderFields' - In a @BatchImportFindings@ request, finding providers use
-- @FindingProviderFields@ to provide and update their own values for
-- confidence, criticality, related findings, severity, and types.
--
-- 'companyName', 'awsSecurityFinding_companyName' - The name of the company for the product that generated the finding.
--
-- Security Hub populates this attribute automatically for each finding.
-- You cannot be updated using @BatchImportFindings@ or
-- @BatchUpdateFindings@. The exception to this is when you use a custom
-- integration.
--
-- When you use the Security Hub console to filter findings by company
-- name, you use this attribute.
--
-- When you use the Security Hub API to filter findings by company name,
-- you use the @aws\/securityhub\/CompanyName@ attribute under
-- @ProductFields@.
--
-- Security Hub does not synchronize those two attributes.
--
-- 'note', 'awsSecurityFinding_note' - A user-defined note added to a finding.
--
-- 'process', 'awsSecurityFinding_process' - The details of process-related information about a finding.
--
-- 'severity', 'awsSecurityFinding_severity' - A finding\'s severity.
--
-- 'types', 'awsSecurityFinding_types' - One or more finding types in the format of
-- @namespace\/category\/classifier@ that classify a finding.
--
-- Valid namespace values are: Software and Configuration Checks | TTPs |
-- Effects | Unusual Behaviors | Sensitive Data Identifications
--
-- 'action', 'awsSecurityFinding_action' - Provides details about an action that affects or that was taken on a
-- resource.
--
-- 'network', 'awsSecurityFinding_network' - The details of network-related information about a finding.
--
-- 'relatedFindings', 'awsSecurityFinding_relatedFindings' - A list of related findings.
--
-- 'firstObservedAt', 'awsSecurityFinding_firstObservedAt' - Indicates when the security-findings provider first observed the
-- potential security issue that a finding captured.
--
-- Uses the @date-time@ format specified in
-- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
-- The value cannot contain spaces. For example,
-- @2020-03-22T13:22:13.933Z@.
--
-- 'malware', 'awsSecurityFinding_malware' - A list of malware related to a finding.
--
-- 'confidence', 'awsSecurityFinding_confidence' - A finding\'s confidence. Confidence is defined as the likelihood that a
-- finding accurately identifies the behavior or issue that it was intended
-- to identify.
--
-- Confidence is scored on a 0-100 basis using a ratio scale, where 0 means
-- zero percent confidence and 100 means 100 percent confidence.
--
-- 'remediation', 'awsSecurityFinding_remediation' - A data type that describes the remediation options for a finding.
--
-- 'patchSummary', 'awsSecurityFinding_patchSummary' - Provides an overview of the patch compliance status for an instance
-- against a selected compliance standard.
--
-- 'vulnerabilities', 'awsSecurityFinding_vulnerabilities' - Provides a list of vulnerabilities associated with the findings.
--
-- 'region', 'awsSecurityFinding_region' - The Region from which the finding was generated.
--
-- Security Hub populates this attribute automatically for each finding.
-- You cannot update it using @BatchImportFindings@ or
-- @BatchUpdateFindings@.
--
-- 'networkPath', 'awsSecurityFinding_networkPath' - Provides information about a network path that is relevant to a finding.
-- Each entry under @NetworkPath@ represents a component of that path.
--
-- 'workflow', 'awsSecurityFinding_workflow' - Provides information about the status of the investigation into a
-- finding.
--
-- 'verificationState', 'awsSecurityFinding_verificationState' - Indicates the veracity of a finding.
--
-- 'threatIntelIndicators', 'awsSecurityFinding_threatIntelIndicators' - Threat intelligence details related to a finding.
--
-- 'sourceUrl', 'awsSecurityFinding_sourceUrl' - A URL that links to a page about the current finding in the
-- security-findings provider\'s solution.
--
-- 'lastObservedAt', 'awsSecurityFinding_lastObservedAt' - Indicates when the security-findings provider most recently observed the
-- potential security issue that a finding captured.
--
-- Uses the @date-time@ format specified in
-- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
-- The value cannot contain spaces. For example,
-- @2020-03-22T13:22:13.933Z@.
--
-- 'userDefinedFields', 'awsSecurityFinding_userDefinedFields' - A list of name\/value string pairs associated with the finding. These
-- are custom, user-defined fields added to a finding.
--
-- 'schemaVersion', 'awsSecurityFinding_schemaVersion' - The schema version that a finding is formatted for.
--
-- 'id', 'awsSecurityFinding_id' - The security findings provider-specific identifier for a finding.
--
-- 'productArn', 'awsSecurityFinding_productArn' - The ARN generated by Security Hub that uniquely identifies a product
-- that generates findings. This can be the ARN for a third-party product
-- that is integrated with Security Hub, or the ARN for a custom
-- integration.
--
-- 'generatorId', 'awsSecurityFinding_generatorId' - The identifier for the solution-specific component (a discrete unit of
-- logic) that generated a finding. In various security-findings
-- providers\' solutions, this generator can be called a rule, a check, a
-- detector, a plugin, etc.
--
-- 'awsAccountId', 'awsSecurityFinding_awsAccountId' - The Amazon Web Services account ID that a finding is generated in.
--
-- 'createdAt', 'awsSecurityFinding_createdAt' - Indicates when the security-findings provider created the potential
-- security issue that a finding captured.
--
-- Uses the @date-time@ format specified in
-- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
-- The value cannot contain spaces. For example,
-- @2020-03-22T13:22:13.933Z@.
--
-- 'updatedAt', 'awsSecurityFinding_updatedAt' - Indicates when the security-findings provider last updated the finding
-- record.
--
-- Uses the @date-time@ format specified in
-- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
-- The value cannot contain spaces. For example,
-- @2020-03-22T13:22:13.933Z@.
--
-- 'title', 'awsSecurityFinding_title' - A finding\'s title.
--
-- In this release, @Title@ is a required property.
--
-- 'description', 'awsSecurityFinding_description' - A finding\'s description.
--
-- In this release, @Description@ is a required property.
--
-- 'resources', 'awsSecurityFinding_resources' - A set of resource data types that describe the resources that the
-- finding refers to.
newAwsSecurityFinding ::
  -- | 'schemaVersion'
  Prelude.Text ->
  -- | 'id'
  Prelude.Text ->
  -- | 'productArn'
  Prelude.Text ->
  -- | 'generatorId'
  Prelude.Text ->
  -- | 'awsAccountId'
  Prelude.Text ->
  -- | 'createdAt'
  Prelude.Text ->
  -- | 'updatedAt'
  Prelude.Text ->
  -- | 'title'
  Prelude.Text ->
  -- | 'description'
  Prelude.Text ->
  AwsSecurityFinding
newAwsSecurityFinding :: Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> AwsSecurityFinding
newAwsSecurityFinding
  Text
pSchemaVersion_
  Text
pId_
  Text
pProductArn_
  Text
pGeneratorId_
  Text
pAwsAccountId_
  Text
pCreatedAt_
  Text
pUpdatedAt_
  Text
pTitle_
  Text
pDescription_ =
    AwsSecurityFinding' :: Maybe Text
-> Maybe WorkflowState
-> Maybe Int
-> Maybe RecordState
-> Maybe (HashMap Text Text)
-> Maybe Compliance
-> Maybe FindingProviderFields
-> Maybe Text
-> Maybe Note
-> Maybe ProcessDetails
-> Maybe Severity
-> Maybe [Text]
-> Maybe Action
-> Maybe Network
-> Maybe [RelatedFinding]
-> Maybe Text
-> Maybe [Malware]
-> Maybe Int
-> Maybe Remediation
-> Maybe PatchSummary
-> Maybe [Vulnerability]
-> Maybe Text
-> Maybe [NetworkPathComponent]
-> Maybe Workflow
-> Maybe VerificationState
-> Maybe [ThreatIntelIndicator]
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> [Resource]
-> AwsSecurityFinding
AwsSecurityFinding'
      { $sel:productName:AwsSecurityFinding' :: Maybe Text
productName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:workflowState:AwsSecurityFinding' :: Maybe WorkflowState
workflowState = Maybe WorkflowState
forall a. Maybe a
Prelude.Nothing,
        $sel:criticality:AwsSecurityFinding' :: Maybe Int
criticality = Maybe Int
forall a. Maybe a
Prelude.Nothing,
        $sel:recordState:AwsSecurityFinding' :: Maybe RecordState
recordState = Maybe RecordState
forall a. Maybe a
Prelude.Nothing,
        $sel:productFields:AwsSecurityFinding' :: Maybe (HashMap Text Text)
productFields = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
        $sel:compliance:AwsSecurityFinding' :: Maybe Compliance
compliance = Maybe Compliance
forall a. Maybe a
Prelude.Nothing,
        $sel:findingProviderFields:AwsSecurityFinding' :: Maybe FindingProviderFields
findingProviderFields = Maybe FindingProviderFields
forall a. Maybe a
Prelude.Nothing,
        $sel:companyName:AwsSecurityFinding' :: Maybe Text
companyName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:note:AwsSecurityFinding' :: Maybe Note
note = Maybe Note
forall a. Maybe a
Prelude.Nothing,
        $sel:process:AwsSecurityFinding' :: Maybe ProcessDetails
process = Maybe ProcessDetails
forall a. Maybe a
Prelude.Nothing,
        $sel:severity:AwsSecurityFinding' :: Maybe Severity
severity = Maybe Severity
forall a. Maybe a
Prelude.Nothing,
        $sel:types:AwsSecurityFinding' :: Maybe [Text]
types = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
        $sel:action:AwsSecurityFinding' :: Maybe Action
action = Maybe Action
forall a. Maybe a
Prelude.Nothing,
        $sel:network:AwsSecurityFinding' :: Maybe Network
network = Maybe Network
forall a. Maybe a
Prelude.Nothing,
        $sel:relatedFindings:AwsSecurityFinding' :: Maybe [RelatedFinding]
relatedFindings = Maybe [RelatedFinding]
forall a. Maybe a
Prelude.Nothing,
        $sel:firstObservedAt:AwsSecurityFinding' :: Maybe Text
firstObservedAt = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:malware:AwsSecurityFinding' :: Maybe [Malware]
malware = Maybe [Malware]
forall a. Maybe a
Prelude.Nothing,
        $sel:confidence:AwsSecurityFinding' :: Maybe Int
confidence = Maybe Int
forall a. Maybe a
Prelude.Nothing,
        $sel:remediation:AwsSecurityFinding' :: Maybe Remediation
remediation = Maybe Remediation
forall a. Maybe a
Prelude.Nothing,
        $sel:patchSummary:AwsSecurityFinding' :: Maybe PatchSummary
patchSummary = Maybe PatchSummary
forall a. Maybe a
Prelude.Nothing,
        $sel:vulnerabilities:AwsSecurityFinding' :: Maybe [Vulnerability]
vulnerabilities = Maybe [Vulnerability]
forall a. Maybe a
Prelude.Nothing,
        $sel:region:AwsSecurityFinding' :: Maybe Text
region = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:networkPath:AwsSecurityFinding' :: Maybe [NetworkPathComponent]
networkPath = Maybe [NetworkPathComponent]
forall a. Maybe a
Prelude.Nothing,
        $sel:workflow:AwsSecurityFinding' :: Maybe Workflow
workflow = Maybe Workflow
forall a. Maybe a
Prelude.Nothing,
        $sel:verificationState:AwsSecurityFinding' :: Maybe VerificationState
verificationState = Maybe VerificationState
forall a. Maybe a
Prelude.Nothing,
        $sel:threatIntelIndicators:AwsSecurityFinding' :: Maybe [ThreatIntelIndicator]
threatIntelIndicators = Maybe [ThreatIntelIndicator]
forall a. Maybe a
Prelude.Nothing,
        $sel:sourceUrl:AwsSecurityFinding' :: Maybe Text
sourceUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:lastObservedAt:AwsSecurityFinding' :: Maybe Text
lastObservedAt = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:userDefinedFields:AwsSecurityFinding' :: Maybe (HashMap Text Text)
userDefinedFields = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
        $sel:schemaVersion:AwsSecurityFinding' :: Text
schemaVersion = Text
pSchemaVersion_,
        $sel:id:AwsSecurityFinding' :: Text
id = Text
pId_,
        $sel:productArn:AwsSecurityFinding' :: Text
productArn = Text
pProductArn_,
        $sel:generatorId:AwsSecurityFinding' :: Text
generatorId = Text
pGeneratorId_,
        $sel:awsAccountId:AwsSecurityFinding' :: Text
awsAccountId = Text
pAwsAccountId_,
        $sel:createdAt:AwsSecurityFinding' :: Text
createdAt = Text
pCreatedAt_,
        $sel:updatedAt:AwsSecurityFinding' :: Text
updatedAt = Text
pUpdatedAt_,
        $sel:title:AwsSecurityFinding' :: Text
title = Text
pTitle_,
        $sel:description:AwsSecurityFinding' :: Text
description = Text
pDescription_,
        $sel:resources:AwsSecurityFinding' :: [Resource]
resources = [Resource]
forall a. Monoid a => a
Prelude.mempty
      }

-- | The name of the product that generated the finding.
--
-- Security Hub populates this attribute automatically for each finding.
-- You cannot update it using @BatchImportFindings@ or
-- @BatchUpdateFindings@. The exception to this is when you use a custom
-- integration.
--
-- When you use the Security Hub console to filter findings by product
-- name, you use this attribute.
--
-- When you use the Security Hub API to filter findings by product name,
-- you use the @aws\/securityhub\/ProductName@ attribute under
-- @ProductFields@.
--
-- Security Hub does not synchronize those two attributes.
awsSecurityFinding_productName :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Prelude.Text)
awsSecurityFinding_productName :: (Maybe Text -> f (Maybe Text))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_productName = (AwsSecurityFinding -> Maybe Text)
-> (AwsSecurityFinding -> Maybe Text -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Text
productName :: Maybe Text
$sel:productName:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
productName} -> Maybe Text
productName) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Text
a -> AwsSecurityFinding
s {$sel:productName:AwsSecurityFinding' :: Maybe Text
productName = Maybe Text
a} :: AwsSecurityFinding)

-- | The workflow state of a finding.
awsSecurityFinding_workflowState :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe WorkflowState)
awsSecurityFinding_workflowState :: (Maybe WorkflowState -> f (Maybe WorkflowState))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_workflowState = (AwsSecurityFinding -> Maybe WorkflowState)
-> (AwsSecurityFinding
    -> Maybe WorkflowState -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe WorkflowState)
     (Maybe WorkflowState)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe WorkflowState
workflowState :: Maybe WorkflowState
$sel:workflowState:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe WorkflowState
workflowState} -> Maybe WorkflowState
workflowState) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe WorkflowState
a -> AwsSecurityFinding
s {$sel:workflowState:AwsSecurityFinding' :: Maybe WorkflowState
workflowState = Maybe WorkflowState
a} :: AwsSecurityFinding)

-- | The level of importance assigned to the resources associated with the
-- finding.
--
-- A score of 0 means that the underlying resources have no criticality,
-- and a score of 100 is reserved for the most critical resources.
awsSecurityFinding_criticality :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Prelude.Int)
awsSecurityFinding_criticality :: (Maybe Int -> f (Maybe Int))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_criticality = (AwsSecurityFinding -> Maybe Int)
-> (AwsSecurityFinding -> Maybe Int -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Int
criticality :: Maybe Int
$sel:criticality:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Int
criticality} -> Maybe Int
criticality) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Int
a -> AwsSecurityFinding
s {$sel:criticality:AwsSecurityFinding' :: Maybe Int
criticality = Maybe Int
a} :: AwsSecurityFinding)

-- | The record state of a finding.
awsSecurityFinding_recordState :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe RecordState)
awsSecurityFinding_recordState :: (Maybe RecordState -> f (Maybe RecordState))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_recordState = (AwsSecurityFinding -> Maybe RecordState)
-> (AwsSecurityFinding -> Maybe RecordState -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe RecordState)
     (Maybe RecordState)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe RecordState
recordState :: Maybe RecordState
$sel:recordState:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe RecordState
recordState} -> Maybe RecordState
recordState) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe RecordState
a -> AwsSecurityFinding
s {$sel:recordState:AwsSecurityFinding' :: Maybe RecordState
recordState = Maybe RecordState
a} :: AwsSecurityFinding)

-- | A data type where security-findings providers can include additional
-- solution-specific details that aren\'t part of the defined
-- @AwsSecurityFinding@ format.
--
-- Can contain up to 50 key-value pairs. For each key-value pair, the key
-- can contain up to 128 characters, and the value can contain up to 2048
-- characters.
awsSecurityFinding_productFields :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
awsSecurityFinding_productFields :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_productFields = (AwsSecurityFinding -> Maybe (HashMap Text Text))
-> (AwsSecurityFinding
    -> Maybe (HashMap Text Text) -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe (HashMap Text Text)
productFields :: Maybe (HashMap Text Text)
$sel:productFields:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe (HashMap Text Text)
productFields} -> Maybe (HashMap Text Text)
productFields) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe (HashMap Text Text)
a -> AwsSecurityFinding
s {$sel:productFields:AwsSecurityFinding' :: Maybe (HashMap Text Text)
productFields = Maybe (HashMap Text Text)
a} :: AwsSecurityFinding) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
    -> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
-> Iso
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
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 AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | This data type is exclusive to findings that are generated as the result
-- of a check run against a specific rule in a supported security standard,
-- such as CIS Amazon Web Services Foundations. Contains security
-- standard-related finding details.
awsSecurityFinding_compliance :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Compliance)
awsSecurityFinding_compliance :: (Maybe Compliance -> f (Maybe Compliance))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_compliance = (AwsSecurityFinding -> Maybe Compliance)
-> (AwsSecurityFinding -> Maybe Compliance -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe Compliance)
     (Maybe Compliance)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Compliance
compliance :: Maybe Compliance
$sel:compliance:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Compliance
compliance} -> Maybe Compliance
compliance) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Compliance
a -> AwsSecurityFinding
s {$sel:compliance:AwsSecurityFinding' :: Maybe Compliance
compliance = Maybe Compliance
a} :: AwsSecurityFinding)

-- | In a @BatchImportFindings@ request, finding providers use
-- @FindingProviderFields@ to provide and update their own values for
-- confidence, criticality, related findings, severity, and types.
awsSecurityFinding_findingProviderFields :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe FindingProviderFields)
awsSecurityFinding_findingProviderFields :: (Maybe FindingProviderFields -> f (Maybe FindingProviderFields))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_findingProviderFields = (AwsSecurityFinding -> Maybe FindingProviderFields)
-> (AwsSecurityFinding
    -> Maybe FindingProviderFields -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe FindingProviderFields)
     (Maybe FindingProviderFields)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe FindingProviderFields
findingProviderFields :: Maybe FindingProviderFields
$sel:findingProviderFields:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe FindingProviderFields
findingProviderFields} -> Maybe FindingProviderFields
findingProviderFields) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe FindingProviderFields
a -> AwsSecurityFinding
s {$sel:findingProviderFields:AwsSecurityFinding' :: Maybe FindingProviderFields
findingProviderFields = Maybe FindingProviderFields
a} :: AwsSecurityFinding)

-- | The name of the company for the product that generated the finding.
--
-- Security Hub populates this attribute automatically for each finding.
-- You cannot be updated using @BatchImportFindings@ or
-- @BatchUpdateFindings@. The exception to this is when you use a custom
-- integration.
--
-- When you use the Security Hub console to filter findings by company
-- name, you use this attribute.
--
-- When you use the Security Hub API to filter findings by company name,
-- you use the @aws\/securityhub\/CompanyName@ attribute under
-- @ProductFields@.
--
-- Security Hub does not synchronize those two attributes.
awsSecurityFinding_companyName :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Prelude.Text)
awsSecurityFinding_companyName :: (Maybe Text -> f (Maybe Text))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_companyName = (AwsSecurityFinding -> Maybe Text)
-> (AwsSecurityFinding -> Maybe Text -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Text
companyName :: Maybe Text
$sel:companyName:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
companyName} -> Maybe Text
companyName) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Text
a -> AwsSecurityFinding
s {$sel:companyName:AwsSecurityFinding' :: Maybe Text
companyName = Maybe Text
a} :: AwsSecurityFinding)

-- | A user-defined note added to a finding.
awsSecurityFinding_note :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Note)
awsSecurityFinding_note :: (Maybe Note -> f (Maybe Note))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_note = (AwsSecurityFinding -> Maybe Note)
-> (AwsSecurityFinding -> Maybe Note -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Note) (Maybe Note)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Note
note :: Maybe Note
$sel:note:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Note
note} -> Maybe Note
note) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Note
a -> AwsSecurityFinding
s {$sel:note:AwsSecurityFinding' :: Maybe Note
note = Maybe Note
a} :: AwsSecurityFinding)

-- | The details of process-related information about a finding.
awsSecurityFinding_process :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe ProcessDetails)
awsSecurityFinding_process :: (Maybe ProcessDetails -> f (Maybe ProcessDetails))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_process = (AwsSecurityFinding -> Maybe ProcessDetails)
-> (AwsSecurityFinding
    -> Maybe ProcessDetails -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe ProcessDetails)
     (Maybe ProcessDetails)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe ProcessDetails
process :: Maybe ProcessDetails
$sel:process:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe ProcessDetails
process} -> Maybe ProcessDetails
process) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe ProcessDetails
a -> AwsSecurityFinding
s {$sel:process:AwsSecurityFinding' :: Maybe ProcessDetails
process = Maybe ProcessDetails
a} :: AwsSecurityFinding)

-- | A finding\'s severity.
awsSecurityFinding_severity :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Severity)
awsSecurityFinding_severity :: (Maybe Severity -> f (Maybe Severity))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_severity = (AwsSecurityFinding -> Maybe Severity)
-> (AwsSecurityFinding -> Maybe Severity -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe Severity)
     (Maybe Severity)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Severity
severity :: Maybe Severity
$sel:severity:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Severity
severity} -> Maybe Severity
severity) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Severity
a -> AwsSecurityFinding
s {$sel:severity:AwsSecurityFinding' :: Maybe Severity
severity = Maybe Severity
a} :: AwsSecurityFinding)

-- | One or more finding types in the format of
-- @namespace\/category\/classifier@ that classify a finding.
--
-- Valid namespace values are: Software and Configuration Checks | TTPs |
-- Effects | Unusual Behaviors | Sensitive Data Identifications
awsSecurityFinding_types :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe [Prelude.Text])
awsSecurityFinding_types :: (Maybe [Text] -> f (Maybe [Text]))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_types = (AwsSecurityFinding -> Maybe [Text])
-> (AwsSecurityFinding -> Maybe [Text] -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe [Text]
types :: Maybe [Text]
$sel:types:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [Text]
types} -> Maybe [Text]
types) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe [Text]
a -> AwsSecurityFinding
s {$sel:types:AwsSecurityFinding' :: Maybe [Text]
types = Maybe [Text]
a} :: AwsSecurityFinding) ((Maybe [Text] -> f (Maybe [Text]))
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Provides details about an action that affects or that was taken on a
-- resource.
awsSecurityFinding_action :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Action)
awsSecurityFinding_action :: (Maybe Action -> f (Maybe Action))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_action = (AwsSecurityFinding -> Maybe Action)
-> (AwsSecurityFinding -> Maybe Action -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Action) (Maybe Action)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Action
action :: Maybe Action
$sel:action:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Action
action} -> Maybe Action
action) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Action
a -> AwsSecurityFinding
s {$sel:action:AwsSecurityFinding' :: Maybe Action
action = Maybe Action
a} :: AwsSecurityFinding)

-- | The details of network-related information about a finding.
awsSecurityFinding_network :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Network)
awsSecurityFinding_network :: (Maybe Network -> f (Maybe Network))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_network = (AwsSecurityFinding -> Maybe Network)
-> (AwsSecurityFinding -> Maybe Network -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe Network)
     (Maybe Network)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Network
network :: Maybe Network
$sel:network:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Network
network} -> Maybe Network
network) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Network
a -> AwsSecurityFinding
s {$sel:network:AwsSecurityFinding' :: Maybe Network
network = Maybe Network
a} :: AwsSecurityFinding)

-- | A list of related findings.
awsSecurityFinding_relatedFindings :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe [RelatedFinding])
awsSecurityFinding_relatedFindings :: (Maybe [RelatedFinding] -> f (Maybe [RelatedFinding]))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_relatedFindings = (AwsSecurityFinding -> Maybe [RelatedFinding])
-> (AwsSecurityFinding
    -> Maybe [RelatedFinding] -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe [RelatedFinding])
     (Maybe [RelatedFinding])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe [RelatedFinding]
relatedFindings :: Maybe [RelatedFinding]
$sel:relatedFindings:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [RelatedFinding]
relatedFindings} -> Maybe [RelatedFinding]
relatedFindings) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe [RelatedFinding]
a -> AwsSecurityFinding
s {$sel:relatedFindings:AwsSecurityFinding' :: Maybe [RelatedFinding]
relatedFindings = Maybe [RelatedFinding]
a} :: AwsSecurityFinding) ((Maybe [RelatedFinding] -> f (Maybe [RelatedFinding]))
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> ((Maybe [RelatedFinding] -> f (Maybe [RelatedFinding]))
    -> Maybe [RelatedFinding] -> f (Maybe [RelatedFinding]))
-> (Maybe [RelatedFinding] -> f (Maybe [RelatedFinding]))
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [RelatedFinding] [RelatedFinding] [RelatedFinding] [RelatedFinding]
-> Iso
     (Maybe [RelatedFinding])
     (Maybe [RelatedFinding])
     (Maybe [RelatedFinding])
     (Maybe [RelatedFinding])
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 AnIso
  [RelatedFinding] [RelatedFinding] [RelatedFinding] [RelatedFinding]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Indicates when the security-findings provider first observed the
-- potential security issue that a finding captured.
--
-- Uses the @date-time@ format specified in
-- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
-- The value cannot contain spaces. For example,
-- @2020-03-22T13:22:13.933Z@.
awsSecurityFinding_firstObservedAt :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Prelude.Text)
awsSecurityFinding_firstObservedAt :: (Maybe Text -> f (Maybe Text))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_firstObservedAt = (AwsSecurityFinding -> Maybe Text)
-> (AwsSecurityFinding -> Maybe Text -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Text
firstObservedAt :: Maybe Text
$sel:firstObservedAt:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
firstObservedAt} -> Maybe Text
firstObservedAt) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Text
a -> AwsSecurityFinding
s {$sel:firstObservedAt:AwsSecurityFinding' :: Maybe Text
firstObservedAt = Maybe Text
a} :: AwsSecurityFinding)

-- | A list of malware related to a finding.
awsSecurityFinding_malware :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe [Malware])
awsSecurityFinding_malware :: (Maybe [Malware] -> f (Maybe [Malware]))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_malware = (AwsSecurityFinding -> Maybe [Malware])
-> (AwsSecurityFinding -> Maybe [Malware] -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe [Malware])
     (Maybe [Malware])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe [Malware]
malware :: Maybe [Malware]
$sel:malware:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [Malware]
malware} -> Maybe [Malware]
malware) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe [Malware]
a -> AwsSecurityFinding
s {$sel:malware:AwsSecurityFinding' :: Maybe [Malware]
malware = Maybe [Malware]
a} :: AwsSecurityFinding) ((Maybe [Malware] -> f (Maybe [Malware]))
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> ((Maybe [Malware] -> f (Maybe [Malware]))
    -> Maybe [Malware] -> f (Maybe [Malware]))
-> (Maybe [Malware] -> f (Maybe [Malware]))
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Malware] [Malware] [Malware] [Malware]
-> Iso
     (Maybe [Malware])
     (Maybe [Malware])
     (Maybe [Malware])
     (Maybe [Malware])
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 AnIso [Malware] [Malware] [Malware] [Malware]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A finding\'s confidence. Confidence is defined as the likelihood that a
-- finding accurately identifies the behavior or issue that it was intended
-- to identify.
--
-- Confidence is scored on a 0-100 basis using a ratio scale, where 0 means
-- zero percent confidence and 100 means 100 percent confidence.
awsSecurityFinding_confidence :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Prelude.Int)
awsSecurityFinding_confidence :: (Maybe Int -> f (Maybe Int))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_confidence = (AwsSecurityFinding -> Maybe Int)
-> (AwsSecurityFinding -> Maybe Int -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Int
confidence :: Maybe Int
$sel:confidence:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Int
confidence} -> Maybe Int
confidence) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Int
a -> AwsSecurityFinding
s {$sel:confidence:AwsSecurityFinding' :: Maybe Int
confidence = Maybe Int
a} :: AwsSecurityFinding)

-- | A data type that describes the remediation options for a finding.
awsSecurityFinding_remediation :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Remediation)
awsSecurityFinding_remediation :: (Maybe Remediation -> f (Maybe Remediation))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_remediation = (AwsSecurityFinding -> Maybe Remediation)
-> (AwsSecurityFinding -> Maybe Remediation -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe Remediation)
     (Maybe Remediation)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Remediation
remediation :: Maybe Remediation
$sel:remediation:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Remediation
remediation} -> Maybe Remediation
remediation) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Remediation
a -> AwsSecurityFinding
s {$sel:remediation:AwsSecurityFinding' :: Maybe Remediation
remediation = Maybe Remediation
a} :: AwsSecurityFinding)

-- | Provides an overview of the patch compliance status for an instance
-- against a selected compliance standard.
awsSecurityFinding_patchSummary :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe PatchSummary)
awsSecurityFinding_patchSummary :: (Maybe PatchSummary -> f (Maybe PatchSummary))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_patchSummary = (AwsSecurityFinding -> Maybe PatchSummary)
-> (AwsSecurityFinding -> Maybe PatchSummary -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe PatchSummary)
     (Maybe PatchSummary)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe PatchSummary
patchSummary :: Maybe PatchSummary
$sel:patchSummary:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe PatchSummary
patchSummary} -> Maybe PatchSummary
patchSummary) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe PatchSummary
a -> AwsSecurityFinding
s {$sel:patchSummary:AwsSecurityFinding' :: Maybe PatchSummary
patchSummary = Maybe PatchSummary
a} :: AwsSecurityFinding)

-- | Provides a list of vulnerabilities associated with the findings.
awsSecurityFinding_vulnerabilities :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe [Vulnerability])
awsSecurityFinding_vulnerabilities :: (Maybe [Vulnerability] -> f (Maybe [Vulnerability]))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_vulnerabilities = (AwsSecurityFinding -> Maybe [Vulnerability])
-> (AwsSecurityFinding
    -> Maybe [Vulnerability] -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe [Vulnerability])
     (Maybe [Vulnerability])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe [Vulnerability]
vulnerabilities :: Maybe [Vulnerability]
$sel:vulnerabilities:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [Vulnerability]
vulnerabilities} -> Maybe [Vulnerability]
vulnerabilities) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe [Vulnerability]
a -> AwsSecurityFinding
s {$sel:vulnerabilities:AwsSecurityFinding' :: Maybe [Vulnerability]
vulnerabilities = Maybe [Vulnerability]
a} :: AwsSecurityFinding) ((Maybe [Vulnerability] -> f (Maybe [Vulnerability]))
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> ((Maybe [Vulnerability] -> f (Maybe [Vulnerability]))
    -> Maybe [Vulnerability] -> f (Maybe [Vulnerability]))
-> (Maybe [Vulnerability] -> f (Maybe [Vulnerability]))
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [Vulnerability] [Vulnerability] [Vulnerability] [Vulnerability]
-> Iso
     (Maybe [Vulnerability])
     (Maybe [Vulnerability])
     (Maybe [Vulnerability])
     (Maybe [Vulnerability])
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 AnIso
  [Vulnerability] [Vulnerability] [Vulnerability] [Vulnerability]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The Region from which the finding was generated.
--
-- Security Hub populates this attribute automatically for each finding.
-- You cannot update it using @BatchImportFindings@ or
-- @BatchUpdateFindings@.
awsSecurityFinding_region :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Prelude.Text)
awsSecurityFinding_region :: (Maybe Text -> f (Maybe Text))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_region = (AwsSecurityFinding -> Maybe Text)
-> (AwsSecurityFinding -> Maybe Text -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Text
region :: Maybe Text
$sel:region:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
region} -> Maybe Text
region) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Text
a -> AwsSecurityFinding
s {$sel:region:AwsSecurityFinding' :: Maybe Text
region = Maybe Text
a} :: AwsSecurityFinding)

-- | Provides information about a network path that is relevant to a finding.
-- Each entry under @NetworkPath@ represents a component of that path.
awsSecurityFinding_networkPath :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe [NetworkPathComponent])
awsSecurityFinding_networkPath :: (Maybe [NetworkPathComponent] -> f (Maybe [NetworkPathComponent]))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_networkPath = (AwsSecurityFinding -> Maybe [NetworkPathComponent])
-> (AwsSecurityFinding
    -> Maybe [NetworkPathComponent] -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe [NetworkPathComponent])
     (Maybe [NetworkPathComponent])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe [NetworkPathComponent]
networkPath :: Maybe [NetworkPathComponent]
$sel:networkPath:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [NetworkPathComponent]
networkPath} -> Maybe [NetworkPathComponent]
networkPath) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe [NetworkPathComponent]
a -> AwsSecurityFinding
s {$sel:networkPath:AwsSecurityFinding' :: Maybe [NetworkPathComponent]
networkPath = Maybe [NetworkPathComponent]
a} :: AwsSecurityFinding) ((Maybe [NetworkPathComponent] -> f (Maybe [NetworkPathComponent]))
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> ((Maybe [NetworkPathComponent]
     -> f (Maybe [NetworkPathComponent]))
    -> Maybe [NetworkPathComponent]
    -> f (Maybe [NetworkPathComponent]))
-> (Maybe [NetworkPathComponent]
    -> f (Maybe [NetworkPathComponent]))
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [NetworkPathComponent]
  [NetworkPathComponent]
  [NetworkPathComponent]
  [NetworkPathComponent]
-> Iso
     (Maybe [NetworkPathComponent])
     (Maybe [NetworkPathComponent])
     (Maybe [NetworkPathComponent])
     (Maybe [NetworkPathComponent])
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 AnIso
  [NetworkPathComponent]
  [NetworkPathComponent]
  [NetworkPathComponent]
  [NetworkPathComponent]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Provides information about the status of the investigation into a
-- finding.
awsSecurityFinding_workflow :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Workflow)
awsSecurityFinding_workflow :: (Maybe Workflow -> f (Maybe Workflow))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_workflow = (AwsSecurityFinding -> Maybe Workflow)
-> (AwsSecurityFinding -> Maybe Workflow -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe Workflow)
     (Maybe Workflow)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Workflow
workflow :: Maybe Workflow
$sel:workflow:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Workflow
workflow} -> Maybe Workflow
workflow) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Workflow
a -> AwsSecurityFinding
s {$sel:workflow:AwsSecurityFinding' :: Maybe Workflow
workflow = Maybe Workflow
a} :: AwsSecurityFinding)

-- | Indicates the veracity of a finding.
awsSecurityFinding_verificationState :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe VerificationState)
awsSecurityFinding_verificationState :: (Maybe VerificationState -> f (Maybe VerificationState))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_verificationState = (AwsSecurityFinding -> Maybe VerificationState)
-> (AwsSecurityFinding
    -> Maybe VerificationState -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe VerificationState)
     (Maybe VerificationState)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe VerificationState
verificationState :: Maybe VerificationState
$sel:verificationState:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe VerificationState
verificationState} -> Maybe VerificationState
verificationState) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe VerificationState
a -> AwsSecurityFinding
s {$sel:verificationState:AwsSecurityFinding' :: Maybe VerificationState
verificationState = Maybe VerificationState
a} :: AwsSecurityFinding)

-- | Threat intelligence details related to a finding.
awsSecurityFinding_threatIntelIndicators :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe [ThreatIntelIndicator])
awsSecurityFinding_threatIntelIndicators :: (Maybe [ThreatIntelIndicator] -> f (Maybe [ThreatIntelIndicator]))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_threatIntelIndicators = (AwsSecurityFinding -> Maybe [ThreatIntelIndicator])
-> (AwsSecurityFinding
    -> Maybe [ThreatIntelIndicator] -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe [ThreatIntelIndicator])
     (Maybe [ThreatIntelIndicator])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe [ThreatIntelIndicator]
threatIntelIndicators :: Maybe [ThreatIntelIndicator]
$sel:threatIntelIndicators:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [ThreatIntelIndicator]
threatIntelIndicators} -> Maybe [ThreatIntelIndicator]
threatIntelIndicators) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe [ThreatIntelIndicator]
a -> AwsSecurityFinding
s {$sel:threatIntelIndicators:AwsSecurityFinding' :: Maybe [ThreatIntelIndicator]
threatIntelIndicators = Maybe [ThreatIntelIndicator]
a} :: AwsSecurityFinding) ((Maybe [ThreatIntelIndicator] -> f (Maybe [ThreatIntelIndicator]))
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> ((Maybe [ThreatIntelIndicator]
     -> f (Maybe [ThreatIntelIndicator]))
    -> Maybe [ThreatIntelIndicator]
    -> f (Maybe [ThreatIntelIndicator]))
-> (Maybe [ThreatIntelIndicator]
    -> f (Maybe [ThreatIntelIndicator]))
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [ThreatIntelIndicator]
  [ThreatIntelIndicator]
  [ThreatIntelIndicator]
  [ThreatIntelIndicator]
-> Iso
     (Maybe [ThreatIntelIndicator])
     (Maybe [ThreatIntelIndicator])
     (Maybe [ThreatIntelIndicator])
     (Maybe [ThreatIntelIndicator])
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 AnIso
  [ThreatIntelIndicator]
  [ThreatIntelIndicator]
  [ThreatIntelIndicator]
  [ThreatIntelIndicator]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A URL that links to a page about the current finding in the
-- security-findings provider\'s solution.
awsSecurityFinding_sourceUrl :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Prelude.Text)
awsSecurityFinding_sourceUrl :: (Maybe Text -> f (Maybe Text))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_sourceUrl = (AwsSecurityFinding -> Maybe Text)
-> (AwsSecurityFinding -> Maybe Text -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Text
sourceUrl :: Maybe Text
$sel:sourceUrl:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
sourceUrl} -> Maybe Text
sourceUrl) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Text
a -> AwsSecurityFinding
s {$sel:sourceUrl:AwsSecurityFinding' :: Maybe Text
sourceUrl = Maybe Text
a} :: AwsSecurityFinding)

-- | Indicates when the security-findings provider most recently observed the
-- potential security issue that a finding captured.
--
-- Uses the @date-time@ format specified in
-- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
-- The value cannot contain spaces. For example,
-- @2020-03-22T13:22:13.933Z@.
awsSecurityFinding_lastObservedAt :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe Prelude.Text)
awsSecurityFinding_lastObservedAt :: (Maybe Text -> f (Maybe Text))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_lastObservedAt = (AwsSecurityFinding -> Maybe Text)
-> (AwsSecurityFinding -> Maybe Text -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding AwsSecurityFinding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe Text
lastObservedAt :: Maybe Text
$sel:lastObservedAt:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
lastObservedAt} -> Maybe Text
lastObservedAt) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe Text
a -> AwsSecurityFinding
s {$sel:lastObservedAt:AwsSecurityFinding' :: Maybe Text
lastObservedAt = Maybe Text
a} :: AwsSecurityFinding)

-- | A list of name\/value string pairs associated with the finding. These
-- are custom, user-defined fields added to a finding.
awsSecurityFinding_userDefinedFields :: Lens.Lens' AwsSecurityFinding (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
awsSecurityFinding_userDefinedFields :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_userDefinedFields = (AwsSecurityFinding -> Maybe (HashMap Text Text))
-> (AwsSecurityFinding
    -> Maybe (HashMap Text Text) -> AwsSecurityFinding)
-> Lens
     AwsSecurityFinding
     AwsSecurityFinding
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Maybe (HashMap Text Text)
userDefinedFields :: Maybe (HashMap Text Text)
$sel:userDefinedFields:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe (HashMap Text Text)
userDefinedFields} -> Maybe (HashMap Text Text)
userDefinedFields) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Maybe (HashMap Text Text)
a -> AwsSecurityFinding
s {$sel:userDefinedFields:AwsSecurityFinding' :: Maybe (HashMap Text Text)
userDefinedFields = Maybe (HashMap Text Text)
a} :: AwsSecurityFinding) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
    -> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
-> Iso
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
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 AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The schema version that a finding is formatted for.
awsSecurityFinding_schemaVersion :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_schemaVersion :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_schemaVersion = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
schemaVersion :: Text
$sel:schemaVersion:AwsSecurityFinding' :: AwsSecurityFinding -> Text
schemaVersion} -> Text
schemaVersion) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:schemaVersion:AwsSecurityFinding' :: Text
schemaVersion = Text
a} :: AwsSecurityFinding)

-- | The security findings provider-specific identifier for a finding.
awsSecurityFinding_id :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_id :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_id = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
id :: Text
$sel:id:AwsSecurityFinding' :: AwsSecurityFinding -> Text
id} -> Text
id) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:id:AwsSecurityFinding' :: Text
id = Text
a} :: AwsSecurityFinding)

-- | The ARN generated by Security Hub that uniquely identifies a product
-- that generates findings. This can be the ARN for a third-party product
-- that is integrated with Security Hub, or the ARN for a custom
-- integration.
awsSecurityFinding_productArn :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_productArn :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_productArn = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
productArn :: Text
$sel:productArn:AwsSecurityFinding' :: AwsSecurityFinding -> Text
productArn} -> Text
productArn) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:productArn:AwsSecurityFinding' :: Text
productArn = Text
a} :: AwsSecurityFinding)

-- | The identifier for the solution-specific component (a discrete unit of
-- logic) that generated a finding. In various security-findings
-- providers\' solutions, this generator can be called a rule, a check, a
-- detector, a plugin, etc.
awsSecurityFinding_generatorId :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_generatorId :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_generatorId = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
generatorId :: Text
$sel:generatorId:AwsSecurityFinding' :: AwsSecurityFinding -> Text
generatorId} -> Text
generatorId) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:generatorId:AwsSecurityFinding' :: Text
generatorId = Text
a} :: AwsSecurityFinding)

-- | The Amazon Web Services account ID that a finding is generated in.
awsSecurityFinding_awsAccountId :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_awsAccountId :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_awsAccountId = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
awsAccountId :: Text
$sel:awsAccountId:AwsSecurityFinding' :: AwsSecurityFinding -> Text
awsAccountId} -> Text
awsAccountId) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:awsAccountId:AwsSecurityFinding' :: Text
awsAccountId = Text
a} :: AwsSecurityFinding)

-- | Indicates when the security-findings provider created the potential
-- security issue that a finding captured.
--
-- Uses the @date-time@ format specified in
-- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
-- The value cannot contain spaces. For example,
-- @2020-03-22T13:22:13.933Z@.
awsSecurityFinding_createdAt :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_createdAt :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_createdAt = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
createdAt :: Text
$sel:createdAt:AwsSecurityFinding' :: AwsSecurityFinding -> Text
createdAt} -> Text
createdAt) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:createdAt:AwsSecurityFinding' :: Text
createdAt = Text
a} :: AwsSecurityFinding)

-- | Indicates when the security-findings provider last updated the finding
-- record.
--
-- Uses the @date-time@ format specified in
-- <https://tools.ietf.org/html/rfc3339#section-5.6 RFC 3339 section 5.6, Internet Date\/Time Format>.
-- The value cannot contain spaces. For example,
-- @2020-03-22T13:22:13.933Z@.
awsSecurityFinding_updatedAt :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_updatedAt :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_updatedAt = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
updatedAt :: Text
$sel:updatedAt:AwsSecurityFinding' :: AwsSecurityFinding -> Text
updatedAt} -> Text
updatedAt) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:updatedAt:AwsSecurityFinding' :: Text
updatedAt = Text
a} :: AwsSecurityFinding)

-- | A finding\'s title.
--
-- In this release, @Title@ is a required property.
awsSecurityFinding_title :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_title :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_title = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
title :: Text
$sel:title:AwsSecurityFinding' :: AwsSecurityFinding -> Text
title} -> Text
title) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:title:AwsSecurityFinding' :: Text
title = Text
a} :: AwsSecurityFinding)

-- | A finding\'s description.
--
-- In this release, @Description@ is a required property.
awsSecurityFinding_description :: Lens.Lens' AwsSecurityFinding Prelude.Text
awsSecurityFinding_description :: (Text -> f Text) -> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_description = (AwsSecurityFinding -> Text)
-> (AwsSecurityFinding -> Text -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {Text
description :: Text
$sel:description:AwsSecurityFinding' :: AwsSecurityFinding -> Text
description} -> Text
description) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} Text
a -> AwsSecurityFinding
s {$sel:description:AwsSecurityFinding' :: Text
description = Text
a} :: AwsSecurityFinding)

-- | A set of resource data types that describe the resources that the
-- finding refers to.
awsSecurityFinding_resources :: Lens.Lens' AwsSecurityFinding [Resource]
awsSecurityFinding_resources :: ([Resource] -> f [Resource])
-> AwsSecurityFinding -> f AwsSecurityFinding
awsSecurityFinding_resources = (AwsSecurityFinding -> [Resource])
-> (AwsSecurityFinding -> [Resource] -> AwsSecurityFinding)
-> Lens AwsSecurityFinding AwsSecurityFinding [Resource] [Resource]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSecurityFinding' {[Resource]
resources :: [Resource]
$sel:resources:AwsSecurityFinding' :: AwsSecurityFinding -> [Resource]
resources} -> [Resource]
resources) (\s :: AwsSecurityFinding
s@AwsSecurityFinding' {} [Resource]
a -> AwsSecurityFinding
s {$sel:resources:AwsSecurityFinding' :: [Resource]
resources = [Resource]
a} :: AwsSecurityFinding) (([Resource] -> f [Resource])
 -> AwsSecurityFinding -> f AwsSecurityFinding)
-> (([Resource] -> f [Resource]) -> [Resource] -> f [Resource])
-> ([Resource] -> f [Resource])
-> AwsSecurityFinding
-> f AwsSecurityFinding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([Resource] -> f [Resource]) -> [Resource] -> f [Resource]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

instance Core.FromJSON AwsSecurityFinding where
  parseJSON :: Value -> Parser AwsSecurityFinding
parseJSON =
    String
-> (Object -> Parser AwsSecurityFinding)
-> Value
-> Parser AwsSecurityFinding
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"AwsSecurityFinding"
      ( \Object
x ->
          Maybe Text
-> Maybe WorkflowState
-> Maybe Int
-> Maybe RecordState
-> Maybe (HashMap Text Text)
-> Maybe Compliance
-> Maybe FindingProviderFields
-> Maybe Text
-> Maybe Note
-> Maybe ProcessDetails
-> Maybe Severity
-> Maybe [Text]
-> Maybe Action
-> Maybe Network
-> Maybe [RelatedFinding]
-> Maybe Text
-> Maybe [Malware]
-> Maybe Int
-> Maybe Remediation
-> Maybe PatchSummary
-> Maybe [Vulnerability]
-> Maybe Text
-> Maybe [NetworkPathComponent]
-> Maybe Workflow
-> Maybe VerificationState
-> Maybe [ThreatIntelIndicator]
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> Text
-> [Resource]
-> AwsSecurityFinding
AwsSecurityFinding'
            (Maybe Text
 -> Maybe WorkflowState
 -> Maybe Int
 -> Maybe RecordState
 -> Maybe (HashMap Text Text)
 -> Maybe Compliance
 -> Maybe FindingProviderFields
 -> Maybe Text
 -> Maybe Note
 -> Maybe ProcessDetails
 -> Maybe Severity
 -> Maybe [Text]
 -> Maybe Action
 -> Maybe Network
 -> Maybe [RelatedFinding]
 -> Maybe Text
 -> Maybe [Malware]
 -> Maybe Int
 -> Maybe Remediation
 -> Maybe PatchSummary
 -> Maybe [Vulnerability]
 -> Maybe Text
 -> Maybe [NetworkPathComponent]
 -> Maybe Workflow
 -> Maybe VerificationState
 -> Maybe [ThreatIntelIndicator]
 -> Maybe Text
 -> Maybe Text
 -> Maybe (HashMap Text Text)
 -> Text
 -> Text
 -> Text
 -> Text
 -> Text
 -> Text
 -> Text
 -> Text
 -> Text
 -> [Resource]
 -> AwsSecurityFinding)
-> Parser (Maybe Text)
-> Parser
     (Maybe WorkflowState
      -> Maybe Int
      -> Maybe RecordState
      -> Maybe (HashMap Text Text)
      -> Maybe Compliance
      -> Maybe FindingProviderFields
      -> Maybe Text
      -> Maybe Note
      -> Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ProductName")
            Parser
  (Maybe WorkflowState
   -> Maybe Int
   -> Maybe RecordState
   -> Maybe (HashMap Text Text)
   -> Maybe Compliance
   -> Maybe FindingProviderFields
   -> Maybe Text
   -> Maybe Note
   -> Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe WorkflowState)
-> Parser
     (Maybe Int
      -> Maybe RecordState
      -> Maybe (HashMap Text Text)
      -> Maybe Compliance
      -> Maybe FindingProviderFields
      -> Maybe Text
      -> Maybe Note
      -> Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe WorkflowState)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"WorkflowState")
            Parser
  (Maybe Int
   -> Maybe RecordState
   -> Maybe (HashMap Text Text)
   -> Maybe Compliance
   -> Maybe FindingProviderFields
   -> Maybe Text
   -> Maybe Note
   -> Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Int)
-> Parser
     (Maybe RecordState
      -> Maybe (HashMap Text Text)
      -> Maybe Compliance
      -> Maybe FindingProviderFields
      -> Maybe Text
      -> Maybe Note
      -> Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Criticality")
            Parser
  (Maybe RecordState
   -> Maybe (HashMap Text Text)
   -> Maybe Compliance
   -> Maybe FindingProviderFields
   -> Maybe Text
   -> Maybe Note
   -> Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe RecordState)
-> Parser
     (Maybe (HashMap Text Text)
      -> Maybe Compliance
      -> Maybe FindingProviderFields
      -> Maybe Text
      -> Maybe Note
      -> Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe RecordState)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RecordState")
            Parser
  (Maybe (HashMap Text Text)
   -> Maybe Compliance
   -> Maybe FindingProviderFields
   -> Maybe Text
   -> Maybe Note
   -> Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe (HashMap Text Text))
-> Parser
     (Maybe Compliance
      -> Maybe FindingProviderFields
      -> Maybe Text
      -> Maybe Note
      -> Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ProductFields" Parser (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> Parser (Maybe (HashMap Text Text))
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty)
            Parser
  (Maybe Compliance
   -> Maybe FindingProviderFields
   -> Maybe Text
   -> Maybe Note
   -> Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Compliance)
-> Parser
     (Maybe FindingProviderFields
      -> Maybe Text
      -> Maybe Note
      -> Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Compliance)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Compliance")
            Parser
  (Maybe FindingProviderFields
   -> Maybe Text
   -> Maybe Note
   -> Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe FindingProviderFields)
-> Parser
     (Maybe Text
      -> Maybe Note
      -> Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe FindingProviderFields)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"FindingProviderFields")
            Parser
  (Maybe Text
   -> Maybe Note
   -> Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Text)
-> Parser
     (Maybe Note
      -> Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompanyName")
            Parser
  (Maybe Note
   -> Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Note)
-> Parser
     (Maybe ProcessDetails
      -> Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Note)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Note")
            Parser
  (Maybe ProcessDetails
   -> Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe ProcessDetails)
-> Parser
     (Maybe Severity
      -> Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ProcessDetails)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Process")
            Parser
  (Maybe Severity
   -> Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Severity)
-> Parser
     (Maybe [Text]
      -> Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Severity)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Severity")
            Parser
  (Maybe [Text]
   -> Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe [Text])
-> Parser
     (Maybe Action
      -> Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Types" Parser (Maybe (Maybe [Text]))
-> Maybe [Text] -> Parser (Maybe [Text])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
            Parser
  (Maybe Action
   -> Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Action)
-> Parser
     (Maybe Network
      -> Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Action)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Action")
            Parser
  (Maybe Network
   -> Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Network)
-> Parser
     (Maybe [RelatedFinding]
      -> Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Network)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Network")
            Parser
  (Maybe [RelatedFinding]
   -> Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe [RelatedFinding])
-> Parser
     (Maybe Text
      -> Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Parser (Maybe (Maybe [RelatedFinding]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RelatedFindings"
                            Parser (Maybe (Maybe [RelatedFinding]))
-> Maybe [RelatedFinding] -> Parser (Maybe [RelatedFinding])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [RelatedFinding]
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Maybe Text
   -> Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Text)
-> Parser
     (Maybe [Malware]
      -> Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"FirstObservedAt")
            Parser
  (Maybe [Malware]
   -> Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe [Malware])
-> Parser
     (Maybe Int
      -> Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Malware]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Malware" Parser (Maybe (Maybe [Malware]))
-> Maybe [Malware] -> Parser (Maybe [Malware])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Malware]
forall a. Monoid a => a
Prelude.mempty)
            Parser
  (Maybe Int
   -> Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Int)
-> Parser
     (Maybe Remediation
      -> Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Confidence")
            Parser
  (Maybe Remediation
   -> Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Remediation)
-> Parser
     (Maybe PatchSummary
      -> Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Remediation)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Remediation")
            Parser
  (Maybe PatchSummary
   -> Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe PatchSummary)
-> Parser
     (Maybe [Vulnerability]
      -> Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe PatchSummary)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"PatchSummary")
            Parser
  (Maybe [Vulnerability]
   -> Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe [Vulnerability])
-> Parser
     (Maybe Text
      -> Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Parser (Maybe (Maybe [Vulnerability]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Vulnerabilities"
                            Parser (Maybe (Maybe [Vulnerability]))
-> Maybe [Vulnerability] -> Parser (Maybe [Vulnerability])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Vulnerability]
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Maybe Text
   -> Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Text)
-> Parser
     (Maybe [NetworkPathComponent]
      -> Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Region")
            Parser
  (Maybe [NetworkPathComponent]
   -> Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe [NetworkPathComponent])
-> Parser
     (Maybe Workflow
      -> Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [NetworkPathComponent]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NetworkPath" Parser (Maybe (Maybe [NetworkPathComponent]))
-> Maybe [NetworkPathComponent]
-> Parser (Maybe [NetworkPathComponent])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [NetworkPathComponent]
forall a. Monoid a => a
Prelude.mempty)
            Parser
  (Maybe Workflow
   -> Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Workflow)
-> Parser
     (Maybe VerificationState
      -> Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Workflow)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Workflow")
            Parser
  (Maybe VerificationState
   -> Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe VerificationState)
-> Parser
     (Maybe [ThreatIntelIndicator]
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe VerificationState)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"VerificationState")
            Parser
  (Maybe [ThreatIntelIndicator]
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe [ThreatIntelIndicator])
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Parser (Maybe (Maybe [ThreatIntelIndicator]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ThreatIntelIndicators"
                            Parser (Maybe (Maybe [ThreatIntelIndicator]))
-> Maybe [ThreatIntelIndicator]
-> Parser (Maybe [ThreatIntelIndicator])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [ThreatIntelIndicator]
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"SourceUrl")
            Parser
  (Maybe Text
   -> Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe Text)
-> Parser
     (Maybe (HashMap Text Text)
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LastObservedAt")
            Parser
  (Maybe (HashMap Text Text)
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser (Maybe (HashMap Text Text))
-> Parser
     (Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Parser (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"UserDefinedFields"
                            Parser (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> Parser (Maybe (HashMap Text Text))
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser Text
-> Parser
     (Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"SchemaVersion")
            Parser
  (Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser Text
-> Parser
     (Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"Id")
            Parser
  (Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser Text
-> Parser
     (Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"ProductArn")
            Parser
  (Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser Text
-> Parser
     (Text
      -> Text
      -> Text
      -> Text
      -> Text
      -> [Resource]
      -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"GeneratorId")
            Parser
  (Text
   -> Text
   -> Text
   -> Text
   -> Text
   -> [Resource]
   -> AwsSecurityFinding)
-> Parser Text
-> Parser
     (Text -> Text -> Text -> Text -> [Resource] -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"AwsAccountId")
            Parser
  (Text -> Text -> Text -> Text -> [Resource] -> AwsSecurityFinding)
-> Parser Text
-> Parser
     (Text -> Text -> Text -> [Resource] -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"CreatedAt")
            Parser (Text -> Text -> Text -> [Resource] -> AwsSecurityFinding)
-> Parser Text
-> Parser (Text -> Text -> [Resource] -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"UpdatedAt")
            Parser (Text -> Text -> [Resource] -> AwsSecurityFinding)
-> Parser Text -> Parser (Text -> [Resource] -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"Title")
            Parser (Text -> [Resource] -> AwsSecurityFinding)
-> Parser Text -> Parser ([Resource] -> AwsSecurityFinding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"Description")
            Parser ([Resource] -> AwsSecurityFinding)
-> Parser [Resource] -> Parser AwsSecurityFinding
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe [Resource])
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Resources" Parser (Maybe [Resource]) -> [Resource] -> Parser [Resource]
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= [Resource]
forall a. Monoid a => a
Prelude.mempty)
      )

instance Prelude.Hashable AwsSecurityFinding

instance Prelude.NFData AwsSecurityFinding

instance Core.ToJSON AwsSecurityFinding where
  toJSON :: AwsSecurityFinding -> Value
toJSON AwsSecurityFinding' {[Resource]
Maybe Int
Maybe [Text]
Maybe [Malware]
Maybe [NetworkPathComponent]
Maybe [RelatedFinding]
Maybe [ThreatIntelIndicator]
Maybe [Vulnerability]
Maybe Text
Maybe (HashMap Text Text)
Maybe Note
Maybe PatchSummary
Maybe Action
Maybe Network
Maybe ProcessDetails
Maybe RecordState
Maybe Remediation
Maybe Severity
Maybe FindingProviderFields
Maybe Compliance
Maybe VerificationState
Maybe WorkflowState
Maybe Workflow
Text
resources :: [Resource]
description :: Text
title :: Text
updatedAt :: Text
createdAt :: Text
awsAccountId :: Text
generatorId :: Text
productArn :: Text
id :: Text
schemaVersion :: Text
userDefinedFields :: Maybe (HashMap Text Text)
lastObservedAt :: Maybe Text
sourceUrl :: Maybe Text
threatIntelIndicators :: Maybe [ThreatIntelIndicator]
verificationState :: Maybe VerificationState
workflow :: Maybe Workflow
networkPath :: Maybe [NetworkPathComponent]
region :: Maybe Text
vulnerabilities :: Maybe [Vulnerability]
patchSummary :: Maybe PatchSummary
remediation :: Maybe Remediation
confidence :: Maybe Int
malware :: Maybe [Malware]
firstObservedAt :: Maybe Text
relatedFindings :: Maybe [RelatedFinding]
network :: Maybe Network
action :: Maybe Action
types :: Maybe [Text]
severity :: Maybe Severity
process :: Maybe ProcessDetails
note :: Maybe Note
companyName :: Maybe Text
findingProviderFields :: Maybe FindingProviderFields
compliance :: Maybe Compliance
productFields :: Maybe (HashMap Text Text)
recordState :: Maybe RecordState
criticality :: Maybe Int
workflowState :: Maybe WorkflowState
productName :: Maybe Text
$sel:resources:AwsSecurityFinding' :: AwsSecurityFinding -> [Resource]
$sel:description:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:title:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:updatedAt:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:createdAt:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:awsAccountId:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:generatorId:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:productArn:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:id:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:schemaVersion:AwsSecurityFinding' :: AwsSecurityFinding -> Text
$sel:userDefinedFields:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe (HashMap Text Text)
$sel:lastObservedAt:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
$sel:sourceUrl:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
$sel:threatIntelIndicators:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [ThreatIntelIndicator]
$sel:verificationState:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe VerificationState
$sel:workflow:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Workflow
$sel:networkPath:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [NetworkPathComponent]
$sel:region:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
$sel:vulnerabilities:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [Vulnerability]
$sel:patchSummary:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe PatchSummary
$sel:remediation:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Remediation
$sel:confidence:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Int
$sel:malware:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [Malware]
$sel:firstObservedAt:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
$sel:relatedFindings:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [RelatedFinding]
$sel:network:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Network
$sel:action:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Action
$sel:types:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe [Text]
$sel:severity:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Severity
$sel:process:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe ProcessDetails
$sel:note:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Note
$sel:companyName:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
$sel:findingProviderFields:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe FindingProviderFields
$sel:compliance:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Compliance
$sel:productFields:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe (HashMap Text Text)
$sel:recordState:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe RecordState
$sel:criticality:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Int
$sel:workflowState:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe WorkflowState
$sel:productName:AwsSecurityFinding' :: AwsSecurityFinding -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"ProductName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
productName,
            (Text
"WorkflowState" Text -> WorkflowState -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (WorkflowState -> Pair) -> Maybe WorkflowState -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe WorkflowState
workflowState,
            (Text
"Criticality" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
criticality,
            (Text
"RecordState" Text -> RecordState -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (RecordState -> Pair) -> Maybe RecordState -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe RecordState
recordState,
            (Text
"ProductFields" Text -> HashMap Text Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (HashMap Text Text -> Pair)
-> Maybe (HashMap Text Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
productFields,
            (Text
"Compliance" Text -> Compliance -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Compliance -> Pair) -> Maybe Compliance -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Compliance
compliance,
            (Text
"FindingProviderFields" Text -> FindingProviderFields -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (FindingProviderFields -> Pair)
-> Maybe FindingProviderFields -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe FindingProviderFields
findingProviderFields,
            (Text
"CompanyName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
companyName,
            (Text
"Note" Text -> Note -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Note -> Pair) -> Maybe Note -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Note
note,
            (Text
"Process" Text -> ProcessDetails -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (ProcessDetails -> Pair) -> Maybe ProcessDetails -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ProcessDetails
process,
            (Text
"Severity" Text -> Severity -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Severity -> Pair) -> Maybe Severity -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Severity
severity,
            (Text
"Types" Text -> [Text] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Text] -> Pair) -> Maybe [Text] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
types,
            (Text
"Action" Text -> Action -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Action -> Pair) -> Maybe Action -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Action
action,
            (Text
"Network" Text -> Network -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Network -> Pair) -> Maybe Network -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Network
network,
            (Text
"RelatedFindings" Text -> [RelatedFinding] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([RelatedFinding] -> Pair) -> Maybe [RelatedFinding] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [RelatedFinding]
relatedFindings,
            (Text
"FirstObservedAt" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
firstObservedAt,
            (Text
"Malware" Text -> [Malware] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Malware] -> Pair) -> Maybe [Malware] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Malware]
malware,
            (Text
"Confidence" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
confidence,
            (Text
"Remediation" Text -> Remediation -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Remediation -> Pair) -> Maybe Remediation -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Remediation
remediation,
            (Text
"PatchSummary" Text -> PatchSummary -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (PatchSummary -> Pair) -> Maybe PatchSummary -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe PatchSummary
patchSummary,
            (Text
"Vulnerabilities" Text -> [Vulnerability] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([Vulnerability] -> Pair) -> Maybe [Vulnerability] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Vulnerability]
vulnerabilities,
            (Text
"Region" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
region,
            (Text
"NetworkPath" Text -> [NetworkPathComponent] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([NetworkPathComponent] -> Pair)
-> Maybe [NetworkPathComponent] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [NetworkPathComponent]
networkPath,
            (Text
"Workflow" Text -> Workflow -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Workflow -> Pair) -> Maybe Workflow -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Workflow
workflow,
            (Text
"VerificationState" Text -> VerificationState -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (VerificationState -> Pair)
-> Maybe VerificationState -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe VerificationState
verificationState,
            (Text
"ThreatIntelIndicators" Text -> [ThreatIntelIndicator] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([ThreatIntelIndicator] -> Pair)
-> Maybe [ThreatIntelIndicator] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [ThreatIntelIndicator]
threatIntelIndicators,
            (Text
"SourceUrl" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
sourceUrl,
            (Text
"LastObservedAt" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
lastObservedAt,
            (Text
"UserDefinedFields" Text -> HashMap Text Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (HashMap Text Text -> Pair)
-> Maybe (HashMap Text Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
userDefinedFields,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"SchemaVersion" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
schemaVersion),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Id" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
id),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"ProductArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
productArn),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"GeneratorId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
generatorId),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"AwsAccountId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
awsAccountId),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"CreatedAt" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
createdAt),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"UpdatedAt" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
updatedAt),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Title" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
title),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Description" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
description),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Resources" Text -> [Resource] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= [Resource]
resources)
          ]
      )