{-# 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.SSM.Types.Patch
-- 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.SSM.Types.Patch where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Represents metadata about a patch.
--
-- /See:/ 'newPatch' smart constructor.
data Patch = Patch'
  { -- | The Bugzilla ID of the patch. For example, @1600646@. Applies to
    -- Linux-based instances only.
    Patch -> Maybe [Text]
bugzillaIds :: Prelude.Maybe [Prelude.Text],
    -- | The name of the vendor providing the patch.
    Patch -> Maybe Text
vendor :: Prelude.Maybe Prelude.Text,
    -- | The severity of the patch, such as @Critical@, @Important@, or
    -- @Moderate@. Applies to Windows patches only.
    Patch -> Maybe Text
msrcSeverity :: Prelude.Maybe Prelude.Text,
    -- | The source patch repository for the operating system and version, such
    -- as @trusty-security@ for Ubuntu Server 14.04 LTE and @focal-security@
    -- for Ubuntu Server 20.04 LTE. Applies to Linux-based instances only.
    Patch -> Maybe Text
repository :: Prelude.Maybe Prelude.Text,
    -- | The product family the patch is applicable for. For example, @Windows@
    -- or @Amazon Linux 2@.
    Patch -> Maybe Text
productFamily :: Prelude.Maybe Prelude.Text,
    -- | The severity level of the patch. For example, @CRITICAL@ or @MODERATE@.
    Patch -> Maybe Text
severity :: Prelude.Maybe Prelude.Text,
    -- | The Advisory ID of the patch. For example, @RHSA-2020:3779@. Applies to
    -- Linux-based instances only.
    Patch -> Maybe [Text]
advisoryIds :: Prelude.Maybe [Prelude.Text],
    -- | The Common Vulnerabilities and Exposures (CVE) ID of the patch. For
    -- example, @CVE-2011-3192@. Applies to Linux-based instances only.
    Patch -> Maybe [Text]
cVEIds :: Prelude.Maybe [Prelude.Text],
    -- | The classification of the patch. For example, @SecurityUpdates@,
    -- @Updates@, or @CriticalUpdates@.
    Patch -> Maybe Text
classification :: Prelude.Maybe Prelude.Text,
    -- | The particular release of a patch. For example, in
    -- @pkg-example-EE-20180914-2.2.amzn1.noarch@, the release is @2.amaz1@.
    -- Applies to Linux-based instances only.
    Patch -> Maybe Text
release :: Prelude.Maybe Prelude.Text,
    -- | The ID of the Microsoft Security Response Center (MSRC) bulletin the
    -- patch is related to. For example, @MS14-045@. Applies to Windows patches
    -- only.
    Patch -> Maybe Text
msrcNumber :: Prelude.Maybe Prelude.Text,
    -- | The name of the patch. Applies to Linux-based instances only.
    Patch -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | The version number of the patch. For example, in
    -- @example-pkg-1.710.10-2.7.abcd.x86_64@, the version number is indicated
    -- by @-1@. Applies to Linux-based instances only.
    Patch -> Maybe Text
version :: Prelude.Maybe Prelude.Text,
    -- | The language of the patch if it\'s language-specific.
    Patch -> Maybe Text
language :: Prelude.Maybe Prelude.Text,
    -- | The Microsoft Knowledge Base ID of the patch. Applies to Windows patches
    -- only.
    Patch -> Maybe Text
kbNumber :: Prelude.Maybe Prelude.Text,
    -- | The URL where more information can be obtained about the patch.
    Patch -> Maybe Text
contentUrl :: Prelude.Maybe Prelude.Text,
    -- | The ID of the patch. Applies to Windows patches only.
    --
    -- This ID isn\'t the same as the Microsoft Knowledge Base ID.
    Patch -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
    -- | The date the patch was released.
    Patch -> Maybe POSIX
releaseDate :: Prelude.Maybe Core.POSIX,
    -- | The title of the patch.
    Patch -> Maybe Text
title :: Prelude.Maybe Prelude.Text,
    -- | The architecture of the patch. For example, in
    -- @example-pkg-0.710.10-2.7.abcd.x86_64@, the architecture is indicated by
    -- @x86_64@. Applies to Linux-based instances only.
    Patch -> Maybe Text
arch :: Prelude.Maybe Prelude.Text,
    -- | The specific product the patch is applicable for. For example,
    -- @WindowsServer2016@ or @AmazonLinux2018.03@.
    Patch -> Maybe Text
product :: Prelude.Maybe Prelude.Text,
    -- | The description of the patch.
    Patch -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | The epoch of the patch. For example in
    -- @pkg-example-EE-20180914-2.2.amzn1.noarch@, the epoch value is
    -- @20180914-2@. Applies to Linux-based instances only.
    Patch -> Maybe Int
epoch :: Prelude.Maybe Prelude.Int
  }
  deriving (Patch -> Patch -> Bool
(Patch -> Patch -> Bool) -> (Patch -> Patch -> Bool) -> Eq Patch
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Patch -> Patch -> Bool
$c/= :: Patch -> Patch -> Bool
== :: Patch -> Patch -> Bool
$c== :: Patch -> Patch -> Bool
Prelude.Eq, ReadPrec [Patch]
ReadPrec Patch
Int -> ReadS Patch
ReadS [Patch]
(Int -> ReadS Patch)
-> ReadS [Patch]
-> ReadPrec Patch
-> ReadPrec [Patch]
-> Read Patch
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Patch]
$creadListPrec :: ReadPrec [Patch]
readPrec :: ReadPrec Patch
$creadPrec :: ReadPrec Patch
readList :: ReadS [Patch]
$creadList :: ReadS [Patch]
readsPrec :: Int -> ReadS Patch
$creadsPrec :: Int -> ReadS Patch
Prelude.Read, Int -> Patch -> ShowS
[Patch] -> ShowS
Patch -> String
(Int -> Patch -> ShowS)
-> (Patch -> String) -> ([Patch] -> ShowS) -> Show Patch
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Patch] -> ShowS
$cshowList :: [Patch] -> ShowS
show :: Patch -> String
$cshow :: Patch -> String
showsPrec :: Int -> Patch -> ShowS
$cshowsPrec :: Int -> Patch -> ShowS
Prelude.Show, (forall x. Patch -> Rep Patch x)
-> (forall x. Rep Patch x -> Patch) -> Generic Patch
forall x. Rep Patch x -> Patch
forall x. Patch -> Rep Patch x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep Patch x -> Patch
$cfrom :: forall x. Patch -> Rep Patch x
Prelude.Generic)

