Skip to content
This repository has been archived by the owner on Feb 14, 2018. It is now read-only.

URL rewrite using dynamic data in JWT #8

Open
twistedstream opened this issue Apr 2, 2015 · 1 comment
Open

URL rewrite using dynamic data in JWT #8

twistedstream opened this issue Apr 2, 2015 · 1 comment

Comments

@twistedstream
Copy link
Contributor

Leverage the URL rewrite capabilities of Nginx (ex: using the ngx_http_rewrite_module module) and perform a rewrite where the destination URL contains data from the JWT.

Example:

  • The Nginx endpoint being called is /api/userinfo and the JWT passed by the client contains a field user_id: sandrino123
  • The rewritten URL to the downstream endpoint becomes https://server01/legacy/api/getuserinfofor/$user_id (where $user_id is a value from the JWT in the Authorization header)
@tarachandverma
Copy link

This supports dynamic url rewriting and custom response.
https://github.com/tarachandverma/nginx-openidc

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants