nokia / kong-oidc

OIDC plugin for Kong
Apache License 2.0
454 stars 321 forks source link

Update lua-resty-openidc to 1.6.0 and encode X-Userinfo header in base64 #56

Closed Trojan295 closed 6 years ago

Trojan295 commented 6 years ago

Fixes #47 and #52.

Fixing #52 required to break backward compatibility with 1.0.4. The X-Userinfo header is now base64 encoded. Using UTF-8 characters in HTTP headers isn't a good solution overall (https://tools.ietf.org/html/rfc7230#section-3.2.4).

@arun2dot0, @nbkntu, can you check, if this PR solves your issues?

@phirvone, @tsyrjanen, @pag-r

coveralls commented 6 years ago

Pull Request Test Coverage Report for Build 87


Totals Coverage Status
Change from base Build 77: 0.03%
Covered Lines: 118
Relevant Lines: 123

💛 - Coveralls
nbkntu commented 6 years ago

Thanks @Trojan295 for making this change.

I've just tested it and confirmed it's working. The server can receive the base64 encoded string and I'm able to get back the raw json (which contains special characters) after decoding it to UTF-8.