# The JWT string must have two dots

**URL:** <https://forum.shopware.com/t/the-jwt-string-must-have-two-dots/100310>\
**Category:** Shopware 6 (English)\
**Created:** [29. Juni 2023 um 08:32 UTC](https://forum.shopware.com/t/the-jwt-string-must-have-two-dots/100310 "2023-06-29T08:32:45Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![NacScha](https://avatars.discourse-cdn.com/v4/letter/n/3bc359/32.png) [@NacScha](https://forum.shopware.com/u/NacScha)\
**Post date:** [29. Juni 2023 um 08:32 UTC](https://forum.shopware.com/t/the-jwt-string-must-have-two-dots/100310/1 "2023-06-29T08:32:45Z")

</div>

In a customer project of ours, there is a constantly logged error within the prod-log:

```auto
`[2023-06-16T11:03:12.870781+00:00] request.CRITICAL: Uncaught PHP Exception League\OAuth2\Server\Exception\OAuthServerException: "The resource owner or authorization server denied the request." at <<DIR>>/vendor/league/oauth2-server/src/Exception/OAuthServerException.php line 243 {"exception":"[object] (League\\OAuth2\\Server\\Exception\\OAuthServerException(code: 9): The resource owner or authorization server denied the request. at <<DIR>>/vendor/league/oauth2-server/src/Exception/OAuthServerException.php:243)\n[previous exception] [object] (Lcobucci\\JWT\\Token\\InvalidTokenStructure(code: 0): The JWT string must have two dots at <<DIR>>/vendor/lcobucci/jwt/src/Token/InvalidTokenStructure.php:13)"} []

```

It says something about a non valid jwt-token.

I already tried regenerate the jwt-secrets within config/jwt directory, but that didn’t worked out.  
Also there are not API calls in any form to the sw6 api. So that shouldn’t be the problem either.

Has someone else experience with an error like this?

---

<div class="post-metadata">

**Author:** ![Max\_Shop](https://avatars.discourse-cdn.com/v4/letter/m/58f4c7/32.png) [@Max\_Shop](https://forum.shopware.com/u/Max_Shop)\
**Post date:** [29. Juni 2023 um 09:15 UTC](https://forum.shopware.com/t/the-jwt-string-must-have-two-dots/100310/2 "2023-06-29T09:15:08Z")

</div>

The backend login uses the API to check the credentials. So these logs a most likely from third parties trying to use the API. It is usual to have hundreds of these messages in the log.

---

<div class="post-metadata">

**Author:** ![NacScha](https://avatars.discourse-cdn.com/v4/letter/n/3bc359/32.png) [@NacScha](https://forum.shopware.com/u/NacScha)\
**Post date:** [5. Juli 2023 um 06:14 UTC](https://forum.shopware.com/t/the-jwt-string-must-have-two-dots/100310/3 "2023-07-05T06:14:40Z")

</div>

Thanks for your response.  
But I don’t have these error on any other environment, so there must be a reason for this.

---

<div class="post-metadata">

**Author:** ![design3](https://avatars.discourse-cdn.com/v4/letter/d/9d8465/32.png) [@design3](https://forum.shopware.com/u/design3)\
**Post date:** [6. Juli 2023 um 08:55 UTC](https://forum.shopware.com/t/the-jwt-string-must-have-two-dots/100310/4 "2023-07-06T08:55:42Z")

</div>

we have the same issue… any news?

---

<div class="post-metadata">

**Author:** ![NacScha](https://avatars.discourse-cdn.com/v4/letter/n/3bc359/32.png) [@NacScha](https://forum.shopware.com/u/NacScha)\
**Post date:** [10. Juli 2023 um 09:23 UTC](https://forum.shopware.com/t/the-jwt-string-must-have-two-dots/100310/5 "2023-07-10T09:23:38Z")

</div>

not really ☹

maybe @Moritz_Naczenski or any other shopware team member can contribute ?

---

<div class="post-metadata">

**Author:** ![verpacking](https://avatars.discourse-cdn.com/v4/letter/v/a183cd/32.png) [@verpacking](https://forum.shopware.com/u/verpacking)\
**Post date:** [15. August 2023 um 10:44 UTC](https://forum.shopware.com/t/the-jwt-string-must-have-two-dots/100310/6 "2023-08-15T10:44:01Z")

</div>

Same problem (fortunately, dev-shop only, live shop is fine):  
I can not log into my user account (frontend), user registration not working, basket is empty after buying any product.  
What a nice surprise after 2 weeks of vacation…
