fix(oauth): Use url safe base64

Description

While testing out chore: Add minLogLevel to config (!257 - closed), I can't running into an issue where the OAuth handshake would sometimes fail... After debugging things on the Rails server side I discovered this:

Screenshot_2023-11-08_at_11.50.57_AM

The problem: When we base64(sha256 on the clientside we are skipping the urlsafe aspect of this behavior (see relevant upstream code).

The fix: This MR updates our typedArrayToBase64 function to mirror Ruby's Base64.urlsafe_encode64.

Screenshots

OAuth handshake works consistently! (Please note: the redirect takes the user back to the config in localhost:8000/ (instead of straight to the Web IDE). This is expected behavior for now and will be addressed in another MR)

20231109_it_works

Edited by Paul Slaughter

Merge request reports

Loading