<?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>Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/111003/connecting-to-azure-iot-hub-fails-at-device-certificates</link><description>We&amp;#39;re trying to connect to our Azure Iot Hub using the Azure Iot Hub library provided by Nrf Connect Sdk 2.6.0 (without DPS). We&amp;#39;re currently using the evaluation board to test this. The error we get once we try to connect using the azure_iot_hub sample</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 22 May 2024 12:22:09 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/111003/connecting-to-azure-iot-hub-fails-at-device-certificates" /><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/485404?ContentTypeID=1</link><pubDate>Wed, 22 May 2024 12:22:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:772f66c8-4885-4e4a-8f6c-2251ace92e9d</guid><dc:creator>Byter</dc:creator><description>&lt;p&gt;I got it working. What I did was follow&amp;nbsp;&lt;a href="https://learn.microsoft.com/en-us/azure/iot-hub/tutorial-x509-test-certs?tabs=windows"&gt;this&lt;/a&gt;&amp;nbsp;tutorial from Microsoft again but this time, instead of using the device id (CN) like the tutorial from Nordic, I used device##. This means that the evaluation board is able to connect using certificates but following the official tutorial from Nordic didn&amp;#39;t work. My guess is that the issue is with the CN, that nrfcredstore uses by default is invalid in some sort of way. In case it&amp;#39;s different than the usual, for me it was something like: #####-####-########-### (not exact number of #&amp;#39;s) that instead of # there was a letter or a number. And somehow this string was either invalid as a CN or as a device name for Azure Iot Hub. Whatever it was, it&amp;#39;s working now so this issue can be marked as resolved&lt;br /&gt;&lt;br /&gt;P.S. There&amp;#39;s always the chance that I did something wrong each time I tried but the last time&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/484875?ContentTypeID=1</link><pubDate>Sun, 19 May 2024 07:26:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:21eea65d-8cbb-4355-a11c-e20a8296e82b</guid><dc:creator>Byter</dc:creator><description>&lt;p&gt;I&amp;#39;ll try. Right now I don&amp;#39;t have access to the azure support from my account because of where we created it from. So you&amp;#39;re saying that you don&amp;#39;t see anything abnormal with the terminal session and in general?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/483223?ContentTypeID=1</link><pubDate>Tue, 14 May 2024 11:06:08 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6bfe91c8-2c78-497a-902e-8482ad6151eb</guid><dc:creator>Hakon</dc:creator><description>[quote user="Byter"]Is there some azure iot hub configuration that I should share?[/quote]
&lt;p&gt;I don&amp;#39;t know. Have you tried contacting Azure support team? Perhaps they have more insight into what is going on.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/482903?ContentTypeID=1</link><pubDate>Sun, 12 May 2024 09:25:50 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:538712d6-904a-42db-9fd7-89df6cb744e9</guid><dc:creator>Byter</dc:creator><description>&lt;p&gt;&lt;img style="max-height:240px;max-width:320px;" alt=" " src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1715505753853v1.png" /&gt;&lt;/p&gt;
&lt;p&gt;I&amp;#39;m not proficient with the TLS handshake but by reading a few articles it seems like it finishes the handshake and only after it fails. Unless I&amp;#39;m understanding it incorrectly.&lt;/p&gt;
&lt;p&gt;EDIT: I&amp;#39;ve now found that &amp;quot;Encrypted Alert&amp;quot; means &amp;quot;Decryption Failed&amp;quot; so I&amp;#39;m digging more into that&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Okay so that&amp;#39;s indeed an issue with the certificates. The issue is figuring where it went wrong because I followed the docs a couple of times already. Is there some azure iot hub configuration that I should share?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/482786?ContentTypeID=1</link><pubDate>Fri, 10 May 2024 12:12:36 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c1c2d410-e903-4456-9495-fd405d724181</guid><dc:creator>Hakon</dc:creator><description>&lt;p&gt;Then maybe if you did a modem trace that would indicate what&amp;#39;s wrong.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/482776?ContentTypeID=1</link><pubDate>Fri, 10 May 2024 11:28:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:58c2ef05-8b65-49fa-8fb0-a9fb169dce6f</guid><dc:creator>Byter</dc:creator><description>&lt;p&gt;&lt;img style="max-height:240px;max-width:320px;" src="https://devzone.nordicsemi.com/resized-image/__size/640x480/__key/communityserver-discussions-components-files/4/pastedimage1715340516255v1.png" alt=" " /&gt;&lt;br /&gt;The certificates have been indeed written into the modem&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/482773?ContentTypeID=1</link><pubDate>Fri, 10 May 2024 11:20:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f62251fc-debf-4d71-882a-c63eab68dd42</guid><dc:creator>Hakon</dc:creator><description>&lt;p&gt;You can use the command to read out the certificates, so you know that they have been written to the modem.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/482772?ContentTypeID=1</link><pubDate>Fri, 10 May 2024 11:15:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:abceef02-eacc-4f74-93d1-bf9d7868d61c</guid><dc:creator>Byter</dc:creator><description>&lt;p&gt;Hey, I meant using the nrfcredstore method from the documentation. Meaning I wrote the certificates that were generated from the cmd tool.&lt;/p&gt;
&lt;p&gt;Unless nrfcredstore uses the at%cmng command behind the scenes of nrfcredstore COM3 list, I haven&amp;#39;t tried it&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Connecting to Azure Iot Hub fails at device certificates</title><link>https://devzone.nordicsemi.com/thread/482746?ContentTypeID=1</link><pubDate>Fri, 10 May 2024 09:05:41 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0fdeae8e-c45d-4034-9d40-699111c5e197</guid><dc:creator>Hakon</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
[quote user=""]Use nrfcredstore to add the certificates to the device[/quote]
&lt;p&gt;What certificates did you write to the modem? Have you tried reading them out with &lt;a href="https://infocenter.nordicsemi.com/topic/ref_at_commands_nrf91x1/REF/at_commands/security/cmng_set.html"&gt;at%cmng&lt;/a&gt;?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>