-
Notifications
You must be signed in to change notification settings - Fork 673
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Separate signing keys for different services #202
Comments
What do you mean by a service? Could you give an example? Maybe code snippet to reproduce the issue and how you imagine it to be solved. |
I’m not quite sure how we would implement this... are you asking if we should have a list of signing keys and test against each one until — voila — it works? @PetrS12 I don’t think it’d be an issue to implement, but I’m just wondering how you’d or some other package would do it. |
What happens if you create a 3rd service? Could this be abstracted out for N services? You could create a mapping of service ID to signing key (great idea btw, I didn't even consider this limitation). |
Alternatively, I am using this package for an identity service that returns the user's permissions upon login:
That way the service handles authentication (client - > service - > identity - > service - > client) and then the service knows if the jwt token is valid for their service. |
Yes, I can create a dictionary "host": "signing key". And I will add signing key for each host.
I am not sure that it`s good idea for me. What`s wrong in my solution? #210 |
That's my bad. I was looking on my phone and was thinking this added just 1 extra key. I like the option to specify a key. |
@PetrS12 Sorry for taking a looooong time to review your PR. I'm on a bit of a running streak atm of reviewing long lost issues, so bear with me. Unfortunately, I'm also very careful not to allow too many features in SimpleJWT in fear of having too much flexibility which can lead to security vulnerabilities. So again, bear with me. |
Hello!
In our project there are restrictions on services: in the api information is given depending on the specified service.
In this regard, there was a problem with the separation of "signing_key" for different services, since at the moment you can specify only one single "signing_key" for project.
Thanks!
The text was updated successfully, but these errors were encountered: