The HomeKit protocol uses some pretty heavy duty math to secure itself. This is especially true with the choice of SRP for pairing an IOS device to a HomeKit device. But while these choices are not the familiar RSA, SHA1 or AES protocols, they are well defined standards already adopted in new cryptographic products. Unfortunately this doesn't make them the speediest choice for a little 16MHz Cortex-M0.
HomeKit has two major security processes. The first is Pairing when a trusted relationship is established between an iOS device and a HomeKit device. The second is Verifying, which takes places each time an iOS device reconnects to a HomeKit device (and so happens often).
Benchmarking these on the nRF51 we see the following:
- Pairing: 40 seconds
- Verifying: 1.2 seconds
While pairing is extremely slow, this is less important because it only happens once - we can tolerate this. Verifying is thankfully quick.
Out of interest, I've also benchmarked on the new nRF52 processor. This is a Cortex-M4 device running at 64MHz; quite a bit faster. Here we see the following:
- Pairing: 3.7 seconds
- Verifying: 0.26 seconds
Quite a nice improvement.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.