Trying to use it with mongo, but the user login_check payload is empty #1049
-
Hi there I am trying to use that library with a mongodb,so I started from there But after doing a POST request I get an error that
Actually the whole payload is empty... I am confused, there is no reason for the payload to be empty |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 6 replies
-
Hi, can you post your |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
Is the token produced by the very same application, using this bundle? |
Beta Was this translation helpful? Give feedback.
-
Yes, it is going to be produced by the same application using this bundle. |
Beta Was this translation helpful? Give feedback.
-
Oh ok it's not when using a token but when trying to get one. The main target of this feature is to allow not querying the database on token-authenticated requests, so you only need to hit the database once when obtaining a token. And to obtain a token, you need a regular user class and user provider such as https://symfony.com/doc/current/security/user_providers.html#entity-user-provider. The database-less user provider is mostly useful for server-to-server interactions. |
Beta Was this translation helpful? Give feedback.
Oh ok it's not when using a token but when trying to get one. The main target of this feature is to allow not querying the database on token-authenticated requests, so you only need to hit the database once when obtaining a token. And to obtain a token, you need a regular user class and user provider such as https://symfony.com/doc/current/security/user_providers.html#entity-user-provider. The database-less user provider is mostly useful for server-to-server interactions.
If you want to use this bundle the classic way i.e. authenticating a user that exists in your database, then you may not need to use the database-less
JWTUserProvider
andJWTUser
class at all but just follow the getting …