-- |
-- Create a value of 'Patch' 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:
--
-- 'bugzillaIds', 'patch_bugzillaIds' - The Bugzilla ID of the patch. For example, @1600646@. Applies to
-- Linux-based instances only.
--
-- 'vendor', 'patch_vendor' - The name of the vendor providing the patch.
--
-- 'msrcSeverity', 'patch_msrcSeverity' - The severity of the patch, such as @Critical@, @Important@, or
-- @Moderate@. Applies to Windows patches only.
--
-- 'repository', 'patch_repository' - The source patch repository for the operating system and version, such
-- as @trusty-security@ for Ubuntu Server 14.04 LTE and @focal-security@
-- for Ubuntu Server 20.04 LTE. Applies to Linux-based instances only.
--
-- 'productFamily', 'patch_productFamily' - The product family the patch is applicable for. For example, @Windows@
-- or @Amazon Linux 2@.
--
-- 'severity', 'patch_severity' - The severity level of the patch. For example, @CRITICAL@ or @MODERATE@.
--
-- 'advisoryIds', 'patch_advisoryIds' - The Advisory ID of the patch. For example, @RHSA-2020:3779@. Applies to
-- Linux-based instances only.
--
-- 'cVEIds', 'patch_cVEIds' - The Common Vulnerabilities and Exposures (CVE) ID of the patch. For
-- example, @CVE-2011-3192@. Applies to Linux-based instances only.
--
-- 'classification', 'patch_classification' - The classification of the patch. For example, @SecurityUpdates@,
-- @Updates@, or @CriticalUpdates@.
--
-- 'release', 'patch_release' - The particular release of a patch. For example, in
-- @pkg-example-EE-20180914-2.2.amzn1.noarch@, the release is @2.amaz1@.
-- Applies to Linux-based instances only.
--
-- 'msrcNumber', 'patch_msrcNumber' - The ID of the Microsoft Security Response Center (MSRC) bulletin the
-- patch is related to. For example, @MS14-045@. Applies to Windows patches
-- only.
--
-- 'name', 'patch_name' - The name of the patch. Applies to Linux-based instances only.
--
-- 'version', 'patch_version' - The version number of the patch. For example, in
-- @example-pkg-1.710.10-2.7.abcd.x86_64@, the version number is indicated
-- by @-1@. Applies to Linux-based instances only.
--
-- 'language', 'patch_language' - The language of the patch if it\'s language-specific.
--
-- 'kbNumber', 'patch_kbNumber' - The Microsoft Knowledge Base ID of the patch. Applies to Windows patches
-- only.
--
-- 'contentUrl', 'patch_contentUrl' - The URL where more information can be obtained about the patch.
--
-- 'id', 'patch_id' - The ID of the patch. Applies to Windows patches only.
--
-- This ID isn\'t the same as the Microsoft Knowledge Base ID.
--
-- 'releaseDate', 'patch_releaseDate' - The date the patch was released.
--
-- 'title', 'patch_title' - The title of the patch.
--
-- 'arch', 'patch_arch' - The architecture of the patch. For example, in
-- @example-pkg-0.710.10-2.7.abcd.x86_64@, the architecture is indicated by
-- @x86_64@. Applies to Linux-based instances only.
--
-- 'product', 'patch_product' - The specific product the patch is applicable for. For example,
-- @WindowsServer2016@ or @AmazonLinux2018.03@.
--
-- 'description', 'patch_description' - The description of the patch.
--
-- 'epoch', 'patch_epoch' - The epoch of the patch. For example in
-- @pkg-example-EE-20180914-2.2.amzn1.noarch@, the epoch value is
-- @20180914-2@. Applies to Linux-based instances only.
newPatch ::
  Patch
