<?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>BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/121067/ble-stack-loads-old-cccd-values-after-removing-bonds-on-client-side-and-reconnect</link><description>I&amp;#39;m testing BLE secure communication with the nRF52840DK device and I have encountered a problem with bonds. I use modified example from BLE fundamental course, in which I added ability to determine if we connected to new or bonded client. The following</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 12 May 2025 12:48:17 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/121067/ble-stack-loads-old-cccd-values-after-removing-bonds-on-client-side-and-reconnect" /><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/534899?ContentTypeID=1</link><pubDate>Mon, 12 May 2025 12:48:17 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:750c4c3e-d403-420a-8b49-ab307b6b91b8</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Biliy,&amp;nbsp;&lt;br /&gt;Actually you are right about overwriting bond. I was under the impression that it&amp;#39;s not possible but it&amp;#39;s actually is if the bond is higher level than level 2 (Just Work).&amp;nbsp;&lt;br /&gt;So only for Just work it&amp;#39;s disabled by default and can be enable with&amp;nbsp;&lt;span&gt;CONFIG_BT_SMP_ALLOW_UNAUTH_OVERWRITE. But for bonding with MITM it seems that re-bond is allowed.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;I will check internally to see if there is an option to disable that.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;Resetting the CCCD value after a new bond would be a good option. It&amp;#39;s the server that store the CCCD&amp;#39;s value, so the client either need to read the value of the CCCD to know if it should expect notification or reset it with a write.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/534791?ContentTypeID=1</link><pubDate>Mon, 12 May 2025 06:12:19 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:70d23f31-b473-42b8-a698-e1077c2b8593</guid><dc:creator>vitaliy2034</dc:creator><description>&lt;p data-start="884" data-end="939"&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Hi &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Emil,&lt;/span&gt;&lt;br data-start="892" data-end="895" /&gt; &lt;span class="_fadeIn_m1hgl_8"&gt;Thank &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;you &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;very &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;much &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;for &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;your &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;detailed &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;reply.&lt;/span&gt;&lt;/p&gt;
&lt;p data-start="941" data-end="1105"&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;For &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;testing, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;we &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;are &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;using &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;automated &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;scripts &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;that &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;control &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;a &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Nordic &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;dongle, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;which &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;has &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;been &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;flashed &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;with &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;a &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;modified &lt;/span&gt;&lt;strong&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;BLE &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Interactive &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Command &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Line &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Interface &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Example&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;.&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p data-start="1107" data-end="1258"&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;If &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;I &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;understand &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;you &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;correctly, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;there &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;is &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;currently &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;no &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;straightforward &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;solution &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;officially &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;recommended &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;by &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Bluetooth &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;SIG&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt; &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;for &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;this &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;particular &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;case.&lt;/span&gt;&lt;/p&gt;
&lt;p data-start="1260" data-end="1357"&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Could &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;you &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;also &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;please &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;confirm &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;if &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;I &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;have &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;correctly &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;understood &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;your &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;suggested &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;possible &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;solutions:&lt;/span&gt;&lt;/p&gt;
&lt;ol data-start="1358" data-end="1860"&gt;
&lt;li data-start="1358" data-end="1486"&gt;
&lt;p data-start="1361" data-end="1486"&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;The &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;client &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;should &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;ignore &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;any &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;unsolicited &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;indications/&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;notifications&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt; &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;from &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;peripheral &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;if &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;it &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;did &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;not &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;subscribe &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;to &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;them.&lt;/span&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li data-start="1487" data-end="1734"&gt;
&lt;p data-start="1490" data-end="1734"&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;If &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;peripheral &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;receives &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;a &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;pairing &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;request &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;from &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;central &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;while &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;a &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;bond &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;already &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;exists&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;and &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;requested &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;security &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;level &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;is &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;not &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;higher &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;than &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;existing &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;bond, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;peripheral &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;can &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;treat &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;this &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;as &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;a &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;new &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;bond&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt; &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;and &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;reset &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;all &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;relevant &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;data.&lt;/span&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li data-start="1735" data-end="1860"&gt;
&lt;p data-start="1738" data-end="1860"&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;As &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;an &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;alternative, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;both &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;devices &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;can &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;implement &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Bluetooth &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;BMS (&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Bond &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Management &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Service)&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt; &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;to &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;synchronize &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;bond &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;removal.&lt;/span&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p data-start="1862" data-end="2169"&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Additionally, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;I &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;have &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;a &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;clarification &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;question &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;regarding &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;option &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;2:&lt;/span&gt;&lt;br data-start="1927" data-end="1930" /&gt; &lt;span class="_fadeIn_m1hgl_8"&gt;If &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;a &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;new &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;bond &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;is &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;detected &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;in &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;this &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;way, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;should &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;application &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;explicitly &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;reset &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;CCCD &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;values &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;to &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;0x0000&lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt; &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;in &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;peripheral &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;firmware, &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;or &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;does &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Nordic &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;BLE &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;stack &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;automatically &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;handle &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;CCCD &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;reset &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;when &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;a &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;new &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;bond &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;replaces &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;the &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;old &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;one?&lt;/span&gt;&lt;/p&gt;
&lt;p data-start="2171" data-end="2219" data-is-last-node="" data-is-only-node=""&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;Thank &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;you &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;again &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;for &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;your &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;help &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;and &lt;/span&gt;&lt;span class="_fadeIn_m1hgl_8"&gt;clarification!&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/534788?ContentTypeID=1</link><pubDate>Mon, 12 May 2025 05:05:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f2fc2458-2508-427a-9114-83ecab84528f</guid><dc:creator>vitaliy2034</dc:creator><description>&lt;p&gt;Hi Hung,&lt;/p&gt;
&lt;p&gt;To perform a new pairing, I pressed the &amp;quot;Bond&amp;quot; button again in the nRF Connect app after reconnecting in step 5:&lt;/p&gt;
&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/pastedimage1747025888487v1.png" alt=" " /&gt;&lt;/p&gt;
&lt;p&gt;And after that, the pairing completes successfully:&lt;/p&gt;
&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/pastedimage1747025924901v3.png" alt=" " /&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/534253?ContentTypeID=1</link><pubDate>Wed, 07 May 2025 10:35:54 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8b8be105-3910-4447-bf97-9f80ce2e49de</guid><dc:creator>Emil Lenngren</dc:creator><description>&lt;p&gt;&amp;quot;&lt;span&gt;When this desynchronization occurs, the behavior becomes unpredictable. In my case, when connecting to a commercial device, this mismatch sometimes freezes the BLE stack, regardless of whether the connection is encrypted or not.&amp;quot;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;This doesn&amp;#39;t seem that good. What BLE stack do you have that it is this buggy? The BLE spec says in the same chapter, section&amp;nbsp;10.3.2.2, that &amp;quot;Any notifications received before the security requirements are met shall be ignored.&amp;quot;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;The BLE spec doesn&amp;#39;t seem to&amp;nbsp;discuss your particular case though. Per the BLE spec, it is theoretically possible that the client did not remove the bond but just wanted to upgrade the security level of its bond by sending a Pairing request, before encryption using the old LTK has been started (see flow chart figure 10.2 in the same chapter), right after the server sent a Peripheral Security Request with the intention to start encryption of the existing LTK rather than pairing. Unfortunately, it is impossible for the peripheral to distinguish between a new bond and an upgraded bond in case the new requested security level is higher than the old one. So, if a client receives unsolicited notifications, the most appropriate action seems to be to just ignore them. The client could also write 0x0000 to the CCCD an extra time in case it is unsynchronised.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;That said, if the peripheral receives a Pairing request from a central when a bond already exists, which does not request a higher security level than what is already present in the current bond, it can assume that it is a new bond. In particular, if the peripheral only allows pairing at the highest security level (LESC + MITM with 128-bit key) at all times, it can safely assume it is not an upgrade but a new bond. In that case (assuming the user, after confirmation, even allows a new bond in this case),&amp;nbsp;the peripheral&amp;nbsp;should reset all CCCDs to the default value (0x0000).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;In order to synchronise bond removal, you can use the&amp;nbsp;&lt;a id="" href="https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/libraries/bluetooth/services/bms.html"&gt;https://docs.nordicsemi.com/bundle/ncs-latest/page/nrf/libraries/bluetooth/services/bms.html&lt;/a&gt;&amp;nbsp;BMS standard service. But both sides need to implement it in order for it to be useful.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/534223?ContentTypeID=1</link><pubDate>Wed, 07 May 2025 08:09:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c90aa844-319c-4b59-8345-e4de0b943341</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Billy,&amp;nbsp;&lt;br /&gt;As far as I know Zephyr won&amp;#39;t allow a&amp;nbsp;re-pairing with the same central (unless you configured so, and only applied for Justwork).&amp;nbsp;&lt;/p&gt;
&lt;p&gt;As mentioned earlier, the way it should work in my opinion is that when the central deletes bond, the peripheral need to delete the bond to the same central as well. How the peripheral delete bond depend on the design choice, either having a physical button or having an encrypted command (proprietary) to erase bond.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;Could you describe how you did this &amp;quot;&lt;span&gt;&amp;nbsp;I reconnect&amp;nbsp; (as in step 5) and perform a new pairing and bonding additionally, the peripheral still attempts to send indications on value update,&amp;nbsp;&amp;quot; ?&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/534217?ContentTypeID=1</link><pubDate>Wed, 07 May 2025 07:52:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:03e8228c-fbf2-4ac3-9944-b4fe7fb3683f</guid><dc:creator>vitaliy2034</dc:creator><description>&lt;p&gt;Hi Hung and Emil, thank you both for the detailed responses, and apologies for the late reply.&lt;br /&gt;&lt;br /&gt;I completely agree that checking the security level before sending notifications or indications is a good safeguard. However, even when the required security level is enforced, the core issue of CCCD desynchronization between the peripheral and central still persists &amp;mdash; and that&amp;rsquo;s where my main concern lies.&lt;br /&gt;&lt;br /&gt;To clarify further: even if, after the central deletes the bond, I reconnect&amp;nbsp; (as in step 5) and perform a new pairing and bonding additionally, the peripheral still attempts to send indications on value update, based on the old CCCD state that was cached from the previous bond. This happens before the central has explicitly enabled indications in the current session.&lt;br /&gt;&lt;br /&gt;According to the Bluetooth specification, a peripheral must not send notifications or indications unless the client has enabled them via the CCCD. When this desynchronization occurs, the behavior becomes unpredictable. In my case, when connecting to a commercial device, this mismatch sometimes freezes the BLE stack, regardless of whether the connection is encrypted or not.&lt;br /&gt;&lt;br /&gt;So the key question remains:&lt;br /&gt;What is the correct and recommended way to handle(on peripheral or central side) or reset the CCCD state when the bond has been removed on the central side but still exists on the peripheral?&lt;br /&gt;&lt;br /&gt;Any clarification or best practice from Nordic would be very helpful.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/534159?ContentTypeID=1</link><pubDate>Tue, 06 May 2025 16:54:56 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fa910132-32f3-43eb-a43c-e98d75fb064f</guid><dc:creator>Emil Lenngren</dc:creator><description>&lt;p&gt;The Bluetooth 6.0 spec says the following (Vol 3: Host, Part C: Generic Access Profile, 10.3.1.1):&lt;/p&gt;
&lt;p style="padding-left:30px;"&gt;Handling of GATT indications and notifications&lt;/p&gt;
&lt;p style="padding-left:30px;"&gt;A client &amp;ldquo;requests&amp;rdquo; a server to send indications and notifications by appropriately configuring the server via a Client Characteristic Configuration Descriptor. Since the configuration is persistent across a disconnection and reconnection, security requirements shall be checked against the configuration upon a reconnection before sending indications or notifications. When a server reconnects to a client to send an indication or notification for which security is required, the server shall initiate or request encryption with the client prior to sending an indication or notification. If the client does not have an LTK, indicating that the client has lost the bond, enabling encryption will fail.&lt;/p&gt;
&lt;p&gt;So yes, if the server is the peripheral role and encryption has not yet been enabled, it should send a Peripheral Security Request, wait for encryption started OR pairing completion (assuming the peripheral allows re-pair attempts at this point, perhaps after user consent) with sufficient security level,&amp;nbsp;THEN send the characteristic notification.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/533740?ContentTypeID=1</link><pubDate>Fri, 02 May 2025 11:33:42 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0da43f96-e092-4b43-b6bc-9cda25ec302a</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Biliy,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;I was thinking of the encryption property of the characteristic would help preventing the notification but it&amp;#39;s not true. Even if the connection doesn&amp;#39;t meet the encryption requirement of the characteristic , the notification will still be sent if the cache used.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;My suggestion is to add a check for the current security level of the connection before sending the notification. This way even if the CCCD is set, you can avoid having the notification being sent when the link is not encrypted at the correct level.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/533655?ContentTypeID=1</link><pubDate>Thu, 01 May 2025 06:04:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:30c8f1fd-6fde-47ba-9f5b-fb47ed5bda9b</guid><dc:creator>vitaliy2034</dc:creator><description>&lt;p&gt;Thank you for your reply. I agree with your argument, but this behavior creates a situation where the peripheral device is bonded, and the client is not (bonds are lost, for example, because of application data reset). After that, the same client initiates the pairing again, as it thinks, with a new device. After reconnecting, the peripheral device loads the old (previous) connection with the old CCCD values, but the client assumes it has connected to a new device and does not expect these CCCD values, which, in our case, causes unexpected notifications and, as a result, the client&amp;#39;s BLE stack to get stuck.&lt;br /&gt;&lt;br /&gt;Please advise the proper way to handle this situation. Maybe there is some way to check if the client has bonds?&lt;br /&gt;&lt;br /&gt;I&amp;#39;ve also tried to send a peripheral security request but got the same behavior.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: BLE stack loads old CCCD values after removing bonds on client side and reconnect</title><link>https://devzone.nordicsemi.com/thread/533415?ContentTypeID=1</link><pubDate>Tue, 29 Apr 2025 13:23:43 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:d0068384-3cd1-44ce-8d8d-69911221c518</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;Hi Biliy,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I believe it&amp;#39;s not a bug but a feature.&amp;nbsp;&lt;br /&gt;When you connect to a previously bonded device and the device now has removed bond with you, you are not expected to remove the previous bond and remove the gatt cache (CCCD cache)&amp;nbsp;&lt;br /&gt;The reason for that is that an attacker can easily spoof the peer device address and pretend that the bond has been removed (and maybe request a new bond).&amp;nbsp;&lt;br /&gt;&lt;br /&gt;You can either allow overwriting using this config&amp;nbsp;CONFIG_BT_SMP_ALLOW_UNAUTH_OVERWRITE (only for just work) or request end user proactively remove bond on the device itself.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;So from my point of view GATT cache should not be automatically removed. It should only be remove when delete bond button is pressed/selected on the device itself.&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>