1
0
mirror of https://github.com/bitwarden/mobile.git synced 2024-11-21 11:25:56 +01:00

Add url encoding to data parameter (#1822)

This commit is contained in:
Matt Gibson 2022-03-02 12:32:43 -05:00 committed by GitHub
parent db7ca3b93e
commit 084072e485
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,5 @@
using System;
using System.Net;
using Bit.App.Abstractions;
using Bit.App.Pages;
using Bit.App.Resources;
@ -439,7 +440,7 @@ namespace Bit.App.Utilities
var escaped = Uri.EscapeDataString(JsonConvert.SerializeObject(obj));
var multiByteEscaped = Regex.Replace(escaped, "%([0-9A-F]{2})", EncodeMultibyte);
return Convert.ToBase64String(Encoding.UTF8.GetBytes(multiByteEscaped));
return WebUtility.UrlEncode(Convert.ToBase64String(Encoding.UTF8.GetBytes(multiByteEscaped)));
}
public static async Task LogOutAsync(string userId, bool userInitiated = false)