Configuring brokerClientAuthenticationParameter for AuthenticationToken plugin does not work as documented
#14.435 geöffnet am 23. Feb. 2022
Repository-Metriken
- Stars
- (13.697 Stars)
- PR-Merge-Metriken
- (Durchschn. Merge 3T 10h) (146 gemergte PRs in 30 T)
Beschreibung
Describe the bug
The documentation suggest that the proper way to reference a file with brokerClientAuthenticationParameter for JWT plugin is brokerClientAuthenticationParameters={"file":"///path/to/proxy-token.txt"}, which does not work. When you look at the source you'll see that it parses a string like file:/some/path or token:someToken, otherwise it tried JSON which explicitly only looks for the token property. Runtime behavior confirms this, I get a long long stack trace pointing back to trying to look at the token property of the provided JSON. So either the docs are wrong or the code is wrong.
To Reproduce Steps to reproduce the behavior:
- Setup [Client authentication using tokens based on JSON Web Tokens]
- Instead of embeddeding the token directly into the config uncomment and use the alternative to load from a file below, which reads:
brokerClientAuthenticationParameters={"file":"///path/to/proxy-token.txt"}
Expected behavior The provided JSON parameter works as stated in the documentation, OR the documentation instead recommends the non-JSON parameters.
Screenshots N/A
Desktop (please complete the following information):
- Ubuntu 20.04, but this is running in the official container.
Additional context Add any other context about the problem here.