TheThingsNetwork / lorawan-stack

The Things Stack, an Open Source LoRaWAN Network Server
https://www.thethingsindustries.com/stack/
Apache License 2.0
957 stars 302 forks source link

Improve Network Server end device state validation #5399

Open adriansmares opened 2 years ago

adriansmares commented 2 years ago

Summary

References https://sentry.io/organizations/the-things-industries/issues/3103305258 References https://sentry.io/organizations/the-things-industries/issues/3107052796

This issue tracks missing validation rules from the NS device registry Set operations.

Why do we need this?

In order to avoid runtime errors caused by the fact that invalid end device settings were provided via Set.

What is already there? What do you see now?

The Set validation mechanism.

What is missing? What do you want to see?

Environment

v3.19

How do you propose to implement this?

How do you propose to test this?

Manual testing.

Can you do this yourself and submit a Pull Request?

Yes

nicholaspcr commented 2 years ago

While working on #5708 I encountered a panic on the network server when trying to import a CSV file.

The file used can be found in this issue.

The steps to reproduce the error are:

The logs of the CLI - > cli.txt The logs of the Stack - > server.txt (The panic can be found on the line 117)