Unauthorized API request: Error while processing JWT token

  • Platform information:
    • Hardware: Raspberry Pi 3 Model B Plus Rev 1.3
    • OS: Linux openhabian 5.10.11-v7+
    • Java Runtime Environment: openjdk version “11.0.10” 2021-01-19 LTS
    • openHAB version: 3.0.1
  • Issue of the topic: Error message as title describes.
  • Please post configurations (if applicable): None that I understand.
  • If logs where generated please post these here using code fences:
2021-02-28 14:41:25.574 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:41:30.743 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:41:35.781 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:41:40.808 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:41:45.869 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:41:51.036 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:42:25.126 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:42:30.284 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:42:35.323 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:42:40.387 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:42:45.543 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

2021-02-28 14:42:50.579 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

I get these warning messages alone or many at a time. I can’t corelate other prior message that could give any clue to why they appear.

Do I need to disable all bindings one after the other before I find the one responsible for these messages? What should I do then?

I have gotten those errors when I have had the UI open in a browser for a long time, or when the computer have gone to sleep and resumes while the UI is open. It then tries to reconnect without getting a new token, which results in this error. A reload of the page should fix it.

4 Likes

Hi,
I am also suffering from those warning messages appearing in the log from time to time an the last days very massiv (some 100 an hour)

2021-07-22 09:23:12.103 [WARN ] [ore.io.rest.auth.internal.AuthFilter] - Unauthorized API request: Error while processing JWT token

I have closed the browser on my mac, but I have an Android Tablet with the client running and 2 IOS phones also with the active client. I also receive some messages at the bottom of these clients when I activate them.

Any clues how to solve this?

I was going to say just ignore it but if it is happening 100 times an hour this needs to be looked into as it could be someone trying to do a brute force attack, or a bug that needs to be looked into. As the post above yours mentions it is normal if you are leaving web browsers or apps connected that have gone to sleep and then you try to use them again. I only see this happen a few times per week.

A good test to do would be to turn off your modem/internet connection when they are occurring and do they stop or continue? Close any open apps that may be running in the background of your tablets, phones and the like as it may be a device is leaving the page open and doing auto refreshes at a certain period of time. Can you narrow it down to a certain app or device?

If your certain you know the cause of them then you can filter them out of the logs so you do not see them anymore. Search forum for how to filter your logs.

1 Like

Good Morning,

I figured out that the problem was caused by my imac having an Openhab Managment interface open. By closing that the wanings disappeared. I now always log out from the interface and log in again when changing something.

Thanks for you support,

br Leo