<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>TLS handshake fails with Alert (Level: Fatal, Description: Unknown CA):</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/119396/tls-handshake-fails-with-alert-level-fatal-description-unknown-ca</link><description>It seems I cannot post a full explanation of context so here is the short version. Ill add detail after. 
 Devices in field all suddenly unable to connect to GCP host. 
 Problem simplified to https_client sample with url changed to run.app and certificate</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 27 Feb 2025 15:11:16 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/119396/tls-handshake-fails-with-alert-level-fatal-description-unknown-ca" /><item><title>RE: TLS handshake fails with Alert (Level: Fatal, Description: Unknown CA):</title><link>https://devzone.nordicsemi.com/thread/525111?ContentTypeID=1</link><pubDate>Thu, 27 Feb 2025 15:11:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:addb90d0-e852-4abc-8154-d7168fb05096</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I downloaded wr2.pem from here:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://pki.goog/repository/"&gt;https://pki.goog/repository/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Did a quickfix to avoid changing main.c:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;diff --git a/samples/net/https_client/CMakeLists.txt b/samples/net/https_client/CMakeLists.txt
index 2a937786ed..975b511569 100644
--- a/samples/net/https_client/CMakeLists.txt
+++ b/samples/net/https_client/CMakeLists.txt
@@ -14,7 +14,7 @@ set(gen_dir ${CMAKE_CURRENT_BINARY_DIR}/certs)
 zephyr_include_directories(${gen_dir})
 generate_inc_file_for_target(
     app
-    cert/DigiCertGlobalG2.pem
+    cert/wr2.pem
     ${gen_dir}/DigiCertGlobalG2.pem.inc
     )
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;and set CONFIG_HTTPS_HOSTNAME=&amp;quot;run.app&amp;quot;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Here&amp;#39;s the output:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;*** Using Zephyr OS v3.7.99-1f8f3dc29142 ***
HTTPS client sample started
Bringing network interface up
[00:00:00.536,163] &amp;lt;inf&amp;gt; nrf_modem_lib_trace: Trace thread ready
[00:00:00.543,640] &amp;lt;inf&amp;gt; nrf_modem_lib_trace: Trace level override: 2
Provisioning certificate
Certificate match
Connecting to the network
+CEREG: 2,&amp;quot;8169&amp;quot;,&amp;quot;014ACE00&amp;quot;,7
+CSCON: 1
+CSCON: 0
+CSCON: 1
+CGEV: ME PDN ACT 0
%MDMEV: SEARCH STATUS 2
+CEREG: 1,&amp;quot;8169&amp;quot;,&amp;quot;014ACE00&amp;quot;,7,,,&amp;quot;00001010&amp;quot;,&amp;quot;11000001&amp;quot;
Network connectivity established and IP address assigned
Looking up run.app
+CGEV: IPV6 0
Resolved 216.239.32.53 (AF_INET)
Connecting to run.app:443
Sent 57 bytes
Received 207 bytes

&amp;gt;        HTTP/1.1 404 Not Found

Finished, closing socket.
+CGEV: ME PDN DEACT 0
+CEREG: 0
+CGEV: ME DETACH
+CSCON: 0
Network connectivity lost
Disconnected from the network&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;And pcapng:&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/341496_5F00_.pcapng"&gt;devzone.nordicsemi.com/.../341496_5F00_.pcapng&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Q1: What mfw are you using?&lt;/p&gt;
&lt;p&gt;&lt;span style="text-decoration:line-through;"&gt;Q2: Have you checked that the wr2.pem is updated on your end?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Your comment indicate that you use the latest.&lt;/p&gt;
&lt;p&gt;Q3: Could you add a top-level root CA to another tag in addition? wr2 is a intermediate cert.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TLS handshake fails with Alert (Level: Fatal, Description: Unknown CA):</title><link>https://devzone.nordicsemi.com/thread/525071?ContentTypeID=1</link><pubDate>Thu, 27 Feb 2025 13:39:32 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:340f4b03-4122-4a92-a1d2-a5b81603f91e</guid><dc:creator>SST</dc:creator><description>&lt;p&gt;Here is the curl line:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;curl -v --tlsv1.2 --ciphers ECDHE-ECDSA-AES128-GCM-SHA256 --cacert wr2.pem --request POST --data &amp;#39;test&amp;#39; https://run.app/
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;The certificate is here (It seems I cannot attach it):&lt;/p&gt;
&lt;p&gt;&lt;a href="https://i.pki.goog/wr2.pem"&gt;https://i.pki.goog/wr2.pem&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: TLS handshake fails with Alert (Level: Fatal, Description: Unknown CA):</title><link>https://devzone.nordicsemi.com/thread/525069?ContentTypeID=1</link><pubDate>Thu, 27 Feb 2025 13:30:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:896b9dd8-c5ce-436e-943b-643539a7ed2a</guid><dc:creator>SST</dc:creator><description>&lt;p&gt;Here is the capture:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/sterile_2D00_with_2D00_wr2.pcapng"&gt;devzone.nordicsemi.com/.../sterile_2D00_with_2D00_wr2.pcapng&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>