From 34775b4128de2801e4d127064f012501ca18d208 Mon Sep 17 00:00:00 2001 From: Cédric Couralet Date: Mon, 13 Apr 2020 23:58:42 +0200 Subject: Add an option to disable certificate validation (#6156) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit adds the option `--no-check-certificate`, which disables certificate checking when resources are fetched by HTTP. Co-authored-by: Cécile Chemin Co-authored-by: Juliette Fourcot --- src/Text/Pandoc/Class/CommonState.hs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/Text/Pandoc/Class/CommonState.hs') diff --git a/src/Text/Pandoc/Class/CommonState.hs b/src/Text/Pandoc/Class/CommonState.hs index 4a0f66859..7e1735c2b 100644 --- a/src/Text/Pandoc/Class/CommonState.hs +++ b/src/Text/Pandoc/Class/CommonState.hs @@ -37,6 +37,8 @@ data CommonState = CommonState -- ^ Absolute URL + dir of 1st source file , stRequestHeaders :: [(Text, Text)] -- ^ Headers to add for HTTP requests + , stNoCheckCertificate :: Bool + -- ^ Controls whether certificate validation is disabled , stMediaBag :: MediaBag -- ^ Media parsed from binary containers , stTranslations :: Maybe (Lang, Maybe Translations) @@ -67,6 +69,7 @@ defaultCommonState = CommonState , stUserDataDir = Nothing , stSourceURL = Nothing , stRequestHeaders = [] + , stNoCheckCertificate = False , stMediaBag = mempty , stTranslations = Nothing , stInputFiles = [] -- cgit v1.2.3