Issue link: https://read.uberflip.com/i/1428377
LoRaWAN Specification ©2015 LoRa™ Alliance Page 31 of 82 The authors reserve the right to change specifications without notice. The join procedure requires the end-device to be personalized with the following information 1 before its starts the join procedure: a globally unique end-device identifier (DevEUI), the 2 application identifier (AppEUI), and an AES-128 key (AppKey). 3 The AppEUI is described above in 6.1.2. 4 Note: For over-the-air-activation, end-devices are not personalized 5 with any kind of network key. Instead, whenever an end-device joins a 6 network, a network session key specific for that end-device is derived 7 to encrypt and verify transmissions at the network level. This way, 8 roaming of end-devices between networks of different providers is 9 facilitated. Using both a network session key and an application 10 session key further allows federated network servers in which 11 application data cannot be read or tampered with by the network 12 provider. 13 6.2.1 End-device identifier (DevEUI) 14 The DevEUI is a global end-device ID in IEEE EUI64 address space that uniquely identifies 15 the end-device. 16 6.2.2 Application key (AppKey) 17 The AppKey is an AES-128 application key specific for the end-device that is assigned by 18 the application owner to the end-device and most likely derived from an application-specific 19 root key exclusively known to and under the control of the application provider. 1 Whenever 20 an end-device joins a network via over-the-air activation, the AppKey is used to derive the 21 session keys NwkSKey and AppSKey specific for that end-device to encrypt and verify 22 network communication and application data. 23 6.2.3 Join procedure 24 From an end-device's point of view, the join procedure consists of two MAC messages 25 exchanged with the server, namely a join request and a join accept. 26 6.2.4 Join-request message 27 The join procedure is always initiated from the end-device by sending a join-request 28 message. 29 30 Size (bytes) 8 8 2 Join Request AppEUI DevEUI DevNonce The join-request message contains the AppEUI and DevEUI of the end-device followed by a 31 nonce of 2 octets (DevNonce). 32 DevNonce is a random value. 2 For each end-device, the network server keeps track of a 33 certain number of DevNonce values used by the end-device in the past, and ignores join 34 requests with any of these DevNonce values from that end-device. 35 1. Since all end-devices end up with unrelated application keys specific for each end-device, extracting the AppKey from an end-device only compromises this one end-device. 2 The DevNonce can be extracted by issuing a sequence of RSSI measurements under the assumption that the quality of randomness fulfills the criteria of true randomness