newPatch :: Patch
newPatch =
  Patch' :: Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Patch
Patch'
    { $sel:bugzillaIds:Patch' :: Maybe [Text]
bugzillaIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:vendor:Patch' :: Maybe Text
vendor = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:msrcSeverity:Patch' :: Maybe Text
msrcSeverity = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:repository:Patch' :: Maybe Text
repository = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:productFamily:Patch' :: Maybe Text
productFamily = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:severity:Patch' :: Maybe Text
severity = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:advisoryIds:Patch' :: Maybe [Text]
advisoryIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:cVEIds:Patch' :: Maybe [Text]
cVEIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:classification:Patch' :: Maybe Text
classification = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:release:Patch' :: Maybe Text
release = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:msrcNumber:Patch' :: Maybe Text
msrcNumber = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:name:Patch' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:version:Patch' :: Maybe Text
version = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:language:Patch' :: Maybe Text
language = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:kbNumber:Patch' :: Maybe Text
kbNumber = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:contentUrl:Patch' :: Maybe Text
contentUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:id:Patch' :: Maybe Text
id = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:releaseDate:Patch' :: Maybe POSIX
releaseDate = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:title:Patch' :: Maybe Text
title = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:arch:Patch' :: Maybe Text
arch = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:product:Patch' :: Maybe Text
product = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:description:Patch' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:epoch:Patch' :: Maybe Int
epoch = Maybe Int
forall a. Maybe a
Prelude.Nothing
    }

-- | The Bugzilla ID of the patch. For example, @1600646@. Applies to
-- Linux-based instances only.
patch_bugzillaIds :: Lens.Lens' Patch (Prelude.Maybe [Prelude.Text])
patch_bugzillaIds :: (Maybe [Text] -> f (Maybe [Text])) -> Patch -> f Patch
patch_bugzillaIds = (Patch -> Maybe [Text])
-> (Patch -> Maybe [Text] -> Patch)
-> Lens Patch Patch (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe [Text]
bugzillaIds :: Maybe [Text]
$sel:bugzillaIds:Patch' :: Patch -> Maybe [Text]
bugzillaIds} -> Maybe [Text]
bugzillaIds) (\s :: Patch
s@Patch' {} Maybe [Text]
a -> Patch
s {$sel:bugzillaIds:Patch' :: Maybe [Text]
bugzillaIds = Maybe [Text]
a} :: Patch) ((Maybe [Text] -> f (Maybe [Text])) -> Patch -> f Patch)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> Patch
-> f Patch
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

-- | The name of the vendor providing the patch.
patch_vendor :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_vendor :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_vendor = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
vendor :: Maybe Text
$sel:vendor:Patch' :: Patch -> Maybe Text
vendor} -> Maybe Text
vendor) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:vendor:Patch' :: Maybe Text
vendor = Maybe Text
a} :: Patch)

-- | The severity of the patch, such as @Critical@, @Important@, or
-- @Moderate@. Applies to Windows patches only.
patch_msrcSeverity :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_msrcSeverity :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_msrcSeverity = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
msrcSeverity :: Maybe Text
$sel:msrcSeverity:Patch' :: Patch -> Maybe Text
msrcSeverity} -> Maybe Text
msrcSeverity) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:msrcSeverity:Patch' :: Maybe Text
msrcSeverity = Maybe Text
a} :: Patch)

-- | The source patch repository for the operating system and version, such
-- as @trusty-security@ for Ubuntu Server 14.04 LTE and @focal-security@
-- for Ubuntu Server 20.04 LTE. Applies to Linux-based instances only.
patch_repository :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_repository :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_repository = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
repository :: Maybe Text
$sel:repository:Patch' :: Patch -> Maybe Text
repository} -> Maybe Text
repository) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:repository:Patch' :: Maybe Text
repository = Maybe Text
a} :: Patch)

-- | The product family the patch is applicable for. For example, @Windows@
-- or @Amazon Linux 2@.
patch_productFamily :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_productFamily :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_productFamily = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
productFamily :: Maybe Text
$sel:productFamily:Patch' :: Patch -> Maybe Text
productFamily} -> Maybe Text
productFamily) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:productFamily:Patch' :: Maybe Text
productFamily = Maybe Text
a} :: Patch)

-- | The severity level of the patch. For example, @CRITICAL@ or @MODERATE@.
patch_severity :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_severity :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_severity = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
severity :: Maybe Text
$sel:severity:Patch' :: Patch -> Maybe Text
severity} -> Maybe Text
severity) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:severity:Patch' :: Maybe Text
severity = Maybe Text
a} :: Patch)

-- | The Advisory ID of the patch. For example, @RHSA-2020:3779@. Applies to
-- Linux-based instances only.
patch_advisoryIds :: Lens.Lens' Patch (Prelude.Maybe [Prelude.Text])
patch_advisoryIds :: (Maybe [Text] -> f (Maybe [Text])) -> Patch -> f Patch
patch_advisoryIds = (Patch -> Maybe [Text])
-> (Patch -> Maybe [Text] -> Patch)
-> Lens Patch Patch (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe [Text]
advisoryIds :: Maybe [Text]
$sel:advisoryIds:Patch' :: Patch -> Maybe [Text]
advisoryIds} -> Maybe [Text]
advisoryIds) (\s :: Patch
s@Patch' {} Maybe [Text]
a -> Patch
s {$sel:advisoryIds:Patch' :: Maybe [Text]
advisoryIds = Maybe [Text]
a} :: Patch) ((Maybe [Text] -> f (Maybe [Text])) -> Patch -> f Patch)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> Patch
-> f Patch
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

-- | The Common Vulnerabilities and Exposures (CVE) ID of the patch. For
-- example, @CVE-2011-3192@. Applies to Linux-based instances only.
patch_cVEIds :: Lens.Lens' Patch (Prelude.Maybe [Prelude.Text])
patch_cVEIds :: (Maybe [Text] -> f (Maybe [Text])) -> Patch -> f Patch
patch_cVEIds = (Patch -> Maybe [Text])
-> (Patch -> Maybe [Text] -> Patch)
-> Lens Patch Patch (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe [Text]
cVEIds :: Maybe [Text]
$sel:cVEIds:Patch' :: Patch -> Maybe [Text]
cVEIds} -> Maybe [Text]
cVEIds) (\s :: Patch
s@Patch' {} Maybe [Text]
a -> Patch
s {$sel:cVEIds:Patch' :: Maybe [Text]
cVEIds = Maybe [Text]
a} :: Patch) ((Maybe [Text] -> f (Maybe [Text])) -> Patch -> f Patch)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> Patch
-> f Patch
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

-- | The classification of the patch. For example, @SecurityUpdates@,
-- @Updates@, or @CriticalUpdates@.
patch_classification :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_classification :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_classification = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
classification :: Maybe Text
$sel:classification:Patch' :: Patch -> Maybe Text
classification} -> Maybe Text
classification) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:classification:Patch' :: Maybe Text
classification = Maybe Text
a} :: Patch)

-- | The particular release of a patch. For example, in
-- @pkg-example-EE-20180914-2.2.amzn1.noarch@, the release is @2.amaz1@.
-- Applies to Linux-based instances only.
patch_release :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_release :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_release = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
release :: Maybe Text
$sel:release:Patch' :: Patch -> Maybe Text
release} -> Maybe Text
release) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:release:Patch' :: Maybe Text
release = Maybe Text
a} :: Patch)

