4.4 Message Integrity Code (MIC)

  1. The message integrity code (MIC) is calculated over all the fields in the message.
  2. msg =MHDR|FHDR|FPort|FRMPayload
  3. whereby len(msg) denotes the length of the message in octets.
  4. The MIC is calculated as follows [RFC4493]:

29

  1. cmac = aes128cmac(NwkSKey, _B0 | msg)
  2. MIC =cmac[0..3]
32
33 whereby the block B0 is defined as follows:
Size (bytes) 1 4 1 4 4 1 1
B0 0x49 4 x 0x00 Dir DevAddr FCntUp or 0x00 len(msg)
FCntDown

©2016 LoRa™ Alliance Page 20 of 70

The authors reserve the right to change specifications without notice.

LoRaWAN Specification

1

2 The direction field (Dir) is 0 for uplink frames and 1 for downlink frames.

©2016 LoRa™ Alliance Page 21 of 70

The authors reserve the right to change specifications without notice.

LoRaWAN Specification

results matching ""

    No results matching ""