OverviewFilesCommitsIssuesDocsReleasesPeers

ap-bridge commits / 2d4d1ae

ap-bridge 0.9.84: log the shape of what actually goes on the wire
Every layer above deliver() is instrumented and every one reports success, while prsm.space accepts our activities with 202 and stores none. The one thing never looked at is what we actually put on the wire. Shape only: type, ids, whether the object is embedded or a bare reference, whether it carries its own @context, attributedTo, addressing, and the signing keyId. Never the signature and never the whole body. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2d4d1ae25ec5c076c0a137afca6d3344a0c6a07a
by plankatron <fleeky@gmail.com> · 2026-09-09T01:31:17.000Z

Changed files (3) +31 -11

.pgh-lock.json +10 -10
……@@ -1,9 +1,9 @@
11{
22 "name": "ap-bridge",
3 "version": "0.9.82",
3 "version": "0.9.83",
44 "runtime": "bare",
5 "rootTreeHash": "0383e56463fd0b2b72bc3192e62b81aa6833cefff9ab7da5641f8723fa322a83",
6 "publishedAt": "2026-09-09T01:26:26.964Z",
5 "rootTreeHash": "f82982ad11e6c8dd975397eea77a9275e482d586f00d73698f22743e490357a2",
6 "publishedAt": "2026-09-09T01:28:01.706Z",
77 "deps": [
88 {
99 "name": "@hyperswarm/secret-stream",
……@@ -3929,7 +3929,7 @@
39293929 }
39303930 ],
39313931 "reason": "version-splits only",
3932 "acceptedAt": "2026-09-09T01:26:26.999Z"
3932 "acceptedAt": "2026-09-09T01:28:01.743Z"
39333933 },
39343934 {
39353935 "type": "VERSION_CONFLICT",
……@@ -3944,7 +3944,7 @@
39443944 }
39453945 ],
39463946 "reason": "version-splits only",
3947 "acceptedAt": "2026-09-09T01:26:27.000Z"
3947 "acceptedAt": "2026-09-09T01:28:01.743Z"
39483948 },
39493949 {
39503950 "type": "VERSION_CONFLICT",
……@@ -3969,7 +3969,7 @@
39693969 }
39703970 ],
39713971 "reason": "version-splits only",
3972 "acceptedAt": "2026-09-09T01:26:27.000Z"
3972 "acceptedAt": "2026-09-09T01:28:01.743Z"
39733973 },
39743974 {
39753975 "type": "VERSION_CONFLICT",
……@@ -3984,7 +3984,7 @@
39843984 }
39853985 ],
39863986 "reason": "version-splits only",
3987 "acceptedAt": "2026-09-09T01:26:27.000Z"
3987 "acceptedAt": "2026-09-09T01:28:01.743Z"
39883988 },
39893989 {
39903990 "type": "VERSION_CONFLICT",
……@@ -3999,7 +3999,7 @@
39993999 }
40004000 ],
40014001 "reason": "version-splits only",
4002 "acceptedAt": "2026-09-09T01:26:27.000Z"
4002 "acceptedAt": "2026-09-09T01:28:01.743Z"
40034003 },
40044004 {
40054005 "type": "VERSION_CONFLICT",
……@@ -4014,7 +4014,7 @@
40144014 }
40154015 ],
40164016 "reason": "version-splits only",
4017 "acceptedAt": "2026-09-09T01:26:27.000Z"
4017 "acceptedAt": "2026-09-09T01:28:01.743Z"
40184018 },
40194019 {
40204020 "type": "VERSION_CONFLICT",
……@@ -4034,7 +4034,7 @@
40344034 }
40354035 ],
40364036 "reason": "version-splits only",
4037 "acceptedAt": "2026-09-09T01:26:27.000Z"
4037 "acceptedAt": "2026-09-09T01:28:01.743Z"
40384038 }
40394039 ]
40404040}
lib/deliver.js +20 -0
……@@ -47,6 +47,26 @@ export function createDeliverer ({ signer, doFetch = httpClient, log = () => {},
4747
4848 async function postOnce (inboxUrl, activity, useSigner) {
4949 const body = JSON.stringify(activity)
50 // ⛔ THE ACTUAL BYTES. Every layer above this was instrumented and every one reported success
51 // while prsm.space accepted 17 activities with 202 and stored none — so the one thing never
52 // looked at was what actually goes on the wire. Shape only: type, ids, whether the object is
53 // embedded or a bare reference, and the keyId that signs it. Never the signature, never the
54 // whole body.
55 log({
56 msg: 'wire',
57 to: inboxUrl,
58 type: activity.type,
59 id: activity.id,
60 actor: activity.actor,
61 objectType: typeof activity.object === 'object' ? activity.object?.type : 'REFERENCE',
62 objectId: typeof activity.object === 'object' ? activity.object?.id : activity.object,
63 objectContext: typeof activity.object === 'object' ? !!activity.object['@context'] : null,
64 attributedTo: typeof activity.object === 'object' ? activity.object?.attributedTo : null,
65 to: activity.to,
66 cc: activity.cc,
67 keyId: useSigner && useSigner.keyId,
68 bytes: body.length
69 })
5070 const signed = await signRequestWith({
5171 method: 'POST',
5272 url: inboxUrl,
package.json +1 -1
……@@ -1,6 +1,6 @@
11{
22 "name": "ap-bridge",
3 "version": "0.9.83",
3 "version": "0.9.84",
44 "description": "ActivityPub membrane — a second projection of the self-custody atproto peer",
55 "type": "module",
66 "main": "index.js",