Funkwhale's answers, deletions and NodeInfo are understood
Three shapes Funkwhale 2.0 sends, each of which lost something: - its Accept is named after the Follow it answers, on our origin (`…#follows/<uuid>/accept`), and was refused as off its actor's origin, so no follow of a channel completed: an Accept or Reject whose id extends the id of the activity it answers, on our origin, is now taken; - a channel deletes its uploads in one Delete without an id, their ids in a list as the object's id: each is deleted; - its NodeInfo discovery names the document under its swagger schema's URL: a link whose path names NodeInfo is taken when no rel is known. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LsXgEaXee4GCU1hwYgPJXw
This commit is contained in:
1 parent
3866558d1d
commit
9f0b25e92b
5 files changed
+82
-3
No files matched your search
@@ -222,7 +222,10 @@ namespace PrivaPub.Federation.Inbox
|
||||
async Task<InboxResult> ShapeProblem(string type, JsonNode activity, string actorUri, CancellationToken token)
|
||||
{
|
||||
var activityId = Id(activity);
|
||||
if (activityId != default && !Origin.Same(activityId, actorUri))
|
||||
// (Funkwhale names its answer after the activity it answers: `<our Follow's id>/accept`)
|
||||
if (activityId != default && !Origin.Same(activityId, actorUri)
|
||||
&& !(type is "Accept" or "Reject" && Id(activity["object"]) is { } answered && Origin.Same(answered, _localActors.BaseAddress)
|
||||
&& activityId.StartsWith(answered + "/", StringComparison.Ordinal)))
|
||||
return new(StatusCodes.Status400BadRequest, "the activity's id is not on its actor's origin", Reason: "id-cross-origin");
|
||||
|
||||
var inner = activity["object"];
|
||||
|
||||
Reference in new issue
Block a user