<?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>Need Help on Encryption in Beacon Advertising data</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/15578/need-help-on-encryption-in-beacon-advertising-data</link><description>Hi, 
 I want to transmit adv. data AES encrypted everytime. The Basic requirement is to do Encryption with Stream Cipher (Counter Mode) so i want to know when and where to do encryption everytime beacon transmits new frame in the Example code ( I have</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 08 Aug 2016 13:30:43 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/15578/need-help-on-encryption-in-beacon-advertising-data" /><item><title>RE: Need Help on Encryption in Beacon Advertising data</title><link>https://devzone.nordicsemi.com/thread/59439?ContentTypeID=1</link><pubDate>Mon, 08 Aug 2016 13:30:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:414b880a-a8e1-42fe-948a-77952d482cd2</guid><dc:creator>bjorn-spockeli</dc:creator><description>&lt;p&gt;Hi Spatel,&lt;/p&gt;
&lt;p&gt;I suggest that you take a look at &lt;a href="https://devzone.nordicsemi.com/blogs/721/intro-to-application-level-security-using-the-ecb-/"&gt;this&lt;/a&gt; blog post about using the ECB(Electronic CodeBook) peripheral to encrypt data.&lt;/p&gt;
&lt;p&gt;As for the where and when, you will have to encrypt the advertisment data(i.e. manuf_specific_data) before calling &lt;code&gt;ble_advdata_set()&lt;/code&gt;. Everytime you want to change the the data you will have to encrypt the new data and then call &lt;code&gt;ble_advdata_set()&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;-Bjørn&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>