okta / okta-jwt-verifier-python

okta-jwt-verifier-python
https://github.com/okta/okta-jwt-verifier-python
Apache License 2.0
33 stars 17 forks source link

okta-jwt-verifier does not support proxies #19

Closed ShubhamSharmaCSE closed 3 years ago

ShubhamSharmaCSE commented 3 years ago

Hi Team,

I was trying to integrate a service running behind HTTP proxy to connect to okta using the okta-jwt-verifier library for JWT validation.

However, after going through the codebase, I find that the library does not support HTTP proxies.

I see that request_executor.py uses the acachecontrol library. This library supports proxies by doing something like https://docs.aiohttp.org/en/1.3.4/client.html#proxy-support or setting trust_env parameter in aiohttp ClientSession(https://docs.aiohttp.org/en/stable/client_reference.html)

Please let me know if I am missing something or if the above context is incorrect. If above sounds good, can someone please look into it.

serhiibuniak-okta commented 3 years ago

@ShubhamSharmaCSE Thanks for posting well-detailed issue. I'll take a look at it. Meanwhile, to unblock you, I can suggest coding some custom RequestExecutor and pass it to JWTVerifier constructor:

jwt_verifier = JWTVerifier('{ISSUER}', '{CLIENT_ID}', 'api://default', request_executor=CustomRequestExecutor)
serhiibuniak-okta commented 3 years ago

@ShubhamSharmaCSE v0.2.0 has been released, I'm closing this issue as resolved. Feel free to reopen or create a new one if your problem exists still