Logging of failed and successfull logins

Hello,

As out company has new rules, we need to log any failed and successfull login to chirpstack server. Even if i set the logs to Trace, i can only get these logs:

2024-06-03T07:41:45.207109Z DEBUG gRPC{uri=/api.InternalService/Login}: chirpstack::api: Started processing request
2024-06-03T07:41:45.208902Z  INFO gRPC{uri=/api.InternalService/Login}: chirpstack::api: Finished processing request status="200" latency=1.819143ms 

for a sucessfull login.

is there a way to get more informations about loggings in the logs

i am interessted in:

  • loging status (successfull, failed)
  • username
  • source IP Address

if this is not possible, i can also write a feature-request in github. but i can’t programm it myself.

thanks for the feedback.

Perhaps the API requests meta data in the redis stream holds more information you are looking for? API requests - ChirpStack open-source LoRaWAN® Network Server documentation

Looks like at the very least you could pull the username from there as the request holds the email and password: chirpstack/api/proto/api/internal.proto at master · chirpstack/chirpstack · GitHub

message LoginRequest {
  // Email of the user.
  string email = 1;

  // Password of the user.
  string password = 2;
}

I suspect the metadata holds the IP as well so thats 2/3

EDIT: After doing some digging into my own redis streams despite the documentation claiming it exposes metadata, it appears they only log the request method/API call and no data along with it. I don’t believe the logging capability you are looking for is in Chirpstack currently.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.