Skip to content

Commit

Permalink
Fix to use upn after copy-paste from email section
Browse files Browse the repository at this point in the history
  • Loading branch information
Vishnu Mohan committed Jul 8, 2018
1 parent e562431 commit 6ce4636
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nginx/lua/oidc_auth_proxy_pass.lua
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ end
-- Only authorize a valid user, based on their User Principal Name (UPN), if specified
if is_not_empty(os.getenv("OIDC_UPN")) then
ngx.log(ngx.DEBUG, "Authorizing UPN: " .. os.getenv("OIDC_UPN") .. " against " .. tostring(res.user.upn))
if res.user.email ~= os.getenv("OIDC_UPN") then
if res.user.upn ~= os.getenv("OIDC_UPN") then
ngx.exit(ngx.HTTP_FORBIDDEN)
end
end
Expand Down

0 comments on commit 6ce4636

Please sign in to comment.