Merge pull request #689 from zxzxwu/link_key

Fix: Missing EVENT_LINK_KEY
This commit is contained in:
zxzxwu
2025-05-13 12:09:27 +08:00
committed by GitHub
+2 -1
View File
@@ -1628,6 +1628,7 @@ class Connection(utils.CompositeEventEmitter):
EVENT_PAIRING = "pairing"
EVENT_PAIRING_FAILURE = "pairing_failure"
EVENT_SECURITY_REQUEST = "security_request"
EVENT_LINK_KEY = "link_key"
@utils.composite_listener
class Listener:
@@ -5066,7 +5067,7 @@ class Device(utils.CompositeEventEmitter):
# [Classic only]
@host_event_handler
def on_link_key(self, bd_addr, link_key, key_type):
def on_link_key(self, bd_addr: hci.Address, link_key: bytes, key_type: int) -> None:
# Store the keys in the key store
if self.keystore:
authenticated = key_type in (