[LMIC] Live data's Payload is not decryting

My end node is runnin a basic script from LMIC library and connecting using ABP.

I have checked my APPSKEY and NWKSKEY but still my live data is not being decrypted. I have also tried the BASE64 Decryting like you mentioned in the other post but this turns up very different values that I have sent. !

1 Like

That is because it is not inteded to be decrypted. It shows you the raw LoRaWAN frames. Please see the live data tab for decrypted application payloads.

The second screenshot is the live data tab

Sorry, I might have replied too quick. The data that you see in that tab is decrypted by LoRa App Server. If it is incorrect, than I think this is an ABP activation issue. E.g. the endianness of the AppSKey is wrong. As the data comes through, this indicates that at least the NwkSKey is correct as else the MIC would have failed.

I figured it out. Thanks for your help

The solution was i just took the data recieved and decoded using UTF-8 base64 and voila my messages were always there.

Note: Changed my appkey and I was recieving different data values for different transmission of the same data. When I entered the correct appkey, the data value was the same in all tranmission but it was just gibberish.

Encryption of the FRMPayload depends on the FPort value:
- if FPort = 0, then NwkSKey is used;
- if FPort = 1…255, then AppSKey is used.
If NwkSKey is correct - the MIC will always be correct, no matter if the AppSKey is correct or not.
AppKey is used only in OTAA devices for Join Request/Accept procedure.