<?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>nRF9160DK Keccak256 ECDSA SAMPLE</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/91565/nrf9160dk-keccak256-ecdsa-sample</link><description>Hello! We are trying to sign our data using ECDSA ( https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/samples/crypto/ecdsa/README.html ) , so we can send our information to an Ethereum Blockchain. The problem is that we don&amp;#39;t have the algorithm</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 05 Sep 2022 13:05:31 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/91565/nrf9160dk-keccak256-ecdsa-sample" /><item><title>RE: nRF9160DK Keccak256 ECDSA SAMPLE</title><link>https://devzone.nordicsemi.com/thread/384592?ContentTypeID=1</link><pubDate>Mon, 05 Sep 2022 13:05:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:28471735-b46e-4e35-a938-d0cfd58a5fae</guid><dc:creator>Gioele</dc:creator><description>&lt;p&gt;Okay, let&amp;#39;s talk in the other case discussing!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160DK Keccak256 ECDSA SAMPLE</title><link>https://devzone.nordicsemi.com/thread/384579?ContentTypeID=1</link><pubDate>Mon, 05 Sep 2022 12:39:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d38478e5-6127-49a4-b84b-5f56c9e2ce92</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;I can see you already have an open case discussing the same, I suggest to continue there:&lt;br /&gt;&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/91484/nrf9160-dk-ethereum-ecdsa-s-problem"&gt;nRF9160 DK Ethereum Ecdsa &amp;quot;s problem&amp;quot;&lt;/a&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160DK Keccak256 ECDSA SAMPLE</title><link>https://devzone.nordicsemi.com/thread/384527?ContentTypeID=1</link><pubDate>Mon, 05 Sep 2022 10:04:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:62dc9535-cd75-424c-963b-34e8ba5e25a5</guid><dc:creator>Gioele</dc:creator><description>&lt;p&gt;We understood that the Keccack256 function is not supported we implemented third party library but we noticed that for some values the ECDSA result is wrong related to the &amp;quot;s value&amp;quot;.&lt;br /&gt;We noticed that when we make the Keccak256 of a standard number or a text the &amp;quot;r and s values&amp;quot; are correct, but when we make the keccack256 of RLP only the &amp;quot;r value&amp;quot; is correct.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160DK Keccak256 ECDSA SAMPLE</title><link>https://devzone.nordicsemi.com/thread/384500?ContentTypeID=1</link><pubDate>Mon, 05 Sep 2022 08:00:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:35c71cca-229c-4898-b021-ecb8db9b4e66</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;You can find an overview of the crypto samples and tests supported in our nRF Connect SDK here:&lt;br /&gt;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/tests/crypto/README.html"&gt;https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/tests/crypto/README.html&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;If it&amp;#39;s not listed there you will need to implement third party library and check their documentation on test and usage.&lt;/p&gt;
&lt;p&gt;Kenneth&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160DK Keccak256 ECDSA SAMPLE</title><link>https://devzone.nordicsemi.com/thread/384426?ContentTypeID=1</link><pubDate>Fri, 02 Sep 2022 13:56:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:361ac8e9-8bf9-4615-809b-0a6ceba72f44</guid><dc:creator>Gioele</dc:creator><description>&lt;p&gt;We are doing exactly this. We are sure that the keccak256 is correct in hex but the final result is not correct (the &amp;quot;s value&amp;quot;)&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nRF9160DK Keccak256 ECDSA SAMPLE</title><link>https://devzone.nordicsemi.com/thread/384383?ContentTypeID=1</link><pubDate>Thu, 01 Sep 2022 22:02:20 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ffead9a5-d711-4e17-bd73-839f4bd8f27b</guid><dc:creator>Emil Lenngren</dc:creator><description>&lt;p&gt;You can use any external library for calculating Keccak-256. A quick search gave me this:&amp;nbsp;&lt;a id="" href="https://github.com/firefly/wallet/blob/master/source/libs/ethers/src/keccak256.c"&gt;https://github.com/firefly/wallet/blob/master/source/libs/ethers/src/keccak256.c&lt;/a&gt;. That replaces psa_hash_compute.&lt;/p&gt;
&lt;p&gt;You should be able to keep the psa_sign_hash call as it is. In contrary to RSA which includes the hash aglorithm used as part of the signature, this is not done in ECDSA. So you should be able to pass&amp;nbsp;PSA_ALG_DETERMINISTIC_ECDSA(PSA_ALG_SHA_256) there without any issues.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>