logo

pleroma

My custom branche(s) on git.pleroma.social/pleroma/pleroma git clone https://hacktivis.me/git/pleroma.git
commit: 4039106500ed0adba3ac6dbd480954aa76ce6bc3
parent 1d417d2a364eb8ae2035275927f6284951fe128b
Author: Mark Felder <feld@feld.me>
Date:   Fri,  8 Dec 2023 21:51:36 -0500

Fix the req_headers formatting

Diffstat:

Mlib/pleroma/workers/receiver_worker.ex4++++
1 file changed, 4 insertions(+), 0 deletions(-)

diff --git a/lib/pleroma/workers/receiver_worker.ex b/lib/pleroma/workers/receiver_worker.ex @@ -14,6 +14,10 @@ defmodule Pleroma.Workers.ReceiverWorker do def perform(%Job{ args: %{"op" => "incoming_ap_doc", "req_headers" => req_headers, "params" => params} }) do + # Oban's serialization converts our tuple headers to lists. + # Revert it for the signature validation. + req_headers = Enum.into(req_headers, [], &List.to_tuple(&1)) + conn_data = %{params: params, req_headers: req_headers} with {:ok, %User{} = _actor} <- User.get_or_fetch_by_ap_id(conn_data.params["actor"]),