From c834d3d2bcf04359205241aff9b506b8dca4adc0 Mon Sep 17 00:00:00 2001 From: Morten Nielsen Date: Tue, 7 Nov 2023 12:14:09 -0800 Subject: [PATCH] Ensure WebAuthenticator URL is fully encoded to avoid issues with certain OAuth servers (#146) Fixes #144 --- src/Directory.Build.targets | 4 ++-- src/WinUIEx/WebAuthenticator.cs | 2 +- src/WinUIEx/WinUIEx.csproj | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Directory.Build.targets b/src/Directory.Build.targets index 7b0873d..b9f63b0 100644 --- a/src/Directory.Build.targets +++ b/src/Directory.Build.targets @@ -17,8 +17,8 @@ Morten Nielsen - https://xaml.dev Morten Nielsen - https://xaml.dev logo.png - 2.3.2 - 2.3.1 + 2.3.3 + 2.3.2 diff --git a/src/WinUIEx/WebAuthenticator.cs b/src/WinUIEx/WebAuthenticator.cs index 71bfeba..4243499 100644 --- a/src/WinUIEx/WebAuthenticator.cs +++ b/src/WinUIEx/WebAuthenticator.cs @@ -260,7 +260,7 @@ private async Task Authenticate(Uri authorizeUri, Uri ca var process = new System.Diagnostics.Process(); process.StartInfo.FileName = "rundll32.exe"; - process.StartInfo.Arguments = $"url.dll,FileProtocolHandler \"{authorizeUri.ToString().Replace("\"","%22")}\""; + process.StartInfo.Arguments = $"url.dll,FileProtocolHandler \"{authorizeUri.OriginalString}\""; process.StartInfo.UseShellExecute = true; process.Start(); tasks.Add(taskId, tcs); diff --git a/src/WinUIEx/WinUIEx.csproj b/src/WinUIEx/WinUIEx.csproj index 08715f1..e345f58 100644 --- a/src/WinUIEx/WinUIEx.csproj +++ b/src/WinUIEx/WinUIEx.csproj @@ -24,7 +24,7 @@ WinUIEx WinUI Extensions - - Fixed WebAuthenticator issue not working with FireFox (#117) + - Ensure WebAuthenticator URL is fully encoded to avoid issues with certain OAuth servers (#144)