Laravel Sanctum - Issuing tokens for different users #33898
Unanswered
harishdurga
asked this question in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have 3 different types of users in separate tables. I am using Sanctum to issues tokens. Each type of user will be using different application connected to same database. Ex: admin.mysite.com, customer.mysite.com and merchant.mysite.com. I am using the auth:sanctum middleware. The token i have issued for Consumer is passing the sanctum guard in the merchant. And vice versa. How to prevent this? Should i need to implement my own middleware to check the tokenable_type of the token or is there any config in sanctum to do this?
Beta Was this translation helpful? Give feedback.
All reactions