<?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>Encryption in nrf52840, hardware or software?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/108380/encryption-in-nrf52840-hardware-or-software</link><description>Hello my friends, I was reading the nrf52840 documentation regarding the encryption. I have realized there are two specifications which point to the fact that there are dedicated pieces of hardware for encyrption/dycrption goals 
 
 
 ARM TrustZone Cryptocell</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 20 Feb 2024 17:52:28 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/108380/encryption-in-nrf52840-hardware-or-software" /><item><title>RE: Encryption in nrf52840, hardware or software?</title><link>https://devzone.nordicsemi.com/thread/469892?ContentTypeID=1</link><pubDate>Tue, 20 Feb 2024 17:52:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b8a7c4b7-0411-4585-9c52-13f48ceabe75</guid><dc:creator>Amanda Hsieh</dc:creator><description>[quote user="BlueLogic"]is literally a hardware computation core separate from the CPU. Is the correct?[/quote]
&lt;p&gt;Yes.&lt;/p&gt;
[quote user="BlueLogic"]If so, then if all the encryption/decryption tasks are done through this computation core[/quote]
&lt;p&gt;Not all, only&amp;nbsp;&lt;span&gt;the encryption/decryption are supported by the AES.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
[quote user="BlueLogic"]Could you please tell if these examples use ECB peripheral?[/quote]
&lt;p&gt;Those examples demonstrate the e&lt;span&gt;ncryption and decryption of a sample plaintext without using E&lt;/span&gt;CB.&lt;/p&gt;
[quote user="BlueLogic"]If not, how they can perform chrytographic task while being detached from the radio?[/quote]
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;See&lt;a title="Encrypting packets on-the-fly in radio transmit mode" href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/ccm.html?cp=5_0_0_5_3_4#unique_564620595"&gt;&lt;br /&gt;Encrypting packets on-the-fly in radio transmit mode&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;a title="Decrypting packets on-the-fly in RADIO receive mode" href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/ccm.html?cp=5_0_0_5_3_5#unique_1970371299"&gt;Decrypting packets on-the-fly in rado receive mode&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;Just note that ECB peripheral can only be accessed through the Softdevice controller API if you use BLE:&amp;nbsp;&lt;/span&gt;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrfxlib/softdevice_controller/doc/api.html#c.sdc_soc_ecb_block_encrypt"&gt;https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrfxlib/softdevice_controller/doc/api.html#c.sdc_soc_ecb_block_encrypt&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;-Amanda H.&lt;/span&gt;&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Encryption in nrf52840, hardware or software?</title><link>https://devzone.nordicsemi.com/thread/469640?ContentTypeID=1</link><pubDate>Mon, 19 Feb 2024 21:33:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3d54e8ff-b532-41f0-85e4-48f3cae923df</guid><dc:creator>Omid</dc:creator><description>&lt;p&gt;Thanks for the answer, but I feel like I do not receive the answer to my questions completely. Could you answer to the following&amp;nbsp;original questions of mine?&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
[quote userid="127459" url="~/f/nordic-q-a/108380/encryption-in-nrf52840-hardware-or-software"]is literally a hardware computation core separate from the CPU. Is the correct?[/quote]
&lt;p&gt;&lt;/p&gt;
[quote userid="127459" url="~/f/nordic-q-a/108380/encryption-in-nrf52840-hardware-or-software"]If so, then if all the encryption/decryption tasks are done through this computation core[/quote]
&lt;p&gt;&lt;/p&gt;
[quote userid="127459" url="~/f/nordic-q-a/108380/encryption-in-nrf52840-hardware-or-software"]Could you please tell if these examples use ECB peripheral?[/quote]
&lt;p&gt;&lt;/p&gt;
[quote userid="127459" url="~/f/nordic-q-a/108380/encryption-in-nrf52840-hardware-or-software"]If not, how they can perform chrytographic task while being detached from the radio?[/quote]
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Encryption in nrf52840, hardware or software?</title><link>https://devzone.nordicsemi.com/thread/469635?ContentTypeID=1</link><pubDate>Mon, 19 Feb 2024 20:09:34 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c0622c05-d483-4806-9fd9-6e608bd5fa6e</guid><dc:creator>Amanda Hsieh</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
[quote user=""]what here is meant by &amp;quot;AES-Core&amp;quot; is literally a hardware computation core separate from the CPU. Is the correct?[/quote]
&lt;p&gt;The &lt;span&gt;AES-Core means the&amp;nbsp;&lt;/span&gt;General-purpose AES engine in the&amp;nbsp;&lt;a href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/cryptocell.html?cp=5_0_0_5_5"&gt;CRYPTOCELL — ARM TrustZone CryptoCell 310&lt;/a&gt;.&amp;nbsp;&amp;nbsp;&lt;/p&gt;
[quote user=""]If so, then if all the encryption/decryption tasks are done through this computation core and using the easyDMA?[/quote]
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The&amp;nbsp;&lt;/span&gt;&lt;a title="EasyDMA and ERROR event" href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/ccm.html?cp=5_0_0_5_3_7#unique_914074177"&gt;CCM&lt;/a&gt;&amp;nbsp;and &lt;a title="EasyDMA" href="https://infocenter.nordicsemi.com/topic/ps_nrf52840/ecb.html?cp=5_0_0_5_6_1#concept_sxc_541_lr"&gt;ECB&lt;/a&gt;&amp;nbsp;&lt;span&gt;implement an EasyDMA mechanism for reading and writing to the Data RAM.&lt;/span&gt;&lt;/p&gt;
[quote user=""]&lt;span&gt;Is there any encryption/decryption done in software using the CPU instead of using the AES core?&lt;br /&gt;&lt;br /&gt;If there is also the cpu-based&amp;nbsp;&lt;/span&gt;cryptography then how does that compare in terms of energy consumption and computation speed with respect to the AES-based chryptography?&amp;nbsp;[/quote]
&lt;p&gt;There is no sample such as your requirement, but I think you could implement by yourself.&amp;nbsp;&lt;/p&gt;
[quote user=""]Could you please tell if these examples use ECB peripheral? If not, how they can perform chrytographic task while being detached from the radio?[/quote]
&lt;p&gt;&lt;span dir="ltr"&gt;Example usage of ECB peripheral:&lt;br /&gt;1)&amp;nbsp;&lt;a title="https://github.com/nrfconnect/sdk-zephyr/blob/main/subsys/bluetooth/controller/ll_sw/nordic/hal/nrf5/ecb.c" href="https://github.com/nrfconnect/sdk-zephyr/blob/main/subsys/bluetooth/controller/ll_sw/nordic/hal/nrf5/ecb.c" rel="noopener noreferrer" target="_blank"&gt;https://github.com/nrfconnect/sdk-zephyr/blob/main/subsys/bluetooth/controller/ll_sw/nordic/hal/nrf5/ecb.c&lt;br /&gt;&lt;/a&gt;2)&amp;nbsp;&lt;a title="https://github.com/nrfconnect/sdk-zephyr/blob/main/drivers/crypto/crypto_nrf_ecb.c" href="https://github.com/nrfconnect/sdk-zephyr/blob/main/drivers/crypto/crypto_nrf_ecb.c" rel="noopener noreferrer" target="_blank"&gt;https://github.com/nrfconnect/sdk-zephyr/blob/main/drivers/crypto/crypto_nrf_ecb.c&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Regards,&lt;br /&gt;Amanda H.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>