<?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>why i am getting pairing rejected  by nordic _uart</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/42092/why-i-am-getting-pairing-rejected-by-nordic-_uart</link><description>hi..folks 
 wish you happiee new year 
 i am using nrf52832 whille i tried to pair my device with my android , i am getting an error message &amp;quot; pairing rejected by nordic_uart &amp;quot; why?</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 01 Oct 2020 09:48:39 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/42092/why-i-am-getting-pairing-rejected-by-nordic-_uart" /><item><title>RE: why i am getting pairing rejected  by nordic _uart</title><link>https://devzone.nordicsemi.com/thread/272468?ContentTypeID=1</link><pubDate>Thu, 01 Oct 2020 09:48:39 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:17af5fa2-98fa-4d11-abea-f5f7c8afde02</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;Presuming your change doesn&amp;#39;t give any error code, then I suspect it may be related to HRM already have a bond, thereby doesn&amp;#39;t want to allow re-bonding with the same peer.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Typically the application can allow re-pairing by adding the following in pm_evt_handler() in main.c:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;case PM_EVT_CONN_SEC_CONFIG_REQ:
{
// Allow or reject pairing request from an already bonded peer.
pm_conn_sec_config_t conn_sec_config = {.allow_repairing = true};
pm_conn_sec_config_reply(p_evt-&amp;gt;conn_handle, &amp;amp;conn_sec_config);
} break;&lt;/pre&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Though, be aware that the user should somehow control this (e.g. by the user for instance press a pairing button), because always allowing re-pairing should be considered an security issue.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;If this isn&amp;#39;t the problem, then I would like a on-air sniffer log (e.g. from nRF sniffer) so I can see the actual on-air error.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: why i am getting pairing rejected  by nordic _uart</title><link>https://devzone.nordicsemi.com/thread/272248?ContentTypeID=1</link><pubDate>Wed, 30 Sep 2020 11:01:25 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2a804e2c-4840-4794-815a-ad6d917094b0</guid><dc:creator>Priyajit</dc:creator><description>&lt;p&gt;While I am going to pair with my android 9 Asus mobile phone with SDK 17 nRF52840. It in my mobile showing&amp;nbsp;&amp;quot;Pairing rejected by Nordic_HRM&amp;quot;. After that&amp;nbsp; I have added a some code line to&lt;/p&gt;
&lt;p&gt;&lt;span&gt;static&amp;nbsp;void&amp;nbsp;peer_manager_init(bool&amp;nbsp;erase_bonds);&lt;/span&gt;&lt;/p&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#af2d04383bf2e1c7a4447e024528b7db9"&gt;bond&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;=&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;false&lt;/span&gt;;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#ab717b7758f6bc0d7ea50682a4d4e149b"&gt;mitm&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;=&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;false&lt;/span&gt;;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#a37125ba9f755929ebc159409446672da"&gt;lesc&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;= 0;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#ac982cb581f29c6277d0d114fa538b4ea"&gt;keypress&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;= 0;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#a13fd33e5f5b50a596e255123f8d21036"&gt;io_caps&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;=&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/group___b_l_e___g_a_p___i_o___c_a_p_s.html#gad11df80d3ac9d375b320363694ec0a03"&gt;BLE_GAP_IO_CAPS_NONE&lt;/a&gt;;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#a72cc5af2f69e1b15a7c0b281acd1059e"&gt;oob&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;=&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;false&lt;/span&gt;;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#a70632c0a1d795c5b651d910826803cad"&gt;min_key_size&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;= 7;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#a6f9134a72c72763bc041086eea13aced"&gt;max_key_size&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;= 16;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#af6639a7874bf72b598b6b3df0d51e68a"&gt;kdist_own&lt;/a&gt;.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__kdist__t.html#aa84265de1334d3ddeed29a09209f02a9"&gt;enc&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;= 0;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#af6639a7874bf72b598b6b3df0d51e68a"&gt;kdist_own&lt;/a&gt;.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__kdist__t.html#a6319f6981dbbcff973574420e81090ce"&gt;id&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;= 0;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#aa00739cbe799e543707da9786f8be440"&gt;kdist_peer&lt;/a&gt;.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__kdist__t.html#aa84265de1334d3ddeed29a09209f02a9"&gt;enc&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;= 0;&lt;/div&gt;
&lt;div&gt;sec_param.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__params__t.html#aa00739cbe799e543707da9786f8be440"&gt;kdist_peer&lt;/a&gt;.&lt;a href="https://infocenter.nordicsemi.com/topic/com.nordic.infocenter.s132.api.v2.0.0/structble__gap__sec__kdist__t.html#a6319f6981dbbcff973574420e81090ce"&gt;id&lt;/a&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;= 0;&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;And getting same&amp;nbsp;&amp;quot;Pairing rejected by Nordic_HRM&amp;quot;&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;After that I have added this code,&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;sec_param.bond = true;&lt;br /&gt;sec_param.mitm = false;&lt;br /&gt;sec_param.lesc = 0;&lt;br /&gt;sec_param.keypress = 0;&lt;br /&gt;sec_param.io_caps = BLE_GAP_IO_CAPS_NONE;&lt;br /&gt;sec_param.oob = false;&lt;br /&gt;sec_param.min_key_size = 7;&lt;br /&gt;sec_param.max_key_size = 16;&lt;br /&gt;sec_param.kdist_own.enc = 1;&lt;br /&gt;sec_param.kdist_own.id = 1;&lt;br /&gt;sec_param.kdist_peer.enc = 1;&lt;br /&gt;sec_param.kdist_peer.id = 1;&lt;/div&gt;
&lt;div&gt;&lt;span&gt;And getting same&amp;nbsp;&lt;/span&gt;&lt;span&gt;&amp;quot;Pairing rejected by Nordic_HRM&amp;quot;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;&lt;span&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;Please give some solution.&lt;/span&gt;&lt;/div&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: why i am getting pairing rejected  by nordic _uart</title><link>https://devzone.nordicsemi.com/thread/163733?ContentTypeID=1</link><pubDate>Thu, 03 Jan 2019 12:01:10 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4ae25211-cffd-4bf4-b1c5-4dbb8b80f0ab</guid><dc:creator>Kenneth</dc:creator><description>&lt;p&gt;I do believe the example you refer to does not support pairing and bonding, refer to:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="c_cpp"&gt;        case BLE_GAP_EVT_SEC_PARAMS_REQUEST:
            // Pairing not supported
            err_code = sd_ble_gap_sec_params_reply(m_conn_handle, BLE_GAP_SEC_STATUS_PAIRING_NOT_SUPP, NULL, NULL);
            APP_ERROR_CHECK(err_code);
            break;&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;If you want to support pairing and bonding, then you need to use an example that have peer manager.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>