From e4866563dedda10047c51747232c2d85fa346be2 Mon Sep 17 00:00:00 2001
From: Daniel Stenberg <daniel@haxx.se>
Date: Sun, 13 Jan 2002 11:32:36 +0000
Subject: [PATCH] =?UTF-8?q?G=F6tz=20Babin-Ebell=20updated=20with=20some=20?=
 =?UTF-8?q?new=207.9.3=20features?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 docs/examples/simplessl.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/docs/examples/simplessl.c b/docs/examples/simplessl.c
index 534fac849a..285d0cd373 100644
--- a/docs/examples/simplessl.c
+++ b/docs/examples/simplessl.c
@@ -37,6 +37,7 @@ int main(int argc, char **argv)
   FILE *headerfile;
 
   const char *pCertFile = "testcert.pem";
+  const char *pCACertFile="cacert.pem"
 
   const char *pKeyName;
   const char *pKeyType;
@@ -96,6 +97,10 @@ int main(int argc, char **argv)
        curl_easy_setopt(curl,CURLOPT_SSLKEYTYPE,pKeyType);
                                 /* set the private key (file or ID in engine) */
        curl_easy_setopt(curl,CURLOPT_SSLKEY,pKeyName);
+                                /* set the file with the certs vaildating the server */
+       curl_easy_setopt(curl,CURLOPT_CAINFO,pCACertFile);
+                                /* disconnect if we can't validate server's cert */
+       curl_easy_setopt(curl,CURLOPT_SSL_VERIFYPEER,1);
        
        res = curl_easy_perform(curl);
        break;                   /* we are done... */
-- 
GitLab