From: William Pitcock Date: Sun, 11 Nov 2018 05:11:27 +0000 (+0000) Subject: oauth: fix token decode regression X-Git-Url: https://git.squeep.com/?a=commitdiff_plain;h=419ed3a0ca62dbcc4ea3985f6561e2aad4b48e5b;p=akkoma oauth: fix token decode regression --- diff --git a/lib/pleroma/web/oauth/oauth_controller.ex b/lib/pleroma/web/oauth/oauth_controller.ex index 35c158fbb..d03c8b05a 100644 --- a/lib/pleroma/web/oauth/oauth_controller.ex +++ b/lib/pleroma/web/oauth/oauth_controller.ex @@ -143,8 +143,11 @@ defmodule Pleroma.Web.OAuth.OAuthController do end end + # XXX - for whatever reason our token arrives urlencoded, but Plug.Conn should be + # decoding it. Investigate sometime. defp fix_padding(token) do token + |> URI.decode() |> Base.url_decode64!(padding: false) |> Base.url_encode64() end