-- | The ID of the Microsoft Security Response Center (MSRC) bulletin the
-- patch is related to. For example, @MS14-045@. Applies to Windows patches
-- only.
patch_msrcNumber :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_msrcNumber :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_msrcNumber = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
msrcNumber :: Maybe Text
$sel:msrcNumber:Patch' :: Patch -> Maybe Text
msrcNumber} -> Maybe Text
msrcNumber) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:msrcNumber:Patch' :: Maybe Text
msrcNumber = Maybe Text
a} :: Patch)

-- | The name of the patch. Applies to Linux-based instances only.
patch_name :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_name :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_name = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
name :: Maybe Text
$sel:name:Patch' :: Patch -> Maybe Text
name} -> Maybe Text
name) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:name:Patch' :: Maybe Text
name = Maybe Text
a} :: Patch)

-- | The version number of the patch. For example, in
-- @example-pkg-1.710.10-2.7.abcd.x86_64@, the version number is indicated
-- by @-1@. Applies to Linux-based instances only.
patch_version :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_version :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_version = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
version :: Maybe Text
$sel:version:Patch' :: Patch -> Maybe Text
version} -> Maybe Text
version) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:version:Patch' :: Maybe Text
version = Maybe Text
a} :: Patch)

-- | The language of the patch if it\'s language-specific.
patch_language :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_language :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_language = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
language :: Maybe Text
$sel:language:Patch' :: Patch -> Maybe Text
language} -> Maybe Text
language) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:language:Patch' :: Maybe Text
language = Maybe Text
a} :: Patch)

-- | The Microsoft Knowledge Base ID of the patch. Applies to Windows patches
-- only.
patch_kbNumber :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_kbNumber :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_kbNumber = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
kbNumber :: Maybe Text
$sel:kbNumber:Patch' :: Patch -> Maybe Text
kbNumber} -> Maybe Text
kbNumber) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:kbNumber:Patch' :: Maybe Text
kbNumber = Maybe Text
a} :: Patch)

-- | The URL where more information can be obtained about the patch.
patch_contentUrl :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_contentUrl :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_contentUrl = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
contentUrl :: Maybe Text
$sel:contentUrl:Patch' :: Patch -> Maybe Text
contentUrl} -> Maybe Text
contentUrl) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:contentUrl:Patch' :: Maybe Text
contentUrl = Maybe Text
a} :: Patch)

-- | The ID of the patch. Applies to Windows patches only.
--
-- This ID isn\'t the same as the Microsoft Knowledge Base ID.
patch_id :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_id :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_id = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
id :: Maybe Text
$sel:id:Patch' :: Patch -> Maybe Text
id} -> Maybe Text
id) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:id:Patch' :: Maybe Text
id = Maybe Text
a} :: Patch)

-- | The date the patch was released.
patch_releaseDate :: Lens.Lens' Patch (Prelude.Maybe Prelude.UTCTime)
patch_releaseDate :: (Maybe UTCTime -> f (Maybe UTCTime)) -> Patch -> f Patch
patch_releaseDate = (Patch -> Maybe POSIX)
-> (Patch -> Maybe POSIX -> Patch)
-> Lens Patch Patch (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe POSIX
releaseDate :: Maybe POSIX
$sel:releaseDate:Patch' :: Patch -> Maybe POSIX
releaseDate} -> Maybe POSIX
releaseDate) (\s :: Patch
s@Patch' {} Maybe POSIX
a -> Patch
s {$sel:releaseDate:Patch' :: Maybe POSIX
releaseDate = Maybe POSIX
a} :: Patch) ((Maybe POSIX -> f (Maybe POSIX)) -> Patch -> f Patch)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> Patch
-> f Patch
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | The title of the patch.
patch_title :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_title :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_title = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
title :: Maybe Text
$sel:title:Patch' :: Patch -> Maybe Text
title} -> Maybe Text
title) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:title:Patch' :: Maybe Text
title = Maybe Text
a} :: Patch)

-- | The architecture of the patch. For example, in
-- @example-pkg-0.710.10-2.7.abcd.x86_64@, the architecture is indicated by
-- @x86_64@. Applies to Linux-based instances only.
patch_arch :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_arch :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_arch = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
arch :: Maybe Text
$sel:arch:Patch' :: Patch -> Maybe Text
arch} -> Maybe Text
arch) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:arch:Patch' :: Maybe Text
arch = Maybe Text
a} :: Patch)

