Lines Matching refs:sec_level
647 static __u8 seclevel_to_authreq(__u8 sec_level) in seclevel_to_authreq() argument
649 switch (sec_level) { in seclevel_to_authreq()
1107 else if (hcon->sec_level == BT_SECURITY_FIPS) in smp_notify_keys()
1278 authenticated = hcon->sec_level == BT_SECURITY_HIGH; in smp_distribute_keys()
1324 if (hcon->sec_level > BT_SECURITY_MEDIUM) in smp_distribute_keys()
1714 u8 key_size, auth, sec_level; in smp_cmd_pairing_req() local
1786 sec_level = BT_SECURITY_MEDIUM; in smp_cmd_pairing_req()
1788 sec_level = authreq_to_seclevel(auth); in smp_cmd_pairing_req()
1790 if (sec_level > conn->hcon->pending_sec_level) in smp_cmd_pairing_req()
1791 conn->hcon->pending_sec_level = sec_level; in smp_cmd_pairing_req()
2179 static bool smp_ltk_encrypt(struct l2cap_conn *conn, u8 sec_level) in smp_ltk_encrypt() argument
2188 if (smp_ltk_sec_level(key) < sec_level) in smp_ltk_encrypt()
2203 bool smp_sufficient_security(struct hci_conn *hcon, u8 sec_level, in smp_sufficient_security() argument
2206 if (sec_level == BT_SECURITY_LOW) in smp_sufficient_security()
2220 if (hcon->sec_level >= sec_level) in smp_sufficient_security()
2233 u8 sec_level, auth; in smp_cmd_security_req() local
2249 sec_level = BT_SECURITY_MEDIUM; in smp_cmd_security_req()
2251 sec_level = authreq_to_seclevel(auth); in smp_cmd_security_req()
2253 if (smp_sufficient_security(hcon, sec_level, SMP_USE_LTK)) in smp_cmd_security_req()
2256 if (sec_level > hcon->pending_sec_level) in smp_cmd_security_req()
2257 hcon->pending_sec_level = sec_level; in smp_cmd_security_req()
2284 int smp_conn_security(struct hci_conn *hcon, __u8 sec_level) in smp_conn_security() argument
2292 BT_DBG("conn %p hcon %p level 0x%2.2x", conn, hcon, sec_level); in smp_conn_security()
2301 if (smp_sufficient_security(hcon, sec_level, SMP_USE_LTK)) in smp_conn_security()
2304 if (sec_level > hcon->pending_sec_level) in smp_conn_security()
2305 hcon->pending_sec_level = sec_level; in smp_conn_security()
2331 authreq = seclevel_to_authreq(sec_level); in smp_conn_security()
2438 authenticated = (hcon->sec_level == BT_SECURITY_HIGH); in smp_cmd_master_ident()
2544 if (conn->hcon->sec_level > BT_SECURITY_MEDIUM) in smp_cmd_sign_info()