Decentralized social media network — no central server, user-owned data
Find a file
Scott Reimers dfd3253734 Fix: GroupKeyDistribute admin forgery + cap concurrent port scanners
Two pre-release fixes found during audit.

1) GroupKeyDistribute admin forgery (critical)

   `group_key_distribution::try_apply_distribution_post` trusted the
   `admin` field inside the decrypted payload without verifying it
   matched the post's author. Exploit: any peer who learns a victim's
   posting NodeId (public — appears as a recipient on any DM/group
   post) and observes a target group_id in the wild could craft an
   encrypted distribution post claiming to be from the legitimate
   admin. The victim's storage uses INSERT OR REPLACE on group_keys,
   so a successful forgery would overwrite the victim's legitimate
   group key record and stored seed, breaking future rotations / key
   distributions from the real admin.

   Fix: reject the distribution post when `content.admin != post.author`.
   Added test `forged_admin_is_rejected` that seeds a legitimate
   record, attempts a forgery, and asserts the legitimate record is
   untouched.

2) Cap concurrent port-scan hole punches at 1 (bandwidth)

   `hole_punch_with_scanning` fires ~100 QUIC ClientHellos/sec for up
   to SCAN_MAX_DURATION_SECS (300s), ~1 Mbps per active scanner. With
   no cap, the growth loop / anchor referrals / replication paths
   could spawn several scanners at once and drive sustained multi-Mbps
   upload — particularly pathological on obfuscated VPNs where every
   probe stalls at a proxy timeout, explaining the reported 10 Mbps
   sustained upload after anchor connect.

   Fix: module-level `tokio::sync::Semaphore(1)` guarding entry to the
   scanning loop. Second-and-beyond callers fall back to the cheaper
   `hole_punch_parallel` (standard punching, no 100/sec port walk)
   instead of spawning another scanner. Permit is held for the scanner
   lifetime and released on return. Added unit test
   `scanner_semaphore_caps_concurrent_scans_at_one`.

Both changes leave the successful-call path untouched (single scanner
still runs; legitimate key distributions still apply). 120 / 120 core
tests pass.
2026-04-22 23:32:10 -04:00
crates Fix: GroupKeyDistribute admin forgery + cap concurrent port scanners 2026-04-22 23:32:10 -04:00
deploy ItsGoin v0.3.2 — Decentralized social media network 2026-03-15 20:23:09 -04:00
docs v0.4.1: Security hardening, lock contention fixes, data cleanup 2026-03-21 19:30:38 -04:00
frontend Phase 2c: remove audience + PostPush + PostNotification + AudienceRequest/Response 2026-04-22 22:20:02 -04:00
website v0.6.1 release: version bump + changelog 2026-04-22 17:57:28 -04:00
.gitignore Add build-appimage.sh and deploy.sh automation scripts 2026-04-19 16:01:34 -04:00
.sync-exclude.lst ItsGoin v0.3.2 — Decentralized social media network 2026-03-15 20:23:09 -04:00
ARCHITECTURE.md ItsGoin v0.3.2 — Decentralized social media network 2026-03-15 20:23:09 -04:00
build-appimage.sh Add build-appimage.sh and deploy.sh automation scripts 2026-04-19 16:01:34 -04:00
Cargo.lock v0.6.1 release: version bump + changelog 2026-04-22 17:57:28 -04:00
Cargo.toml ItsGoin v0.3.2 — Decentralized social media network 2026-03-15 20:23:09 -04:00
deploy.sh Platform: Reset wipe, empty name, Android browse + backup-off, import as personas 2026-04-22 17:40:21 -04:00
download-page.html ItsGoin v0.3.2 — Decentralized social media network 2026-03-15 20:23:09 -04:00
IMPLEMENTATION_PLAN_0.6.md Implementation plan: drop cross-version compat, beta/stable as separate networks 2026-04-21 18:26:55 -04:00
pic2.png v0.4.4: UI overhaul — sticky header, mobile nav, profiles/redundancy lightboxes 2026-03-23 00:56:27 -04:00
project discussion.txt ItsGoin v0.3.2 — Decentralized social media network 2026-03-15 20:23:09 -04:00
project-notes-from-elitebook.md ItsGoin v0.3.2 — Decentralized social media network 2026-03-15 20:23:09 -04:00
TODO.md ItsGoin v0.3.2 — Decentralized social media network 2026-03-15 20:23:09 -04:00