-- | The specific product the patch is applicable for. For example,
-- @WindowsServer2016@ or @AmazonLinux2018.03@.
patch_product :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_product :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_product = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
product :: Maybe Text
$sel:product:Patch' :: Patch -> Maybe Text
product} -> Maybe Text
product) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:product:Patch' :: Maybe Text
product = Maybe Text
a} :: Patch)

-- | The description of the patch.
patch_description :: Lens.Lens' Patch (Prelude.Maybe Prelude.Text)
patch_description :: (Maybe Text -> f (Maybe Text)) -> Patch -> f Patch
patch_description = (Patch -> Maybe Text)
-> (Patch -> Maybe Text -> Patch)
-> Lens Patch Patch (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Text
description :: Maybe Text
$sel:description:Patch' :: Patch -> Maybe Text
description} -> Maybe Text
description) (\s :: Patch
s@Patch' {} Maybe Text
a -> Patch
s {$sel:description:Patch' :: Maybe Text
description = Maybe Text
a} :: Patch)

-- | The epoch of the patch. For example in
-- @pkg-example-EE-20180914-2.2.amzn1.noarch@, the epoch value is
-- @20180914-2@. Applies to Linux-based instances only.
patch_epoch :: Lens.Lens' Patch (Prelude.Maybe Prelude.Int)
patch_epoch :: (Maybe Int -> f (Maybe Int)) -> Patch -> f Patch
patch_epoch = (Patch -> Maybe Int)
-> (Patch -> Maybe Int -> Patch)
-> Lens Patch Patch (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Patch' {Maybe Int
epoch :: Maybe Int
$sel:epoch:Patch' :: Patch -> Maybe Int
epoch} -> Maybe Int
epoch) (\s :: Patch
s@Patch' {} Maybe Int
a -> Patch
s {$sel:epoch:Patch' :: Maybe Int
epoch = Maybe Int
a} :: Patch)

instance Core.FromJSON Patch where
  parseJSON :: Value -> Parser Patch
parseJSON =
    String -> (Object -> Parser Patch) -> Value -> Parser Patch
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"Patch"
      ( \Object
x ->
          Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Patch
Patch'
            (Maybe [Text]
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe [Text]
 -> Maybe [Text]
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe POSIX
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Int
 -> Patch)
-> Parser (Maybe [Text])
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
forall (f :: * -> *) a b. Functor 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
"BugzillaIds" 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 Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Vendor")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"MsrcSeverity")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe [Text]
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Repository")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe [Text]
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe [Text]
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"ProductFamily")
            Parser
  (Maybe Text
   -> Maybe [Text]
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe [Text]
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Severity")
            Parser
  (Maybe [Text]
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe [Text])
-> Parser
     (Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"AdvisoryIds" 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 [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe [Text])
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"CVEIds" 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 Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Classification")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Release")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"MsrcNumber")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Name")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Version")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Language")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"KbNumber")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"ContentUrl")
            Parser
  (Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Patch)
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
"Id")
            Parser
  (Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Patch)
-> Parser (Maybe POSIX)
-> Parser
     (Maybe Text
      -> Maybe Text -> Maybe Text -> Maybe Text -> Maybe Int -> Patch)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ReleaseDate")
            Parser
  (Maybe Text
   -> Maybe Text -> Maybe Text -> Maybe Text -> Maybe Int -> Patch)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text -> Maybe Text -> Maybe Text -> Maybe Int -> Patch)
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
"Title")
            Parser
  (Maybe Text -> Maybe Text -> Maybe Text -> Maybe Int -> Patch)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe Text -> Maybe Int -> Patch)
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
"Arch")
            Parser (Maybe Text -> Maybe Text -> Maybe Int -> Patch)
-> Parser (Maybe Text) -> Parser (Maybe Text -> Maybe Int -> Patch)
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
"Product")
            Parser (Maybe Text -> Maybe Int -> Patch)
-> Parser (Maybe Text) -> Parser (Maybe Int -> Patch)
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
"Description")
            Parser (Maybe Int -> Patch) -> Parser (Maybe Int) -> Parser Patch
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
"Epoch")
      )

instance Prelude.Hashable Patch

instance Prelude.NFData Patch