HTTP 401 unauthorized v6.17.0

Oluwatobi 4 hours ago

After upgrading server to 6.17.0

Started getting this error across all users

Http 401 Unauthorized
jakarta.ws.rs.WebApplicationException: HTTP 401 Unauthorized
	at org.traccar.api.security.SecurityRequestFilter.filter(SecurityRequestFilter.java:107)
	at org.glassfish.jersey.server.ContainerFilteringStage.apply(ContainerFilteringStage.java:108)
	at org.glassfish.jersey.server.ContainerFilteringStage.apply(ContainerFilteringStage.java:44)…

This happens on the following conditions:

  1. when any user login with face id or fingerprint.
  2. You get the error only when you want to send a command, or modify data (create, edit, delete user, device, etc)

The only way to bypass is to
Logout, and login by typing your password…

And after that, session it goes back to unauthorized.

The only exception is, view devices, location or history works… (sometimes)

Anton Tananaev 4 hours ago

Are you using a reverse proxy? Please check whether it preserves the original Host header. For nginx, check proxy_set_header Host $host;. A mismatch between the public hostname and the Host header reaching Traccar would explain why biometric login allows viewing data but changes fail, while password login works.

Oluwatobi 3 hours ago

Thanks Anton, That worked.

Looking at code history, i see this was introduced in 6.15.3. and I upgraded from 6.13.