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
Read extended user attributes from auth proxy #7547
Read extended user attributes from auth proxy #7547
Conversation
[test] |
@sgallagher PTAL |
Evaluated for origin test up to f6a0c52 |
} | ||
if len(username) == 0 { | ||
id := headerValue(req.Header, a.config.IDHeaders) | ||
if len(id) == 0 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not that this is incorrect, but since this is now a function, wouldn't the logic be better if we had it return a boolean success or failure, rather than running a len() on the return? I'd think that would be less error-prone.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if I had that bool, I'd still do the length check, because we can't successfully provision an identity with an empty id. when we have a case where we care about a present-but-empty value, it'd be fine to add then
LGTM |
[merge] |
continuous-integration/openshift-jenkins/test SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pr_origin/1533/) |
continuous-integration/openshift-jenkins/merge SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pr_origin/1533/) (Image: devenv-rhel7_3520) |
Evaluated for origin merge up to f6a0c52 |
Merged by openshift-bot
Bring the requestheader IDP to parity with the other providers by allowing setting the display name, email, and preferred username from header values.
Added config for listing headers to read display name, email, and preferred username from. Example config: