<?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>Authenticate using button</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/22673/authenticate-using-button</link><description>Hi, 
 we are building a device based on nrf52832. Everyone with the app installed should be able to connect to some characteristics on the device but we want other characteristics (that changes the device behavior) to be protected. The device have a</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 13 Jun 2017 07:15:26 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/22673/authenticate-using-button" /><item><title>RE: Authenticate using button</title><link>https://devzone.nordicsemi.com/thread/89138?ContentTypeID=1</link><pubDate>Tue, 13 Jun 2017 07:15:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6bacfc9d-6e9d-4d5e-9abb-88260cdfcc8b</guid><dc:creator>olovh</dc:creator><description>&lt;p&gt;Thanks for your ideas and responses!  @hung bui: I was trying to explain that I was looking for a way to also deny pairing requests and not only deny bonding requests. After som sleep and fresh coffee It was easily fixed by supplying a NULL argument to pm_sec_params_set() and I believe it all works fine for us now.&lt;/p&gt;
&lt;p&gt;In other words - ok to close this ticket now.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Authenticate using button</title><link>https://devzone.nordicsemi.com/thread/89137?ContentTypeID=1</link><pubDate>Mon, 12 Jun 2017 16:18:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:883fc231-8540-492b-9ceb-7ab2c44a1e05</guid><dc:creator>Hung Bui</dc:creator><description>&lt;p&gt;@olov: Could you clarify that the issue you have now is central device can pair but cannot bond ? It&amp;#39;s a little bit unclear on the issue you described: &lt;em&gt;&amp;quot;Problem with current setup is that all peers with access to the static key, which is distributed in the app, can do MITM level encryption and access the restricted attributes. It is just that they cannot bond unless button is pressed (have physical access to the unit).&amp;quot;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;isn&amp;#39;t  &lt;code&gt;It is just that they cannot bond unless button is pressed (have physical access to the unit).&lt;/code&gt; what you want to achieve ?&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t see any problem of using a physical button to reject bonding /pairing. You simply have to reject pairing when BLE_GAP_EVT_SEC_PARAMS_REQUEST event is received with BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP, if the button is not pressed.&lt;/p&gt;
&lt;p&gt;Please have a look at our ble_app_uart example, where we always reject pairing.&lt;/p&gt;
&lt;p&gt;Another option you can do is to set your protected characteristic with authorization property. So that if the button is not pressed, all the read and write to it will be rejected by the application.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Authenticate using button</title><link>https://devzone.nordicsemi.com/thread/89136?ContentTypeID=1</link><pubDate>Mon, 12 Jun 2017 14:52:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:fb2a72d0-5ce1-46fb-a903-88ef7edf802e</guid><dc:creator>dav lion</dc:creator><description>&lt;p&gt;My nrf51 product does something like this.  We use an unprotected characteristic on the board (peripheral) that the Central writes when it wants to Pair.   On receipt of this message, the peripheral shows an indicator to user (in our case a particular pattern of leds).   If the user accepts by pressing a button, the Peripheral informs the Central (ios/android) via an hvx on the unprotected characteristic.  Also, the peripheral sets a flag that allows connections to an encrypted characteristic, recording the address of the current Central.   For the rest of the duration of the current connection, the Central may attempt to read from an encrypted characteristic (setup for JustWorks pairing).   The peripheral gates whether pairing is allowed inside it&amp;#39;s on_ble_event handler, when processing the BLE_GATTS_EVT_RW_AUTHORIZE_REQUEST.  When the connection to the central closes, the peripheral stops allowing pairing.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>