jhub_remote_user_authenticator icon indicating copy to clipboard operation
jhub_remote_user_authenticator copied to clipboard

Change HTTP header

Open egrabello opened this issue 6 years ago • 3 comments

How do I change the HTTP header name? Also, I'm using an OIDC authenticator and the desired username comes at the end of "x-amzn-oidc-identity" header. It is not hard to get this info by manipulating the string, but I can't figure out where to do it.

Any suggestions??

Thanks in advance and congrats for this very useful authenticator!!

egrabello avatar Apr 01 '20 22:04 egrabello

Try: c.RemoteUserAuthenticator.header_name = "MY_HTTP_HEADER" or c.RemoteUserLocalAuthenticator.header_name = "MY_HTTP_HEADER" depending on the class you are using.

cwaldbieser avatar Apr 02 '20 13:04 cwaldbieser

Is there a way to extract a specific part of the value of this header? I mean, if I receive an email address and I want to remove the "@domain.com" for example...

egrabello avatar Apr 15 '20 17:04 egrabello

Take a look at https://github.com/cwaldbieser/jhub_remote_user_authenticator/issues/19. I pushed an experimental branch that may address this. If I get some feedback that it works, I will merge it into the master branch.

cwaldbieser avatar Apr 26 '20 00:04 cwaldbieser