Forum Discussion
Charset issue with Basic authentication
- 4 years ago
At a high level, the answer is "whenever your Excel channel gets the December release of Power Query". There are more details in the below thread about how to determine which release channel you're on (which determines how quickly you'll receive PQ updates), and how to determine which version of PQ you have.
Hi bnobo . Just to confirm: the issue occurs when using the built-in Basic auth, not passing the creds manually via custom M. Is that correct?
- bnobo4 years agoFrequent Visitor
Hi Ehren , you are right, the issue occurs when using the built-in Basic auth.
- Ehren4 years agoMicrosoft Employee
Ok. Let me see if there's a way to solve this without breaking backwards-compatibility.
- bnobo4 years agoFrequent Visitor
You could handle the "charset" auth-param returned by the server in WWW-Authenticate header when the authentication fail (401 status code) as stated in Basic Authentication RFC 7617: https://datatracker.ietf.org/doc/html/rfc7617#section-2.1
If the WWW-Authenticate header returned by the server contains 'charset="UTF-8"' then re-encode username:password with UTF-8 encoding and re-emit the request.
Doing so, the encoding would change only for servers requesting UTF-8 encoding.