Files
lanspread/security-report/report.md
T
2026-09-02 22:08:37 +02:00

137 KiB

Security Review: lanspread

Scope

Whole Git-backed Lanspread repository at revision 15faecbf89, including Rust workspace crates, Tauri frontend/shell, catalog/build tooling, peer CLI, tests, configs, generated permission manifests, and opaque sidecars as data.

  • Scan mode: repository
  • Target kind: git_revision
  • Target ID: target_sha256_b3f00671b54800aee0df5478bf1bd03061b69b79eb9beece1ed34dc8c8bbc8a6
  • Revision: 15faecbf89
  • Inventory strategy: repository
  • Included paths: .
  • Excluded paths: none
  • Runtime or test status: Source review, validation, attack paths, and coverage reconciliation complete.
  • Artifacts reviewed: 94 Rust source files, production TypeScript/TSX/CSS/HTML frontend, Cargo/deno manifests and locks, Tauri capabilities/config/build gate, just/Python/Docker publisher and peer-CLI workflows, tests exposing product contracts, opaque unrar sidecar metadata/digests
  • Scan context: Standard single-pass read-only security audit with no additional user focus.

Limitations and exclusions:

  • Offline static review only; no application or third-party binary execution.
  • No online dependency advisory lookup.
  • External production package corpus and generated production manifests absent.
  • No physical-LAN, Windows UAC, or live resource-exhaustion reproduction.
  • Excluded crates/lanspread-tauri-deno-ts/src-tauri/assets/** and src-tauri/icons/**: Static image/icon payloads; file types and consumers were checked, but pixel data is not executable security logic.
  • Excluded crates/lanspread-peer-cli/fixtures/** and catalog fixture payload bytes (*.eti, *.ini, *.db): Static test corpus. Publisher/loaders, catalog manifests, protocol harness, and scenario consumers were reviewed rather than treating every fixture byte as implementation source.
  • Excluded crates/lanspread-tauri-deno-ts/src-tauri/gen/schemas/** except ACL/capability manifests: Generated schema output; checked-in capability source and generated ACL/capability manifests owning runtime permissions were inspected.
  • Excluded Documentation-only design prose outside README.md and crates/lanspread-peer/ARCHITECTURE.md: Non-executable prose not owning a runtime/build control; security claims in the primary product/architecture docs were traced to consumers.

Scan Summary

Field Value
Scan outcome completed
Reportable findings 15
Severity mix medium: 10, low: 5
Confidence mix high: 15
Coverage partial
Validation mode Every worker candidate checkpointed before one parent source validation; duplicates merged only when root cause and remediation matched.

Canonical artifacts: scan-manifest.json, findings.json, and coverage.json. This report is a deterministic projection of those files.

Threat Model

Lanspread is a single-user LAN-party game-sharing desktop app plus a developer JSONL CLI and catalog publication tools. A sharing-enabled peer binds ephemeral IPv4 QUIC on all interfaces, advertises/discovers via mDNS, authenticates only the responder with SPKI-derived PeerId pinning, and serves requester-anonymous current-protocol operations. Remote availability and bytes remain subordinate to the bundled catalog. Sources: README.md:3-17; crates/lanspread-peer/src/tls.rs:51-143; crates/lanspread-peer/src/services/server.rs:74-177; crates/lanspread-peer/src/download/manifest.rs:129-185.

Assets

  • Installation Ed25519 private key and stable PeerId in Tauri AppData or CLI state-dir. Sources: crates/lanspread-peer/src/state_paths.rs:18-36; identity.rs:61-165,223-291.
  • Catalog authority: game.db, compact content index, canonical manifest paths/sizes/BLAKE3 and Stream Install outputs. Sources: crates/lanspread-compat/src/catalog_bundle.rs:50-82,169-233; crates/lanspread-db/src/content_manifest/bundle.rs:20-124.
  • Configured game storage, user-owned local installs, version sentinel, staging/backup, install intent, and download ownership journals. Sources: crates/lanspread-peer/ARCHITECTURE.md:202-260.
  • Authenticated endpoint generations, runtime sessions, library/Call-to-Play projections, and application availability.
  • Tauri native command/plugin authority and Windows administrator process boundary.
  • Catalog package/build provenance and checked-in opaque unrar sidecars.

Trust Boundaries

  • Anonymous LAN requester -> QUIC server: TLS authenticates the responder only; global frame/task/transfer controls and sharing state govern admission. Sources: tls.rs:126-143; services/server.rs:31-365; services/stream.rs:34-303.
  • mDNS hint -> pinned endpoint: claimed PeerId/address occupies bounded candidate work; only a pinned full pull commits state. Sources: services/discovery.rs:30-61,233-259; services/remote_state.rs:147-275.
  • Pinned snapshot -> peer database and Call-to-Play: endpoint generation, runtime session, revision and independent domain validation gate commit.
  • Remote availability/bytes -> local catalog -> confined filesystem: peers never choose expected paths/hashes; complete catalog manifests and no-follow capabilities gate reads/writes.
  • Stream Install frames -> verified staging: catalog archive/output shape, size and digest must match before promotion; ordinary install is a materially different path.
  • Main/auxiliary Tauri webviews -> registered native commands/plugins; bundled content and localhost development content both have CSP null.
  • User-selected game directory -> backend canonical acknowledgement -> scanner/downloader/installer/Windows launcher.
  • Catalog/package operator -> publisher shell recipes -> Rust publisher/unrar -> production manifest/bundle authority.
  • Catalog or mutable game scripts -> Windows cmd.exe runas after local action/UAC.
  • AppData/state-dir -> identity, policy, logs, migration and recovery consumers.

Attacker Capabilities

  • Same-LAN host may advertise arbitrary identities/endpoints, operate valid self-issued identities, send anonymous requests/hints, and control its own snapshots/transfer bytes, but not forge another PeerId or local catalog hashes.
  • Local/shared-filesystem actor may populate a user-selected games/package directory but does not initially control AppData, build operator credentials, or victim UAC decision.
  • Local CLI stdin controller is operator authority and is not modeled as a remote attacker.
  • Compromised renderer is conditional; no current hostile-peer XSS or remote-navigation route was established.
  • Package/CI input supplier may influence documented recipe arguments where an operator passes them through.

Security Objectives

  • Pin every outbound responder to the expected Ed25519 SPKI-derived PeerId and TLS 1.3 proof.
  • When sharing is disabled, close admission, drain network generations, and clear remote projections.
  • Treat mDNS, hints and payload claims as non-authoritative until a pinned pull and current generation/session commit.
  • Accept only protocol 8 with strict bounded decoding and no compatibility fallback.
  • Keep remote bytes subordinate to local catalog ContentId/path/size/BLAKE3 authority.
  • Confine file reads/writes/deletes to canonical game roots and preserve unknown/user-owned content outside explicit operations.
  • Bound public work before allocation and apply fair quotas to attacker-multipliable identities/origins.
  • Keep fixture authority out of production builds and make catalog publication fail closed.
  • Bind elevated process launch to verified immutable content.
  • Keep process/task shutdown structured and joined.

Assumptions

  • Requester anonymity while Local network sharing is enabled is intentional product behavior; responder identity, not membership, is authenticated.
  • Missing sharing policy defaults to enabled, while malformed/unreadable policy fails disabled and no game directory prevents peer startup.
  • The current production game.db has 186 rows but the production manifests and external package corpus are absent, so their aggregate size/provenance cannot be verified.
  • Tauri AppData/Resource absolute paths are platform-owned; logical child paths are source-backed.
  • Windows UAC policy, firewall/LAN segmentation, physical-LAN behavior and cross-user directory ACLs are deployment prerequisites.
  • Checked-in unrar binaries were inspected as opaque binary data and hashed, but source-to-binary/upstream provenance is unresolved.
  • Docker peer CLI and Python scenario tools are developer/test surfaces, not production requester APIs.
  • No source-backed frontend script injection, raw HTML, eval, or remote navigation path was found.
  • Windows game/server scripts are elevated by source but this privilege transition is not documented in README/ARCHITECTURE.

Findings

Finding Severity Confidence Detailed write-up
Anonymous LAN requesters can monopolize global pools and native extractors medium high inline below
Rejected bulk requests can populate the persistent manifest cache medium high inline below
Ordinary install extracts uncatalogued root archives without output verification medium high inline below
Sybil sources can multiply one chunk deadline into a multi-hour retry loop medium high inline below
One peer can force continuous rendering of thousands of active calls medium high inline below
Control-frame prefixes can reserve about 512 MiB across concurrent decoders medium high inline below
Catalog/build recipe arguments are interpolated as shell code medium high inline below
Sybil peers can exhaust aggregate state and unbounded UI publication medium high inline below
Unauthenticated hints can make the victim pull arbitrary known peers medium high inline below
Mutable game scripts are launched elevated without launch-time trust binding medium high inline below
Selected game directories can trigger unbounded monitoring and migration work low high inline below
Public state helpers permit marker writes outside the state directory low high inline below
Catalog preflight can read outside the package root through links and Windows races low high inline below
Cross-author event-ID collisions can suppress Call-to-Play entries low high inline below
Forged mDNS candidates can monopolize discovery slots low high inline below

Confidence Scale

Label Meaning
high Direct evidence supports the finding with no material unresolved blocker.
medium Evidence supports a plausible issue, but material runtime or reachability proof remains.
low Evidence is incomplete and the item is retained only for explicit follow-up.

[1] Anonymous LAN requesters can monopolize global pools and native extractors

Field Value
Severity medium
Confidence high
Confidence rationale No-client-auth, global-only semaphores, request dispatch, and per-request provider execution are explicit.
Category resource-exhaustion
CWE CWE-400
Affected lines crates/lanspread-peer/src/tls.rs:126-133, crates/lanspread-peer/src/services/server.rs:31-44, crates/lanspread-peer/src/services/stream.rs:70-89, crates/lanspread-peer/src/stream_install.rs:387-414

Summary

The responder authenticates no client and applies only global connection, control, and bulk limits, so one origin can occupy every admission slot and drive up to 48 concurrent StreamInstall operations with native unrar work.

Root Cause

Anonymous requester admission is protected only by finite global pools; expensive StreamInstall provider work has no smaller global or per-origin quota.

Server accepts anonymous requesters — crates/lanspread-peer/src/tls.rs:126-133

Requester identity cannot support fair per-peer quotas.

let mut config = ServerConfig::builder_with_provider(provider)
    .with_protocol_versions(&[&rustls::version::TLS13])?
    .with_no_client_auth()
    .with_single_cert(...)?;

Admission budgets are global — crates/lanspread-peer/src/services/server.rs:31-44

One origin can consume every shared slot.

const MAX_ESTABLISHED_CONNECTIONS: usize = 64;
const MAX_CONTROL_STREAM_TASKS: usize = 32;
const MAX_GLOBAL_CONTROL_STREAM_TASKS: usize = 64;
const MAX_GLOBAL_BULK_TRANSFER_TASKS: usize = 48;

Each bulk request independently takes the shared pool — crates/lanspread-peer/src/services/stream.rs:70-89

There is no source-address, requester, game, or expensive-provider quota.

let bulk_permit = Arc::clone(&bulk_transfer_permits).try_acquire_owned();
drop(control_permit.take());
if let Ok(permit) = bulk_permit {
    _bulk_permit = Some(permit);
    ...
}

Stream Install starts native archive processing — crates/lanspread-peer/src/stream_install.rs:387-414

Each admitted operation can start native listing and later decompression.

let process = ScopedProcess::spawn(
    program,
    ["vt", "-c-", "-p-", ...],
    cancel_token,
    LISTING_CAPTURE_LIMIT,
)?;

Validation

Validated; the separate StreamInstall-subprocess candidate is merged here because it shares anonymous global bulk admission and the same quota remediation.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Server accepts anonymous requesters — crates/lanspread-peer/src/tls.rs:126-133

Requester identity cannot support fair per-peer quotas.

let mut config = ServerConfig::builder_with_provider(provider)
    .with_protocol_versions(&[&rustls::version::TLS13])?
    .with_no_client_auth()
    .with_single_cert(...)?;

Admission budgets are global — crates/lanspread-peer/src/services/server.rs:31-44

One origin can consume every shared slot.

const MAX_ESTABLISHED_CONNECTIONS: usize = 64;
const MAX_CONTROL_STREAM_TASKS: usize = 32;
const MAX_GLOBAL_CONTROL_STREAM_TASKS: usize = 64;
const MAX_GLOBAL_BULK_TRANSFER_TASKS: usize = 48;

Each bulk request independently takes the shared pool — crates/lanspread-peer/src/services/stream.rs:70-89

There is no source-address, requester, game, or expensive-provider quota.

let bulk_permit = Arc::clone(&bulk_transfer_permits).try_acquire_owned();
drop(control_permit.take());
if let Ok(permit) = bulk_permit {
    _bulk_permit = Some(permit);
    ...
}

Stream Install starts native archive processing — crates/lanspread-peer/src/stream_install.rs:387-414

Each admitted operation can start native listing and later decompression.

let process = ScopedProcess::spawn(
    program,
    ["vt", "-c-", "-p-", ...],
    cancel_token,
    LISTING_CAPTURE_LIMIT,
)?;

Assertions:

  • No client identity exists.
  • All resource permits are shared globally.
  • StreamInstall performs native work after acquiring only the general bulk permit.

Counterevidence and remaining uncertainty:

  • Handshake, connection, control, and bulk counts are finite.
  • Control and bulk pools are separated.
  • Stalled work has application timeouts and cancellation.

Dataflow

Anonymous QUIC connection -> global stream/bulk permit -> request handler -> file handles or unrar subprocesses.

  • Source: Same-LAN client requests.

  • Sink: Global peer admission, bulk transfer capacity, native subprocess/CPU resources.

  • Outcome: Denial of legitimate sync/download/install service.

Server accepts anonymous requesters — crates/lanspread-peer/src/tls.rs:126-133

Requester identity cannot support fair per-peer quotas.

let mut config = ServerConfig::builder_with_provider(provider)
    .with_protocol_versions(&[&rustls::version::TLS13])?
    .with_no_client_auth()
    .with_single_cert(...)?;

Admission budgets are global — crates/lanspread-peer/src/services/server.rs:31-44

One origin can consume every shared slot.

const MAX_ESTABLISHED_CONNECTIONS: usize = 64;
const MAX_CONTROL_STREAM_TASKS: usize = 32;
const MAX_GLOBAL_CONTROL_STREAM_TASKS: usize = 64;
const MAX_GLOBAL_BULK_TRANSFER_TASKS: usize = 48;

Each bulk request independently takes the shared pool — crates/lanspread-peer/src/services/stream.rs:70-89

There is no source-address, requester, game, or expensive-provider quota.

let bulk_permit = Arc::clone(&bulk_transfer_permits).try_acquire_owned();
drop(control_permit.take());
if let Ok(permit) = bulk_permit {
    _bulk_permit = Some(permit);
    ...
}

Stream Install starts native archive processing — crates/lanspread-peer/src/stream_install.rs:387-414

Each admitted operation can start native listing and later decompression.

let process = ScopedProcess::spawn(
    program,
    ["vt", "-c-", "-p-", ...],
    cancel_token,
    LISTING_CAPTURE_LIMIT,
)?;

Reachability

Directly reachable whenever Local network sharing is enabled.

  • Attacker: Any host on the reachable LAN.

  • Entry point: QUIC listener and StreamInstall/GetGameFileChunk requests.

Preconditions:

  • Sharing enabled
  • Victim advertises or attacker learns endpoint
  • For StreamInstall, a locally available stream-capable game

Existing controls:

  • Finite global caps
  • 10-second control deadlines
  • 10-minute inactivity deadlines
  • Separate control and bulk pools

Server accepts anonymous requesters — crates/lanspread-peer/src/tls.rs:126-133

Requester identity cannot support fair per-peer quotas.

let mut config = ServerConfig::builder_with_provider(provider)
    .with_protocol_versions(&[&rustls::version::TLS13])?
    .with_no_client_auth()
    .with_single_cert(...)?;

Admission budgets are global — crates/lanspread-peer/src/services/server.rs:31-44

One origin can consume every shared slot.

const MAX_ESTABLISHED_CONNECTIONS: usize = 64;
const MAX_CONTROL_STREAM_TASKS: usize = 32;
const MAX_GLOBAL_CONTROL_STREAM_TASKS: usize = 64;
const MAX_GLOBAL_BULK_TRANSFER_TASKS: usize = 48;

Each bulk request independently takes the shared pool — crates/lanspread-peer/src/services/stream.rs:70-89

There is no source-address, requester, game, or expensive-provider quota.

let bulk_permit = Arc::clone(&bulk_transfer_permits).try_acquire_owned();
drop(control_permit.take());
if let Ok(permit) = bulk_permit {
    _bulk_permit = Some(permit);
    ...
}

Stream Install starts native archive processing — crates/lanspread-peer/src/stream_install.rs:387-414

Each admitted operation can start native listing and later decompression.

let process = ScopedProcess::spawn(
    program,
    ["vt", "-c-", "-p-", ...],
    cancel_token,
    LISTING_CAPTURE_LIMIT,
)?;

Severity

Medium — A same-LAN attacker can reliably deny synchronization and transfers and impose expensive native work, but all pools are finite and the attack must be sustained.

Severity increases on memory-constrained hosts or archives with expensive decompression.

Impact assessment:

  • Level: medium
  • Rationale: Availability is lost and host resources are pressured; file integrity remains catalog-protected.

Likelihood assessment:

  • Level: high
  • Rationale: Only ordinary LAN reachability and sustained requests are required.

Remediation

Add per-source connection/stream/rate quotas, close origins after repeated timeouts, reserve capacity across origins, place unrar behind a small global and per-origin semaphore, and enforce absolute transfer deadlines.

[2] Rejected bulk requests can populate the persistent manifest cache

Field Value
Severity medium
Confidence high
Confidence rationale Call order and unbounded cache insertion are direct; the missing production bodies only limit measurement.
Category resource-exhaustion
CWE CWE-400
Affected lines crates/lanspread-peer/src/services/transfer.rs:258-321, crates/lanspread-db/src/content_manifest/store.rs:162-186

Summary

Both bulk request variants load and retain a full catalog manifest before checking compact ContentId equality or whether the game is locally serveable.

Root Cause

Bulk admission uses the disk-capable on-demand manifest API before the compact index and preloaded local-library cache can reject the request.

Full body loads precede rejection — crates/lanspread-peer/src/services/transfer.rs:270-284

A wrong ContentId or nonlocal known game still causes a body load.

let manifest = load_expected_catalog_manifest(ctx, game_id)?;
if manifest.content_id() != content_id { return None; }
if !can_serve_game(ctx, &game_dir, game_id).await { return None; }

Stream Install repeats the ordering — crates/lanspread-peer/src/services/transfer.rs:308-319

Both independent network operations are affected.

let manifest = load_expected_catalog_manifest(ctx, game_id)?;
if manifest.content_id() != content_id { return None; }
if !can_serve_game(ctx, &game_dir, game_id).await || !manifest.supports_streamed_install() { return None; }

Every miss is retained — crates/lanspread-db/src/content_manifest/store.rs:162-186

No entry/byte eviction applies to cumulative remote-triggered loads.

let manifest = Arc::new(self.load_uncached(game_id, expected_version)?);
let mut cache = self.cache.write()?;
Ok(cache.entry(game_id.to_owned()).or_insert_with(|| Arc::clone(&manifest)).clone())

Validation

Validated. Known IDs and per-body limits bound the universe, but do not enforce the documented no-I/O rejection or an aggregate retained-byte limit.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Full body loads precede rejection — crates/lanspread-peer/src/services/transfer.rs:270-284

A wrong ContentId or nonlocal known game still causes a body load.

let manifest = load_expected_catalog_manifest(ctx, game_id)?;
if manifest.content_id() != content_id { return None; }
if !can_serve_game(ctx, &game_dir, game_id).await { return None; }

Stream Install repeats the ordering — crates/lanspread-peer/src/services/transfer.rs:308-319

Both independent network operations are affected.

let manifest = load_expected_catalog_manifest(ctx, game_id)?;
if manifest.content_id() != content_id { return None; }
if !can_serve_game(ctx, &game_dir, game_id).await || !manifest.supports_streamed_install() { return None; }

Every miss is retained — crates/lanspread-db/src/content_manifest/store.rs:162-186

No entry/byte eviction applies to cumulative remote-triggered loads.

let manifest = Arc::new(self.load_uncached(game_id, expected_version)?);
let mut cache = self.cache.write()?;
Ok(cache.entry(game_id.to_owned()).or_insert_with(|| Arc::clone(&manifest)).clone())

Assertions:

  • The compact identity is available without filesystem I/O.
  • Both bulk variants call full load before identity/local checks.
  • Loaded bodies persist in a HashMap without eviction.

Counterevidence and remaining uncertainty:

  • Only immutable catalog IDs can load.
  • Each manifest and catalog are finite.
  • Operation admission serializes loads.
  • Production bodies are absent, so actual aggregate size was not measured.

Dataflow

Network game_id -> CatalogBundle::manifest -> bounded disk read/parse -> persistent cache -> later rejection.

  • Source: Unauthenticated bulk request fields.

  • Sink: Process heap, manifest parser, and serialized operation-admission lock.

  • Outcome: Memory growth and denial/delay of legitimate operations.

Full body loads precede rejection — crates/lanspread-peer/src/services/transfer.rs:270-284

A wrong ContentId or nonlocal known game still causes a body load.

let manifest = load_expected_catalog_manifest(ctx, game_id)?;
if manifest.content_id() != content_id { return None; }
if !can_serve_game(ctx, &game_dir, game_id).await { return None; }

Stream Install repeats the ordering — crates/lanspread-peer/src/services/transfer.rs:308-319

Both independent network operations are affected.

let manifest = load_expected_catalog_manifest(ctx, game_id)?;
if manifest.content_id() != content_id { return None; }
if !can_serve_game(ctx, &game_dir, game_id).await || !manifest.supports_streamed_install() { return None; }

Every miss is retained — crates/lanspread-db/src/content_manifest/store.rs:162-186

No entry/byte eviction applies to cumulative remote-triggered loads.

let manifest = Arc::new(self.load_uncached(game_id, expected_version)?);
let mut cache = self.cache.write()?;
Ok(cache.entry(game_id.to_owned()).or_insert_with(|| Arc::clone(&manifest)).clone())

Reachability

Reachable for any known bundled game ID while sharing is enabled.

  • Attacker: Same-LAN anonymous requester.

  • Entry point: GetGameFileChunk and StreamInstall.

Preconditions:

  • Sharing enabled
  • Knowledge or enumeration of bundled game IDs

Existing controls:

  • 128 MiB individual manifest limit
  • Finite immutable catalog
  • Serialized operation admission

Full body loads precede rejection — crates/lanspread-peer/src/services/transfer.rs:270-284

A wrong ContentId or nonlocal known game still causes a body load.

let manifest = load_expected_catalog_manifest(ctx, game_id)?;
if manifest.content_id() != content_id { return None; }
if !can_serve_game(ctx, &game_dir, game_id).await { return None; }

Stream Install repeats the ordering — crates/lanspread-peer/src/services/transfer.rs:308-319

Both independent network operations are affected.

let manifest = load_expected_catalog_manifest(ctx, game_id)?;
if manifest.content_id() != content_id { return None; }
if !can_serve_game(ctx, &game_dir, game_id).await || !manifest.supports_streamed_install() { return None; }

Every miss is retained — crates/lanspread-db/src/content_manifest/store.rs:162-186

No entry/byte eviction applies to cumulative remote-triggered loads.

let manifest = Arc::new(self.load_uncached(game_id, expected_version)?);
let mut cache = self.cache.write()?;
Ok(cache.entry(game_id.to_owned()).or_insert_with(|| Arc::clone(&manifest)).clone())

Severity

Medium — An anonymous LAN client can force persistent corpus-wide parse/retention and serialized admission work; actual production size is unavailable, limiting impact certainty.

Severity depends on the aggregate encoded/parsed size of the external production manifest corpus.

Impact assessment:

  • Level: medium
  • Rationale: Potential process memory exhaustion and operational blocking; exact magnitude depends on external corpus.

Likelihood assessment:

  • Level: high
  • Rationale: Wrong ContentIds are sufficient and no local availability is required.

Remediation

Check content_identity and local readiness first, then require cached_manifest; add tests proving rejected requests perform no load, plus an aggregate cache budget.

[3] Ordinary install extracts uncatalogued root archives without output verification

Field Value
Severity medium
Confidence high
Confidence rationale Archive enumeration, extraction loop, promotion, and absence of a manifest argument/check are explicit.
Category content-integrity
CWE CWE-494, CWE-400
Affected lines crates/lanspread-peer/src/install/transaction.rs:449-562, crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:3195-3206, crates/lanspread-peer/src/handlers.rs:1443-1488

Summary

Install/update enumerates every root regular .eti file—including unknown files deliberately preserved beside downloads—runs native extraction for each, and promotes the staging tree without comparing the archive set or extracted output to the local catalog.

Root Cause

The ordinary install path predates the catalog-owned archive/output contract used by Stream Install and treats filename extension plus extractor success as content authority.

Every root .eti is selected — crates/lanspread-peer/src/install/transaction.rs:514-562

No local manifest archive-set, size, or digest check precedes native parsing.

let archives = root_eti_archives(game_root)?;
...
for archive in archives {
    unpacker.unpack(&archive, staging, cancel_token.clone()).await?;
}
...
if path.extension().is_some_and(|extension| extension == "eti") {
    archives.push(path);
}

Staging is promoted after extractor success only — crates/lanspread-peer/src/install/transaction.rs:449-468

Ordinary install does not receive or verify the catalog's extracted-output manifest.

prepare_owned_empty_dir(&staging)?;
unpack_archives(game_root, &staging, unpacker, cancel_token).await?;
rename_path(&staging, &local)?;

Tauri runs native extraction into staging — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:3195-3206

The executable is fixed, but archive bytes and decompression cost cross a native parser boundary.

ScopedProcess::spawn(
    program,
    ["x", "-p-", paths.archive.as_os_str(), "-y", "-o", &paths.destination_arg],
    &registration.cancel_token(),
    UNRAR_LOG_CAPTURE_LIMIT,
)

Validation

Validated. Remote downloads cannot add unknown files, but the selected/shared filesystem is an explicit untrusted boundary and unknown files are preserved by download ownership.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Every root .eti is selected — crates/lanspread-peer/src/install/transaction.rs:514-562

No local manifest archive-set, size, or digest check precedes native parsing.

let archives = root_eti_archives(game_root)?;
...
for archive in archives {
    unpacker.unpack(&archive, staging, cancel_token.clone()).await?;
}
...
if path.extension().is_some_and(|extension| extension == "eti") {
    archives.push(path);
}

Staging is promoted after extractor success only — crates/lanspread-peer/src/install/transaction.rs:449-468

Ordinary install does not receive or verify the catalog's extracted-output manifest.

prepare_owned_empty_dir(&staging)?;
unpack_archives(game_root, &staging, unpacker, cancel_token).await?;
rename_path(&staging, &local)?;

Tauri runs native extraction into staging — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:3195-3206

The executable is fixed, but archive bytes and decompression cost cross a native parser boundary.

ScopedProcess::spawn(
    program,
    ["x", "-p-", paths.archive.as_os_str(), "-y", "-o", &paths.destination_arg],
    &registration.cancel_token(),
    UNRAR_LOG_CAPTURE_LIMIT,
)

Assertions:

  • Install admission can proceed with an untracked but sentinel-bearing root.
  • Every root .eti is extracted.
  • No extracted-output verification occurs before promotion.

Counterevidence and remaining uncertainty:

  • Catalog-downloaded archive bytes are chunk-hash verified.
  • Symlink/reparse roots are rejected.
  • The sidecar path and argv grammar are fixed.
  • Outside-root archive behavior of opaque unrar was not claimed.

Dataflow

Selected game root files -> extension enumeration -> native unrar -> staging -> local promotion.

  • Source: Locally/shared-root controlled regular .eti file.

  • Sink: Installed local/ tree and native extraction resources.

  • Outcome: Uncatalogued installed bytes and decompression resource exhaustion.

Every root .eti is selected — crates/lanspread-peer/src/install/transaction.rs:514-562

No local manifest archive-set, size, or digest check precedes native parsing.

let archives = root_eti_archives(game_root)?;
...
for archive in archives {
    unpacker.unpack(&archive, staging, cancel_token.clone()).await?;
}
...
if path.extension().is_some_and(|extension| extension == "eti") {
    archives.push(path);
}

Staging is promoted after extractor success only — crates/lanspread-peer/src/install/transaction.rs:449-468

Ordinary install does not receive or verify the catalog's extracted-output manifest.

prepare_owned_empty_dir(&staging)?;
unpack_archives(game_root, &staging, unpacker, cancel_token).await?;
rename_path(&staging, &local)?;

Tauri runs native extraction into staging — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:3195-3206

The executable is fixed, but archive bytes and decompression cost cross a native parser boundary.

ScopedProcess::spawn(
    program,
    ["x", "-p-", paths.archive.as_os_str(), "-y", "-o", &paths.destination_arg],
    &registration.cancel_token(),
    UNRAR_LOG_CAPTURE_LIMIT,
)

Reachability

Requires write influence over the selected game root and local install/update action.

  • Attacker: Local/shared-filesystem actor.

  • Entry point: InstallGame/Update path after catalog ID and version sentinel checks.

Preconditions:

  • Catalog game root with version.ini
  • Attacker-controlled extra .eti
  • Victim install/update

Existing controls:

  • Catalog validation for downloaded files
  • Fixed unrar executable/argv
  • Transactional staging
  • Link/reparse rejection

Every root .eti is selected — crates/lanspread-peer/src/install/transaction.rs:514-562

No local manifest archive-set, size, or digest check precedes native parsing.

let archives = root_eti_archives(game_root)?;
...
for archive in archives {
    unpacker.unpack(&archive, staging, cancel_token.clone()).await?;
}
...
if path.extension().is_some_and(|extension| extension == "eti") {
    archives.push(path);
}

Staging is promoted after extractor success only — crates/lanspread-peer/src/install/transaction.rs:449-468

Ordinary install does not receive or verify the catalog's extracted-output manifest.

prepare_owned_empty_dir(&staging)?;
unpack_archives(game_root, &staging, unpacker, cancel_token).await?;
rename_path(&staging, &local)?;

Tauri runs native extraction into staging — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:3195-3206

The executable is fixed, but archive bytes and decompression cost cross a native parser boundary.

ScopedProcess::spawn(
    program,
    ["x", "-p-", paths.archive.as_os_str(), "-y", "-o", &paths.destination_arg],
    &registration.cancel_token(),
    UNRAR_LOG_CAPTURE_LIMIT,
)

Severity

Medium — A crafted selected/shared game root can bypass installed-content integrity and exhaust disk/CPU; exploitation needs local/shared-root influence and a user install/update action.

Severity increases if unverified extracted binaries are later executed by elevated catalog scripts or if the selected game directory is remotely writable.

Impact assessment:

  • Level: medium
  • Rationale: Installed content integrity and host availability are affected; direct remote or outside-root write is not established.

Likelihood assessment:

  • Level: medium
  • Rationale: Requires local/shared-directory placement but extraction is deterministic after user action.

Remediation

Pass the exact catalog manifest into install/update; require the exact root archive set and verify each archive size/BLAKE3 through no-follow handles; verify every extracted path/kind/size/digest before promotion; enforce entry/decompressed-byte/total deadlines.

[4] Sybil sources can multiply one chunk deadline into a multi-hour retry loop

Field Value
Severity medium
Confidence high
Confidence rationale The full-source retry loop, retry classification, peer cap, and per-attempt deadline are explicit.
Category resource-exhaustion
CWE CWE-400
Affected lines crates/lanspread-peer/src/download/retry.rs:294-327, crates/lanspread-peer/src/download/transport.rs:34, crates/lanspread-peer/src/peer_db.rs:654-667

Summary

A download retries every distinct peer identity with no numeric or total deadline; transport stalls remain retryable and each of up to 64 Sybil sources receives a fresh ten-minute chunk deadline.

Root Cause

The retry budget is defined per identity rather than per chunk/download, while identities are cheap and attacker-multipliable.

Retries exhaust the complete source set — crates/lanspread-peer/src/download/retry.rs:294-327

Identity multiplicity directly controls total operation duration.

/// Retries failed chunks against every eligible, nonquarantined peer identity.
/// Each source is attempted at most once per chunk. There is no numeric retry cap.
...
while !queue.is_empty() { ... }

Transport stalls are retryable — crates/lanspread-peer/src/download/retry.rs:192-219

A stalling source is not quarantined and advances to the next identity.

match kind {
    DownloadTransferErrorKind::Integrity | DownloadTransferErrorKind::Transport => {
        retry.last_error = error;
        queue.push_back(retry);
    }
    ...
}

Each source gets a fresh ten-minute deadline — crates/lanspread-peer/src/download/transport.rs:34

Sixty-four distinct identities can multiply the per-attempt deadline to about 640 minutes.

const ORDINARY_CHUNK_TRANSFER_TIMEOUT: Duration = Duration::from_mins(10);

Validation

Validated; exact content verification prevents corrupt acceptance but not operation-lifetime exhaustion.

Validation method: Static trace of source selection, transport failure policy, retry termination, and per-attempt deadline.

  • Status: validated
  • Disposition: reportable

Retries exhaust the complete source set — crates/lanspread-peer/src/download/retry.rs:294-327

Identity multiplicity directly controls total operation duration.

/// Retries failed chunks against every eligible, nonquarantined peer identity.
/// Each source is attempted at most once per chunk. There is no numeric retry cap.
...
while !queue.is_empty() { ... }

Transport stalls are retryable — crates/lanspread-peer/src/download/retry.rs:192-219

A stalling source is not quarantined and advances to the next identity.

match kind {
    DownloadTransferErrorKind::Integrity | DownloadTransferErrorKind::Transport => {
        retry.last_error = error;
        queue.push_back(retry);
    }
    ...
}

Each source gets a fresh ten-minute deadline — crates/lanspread-peer/src/download/transport.rs:34

Sixty-four distinct identities can multiply the per-attempt deadline to about 640 minutes.

const ORDINARY_CHUNK_TRANSFER_TIMEOUT: Duration = Duration::from_mins(10);

Assertions:

  • Up to 64 exact-content claimants enter the source set.
  • Every identity can be attempted once.
  • Transport stalls requeue.
  • Each attempt gets ten minutes.

Counterevidence and remaining uncertainty:

  • Source count is capped at 64.
  • Integrity failures quarantine the peer/content pair.
  • User cancellation drains children and rolls back.

Dataflow

Sybil availability claims -> exact-content source vector -> sequential retry batches -> fresh ten-minute deadline per identity.

  • Source: Attacker-controlled PeerIds/endpoints.

  • Sink: Active download transaction, preallocated storage, and network tasks.

  • Outcome: Multi-hour denial of a game download.

Retries exhaust the complete source set — crates/lanspread-peer/src/download/retry.rs:294-327

Identity multiplicity directly controls total operation duration.

/// Retries failed chunks against every eligible, nonquarantined peer identity.
/// Each source is attempted at most once per chunk. There is no numeric retry cap.
...
while !queue.is_empty() { ... }

Transport stalls are retryable — crates/lanspread-peer/src/download/retry.rs:192-219

A stalling source is not quarantined and advances to the next identity.

match kind {
    DownloadTransferErrorKind::Integrity | DownloadTransferErrorKind::Transport => {
        retry.last_error = error;
        queue.push_back(retry);
    }
    ...
}

Each source gets a fresh ten-minute deadline — crates/lanspread-peer/src/download/transport.rs:34

Sixty-four distinct identities can multiply the per-attempt deadline to about 640 minutes.

const ORDINARY_CHUNK_TRANSFER_TIMEOUT: Duration = Duration::from_mins(10);

Reachability

Requires a user-started download and many authenticated Sybil sources claiming the expected local catalog ContentId.

  • Attacker: Malicious same-LAN host.

  • Entry point: Remote library snapshots and ordinary chunk transport.

Preconditions:

  • User starts download
  • Up to 64 Sybil peers claim exact ContentId
  • Sources stall/fail transport

Existing controls:

  • 64-peer cap
  • one attempt per identity
  • integrity quarantine
  • user cancellation

Retries exhaust the complete source set — crates/lanspread-peer/src/download/retry.rs:294-327

Identity multiplicity directly controls total operation duration.

/// Retries failed chunks against every eligible, nonquarantined peer identity.
/// Each source is attempted at most once per chunk. There is no numeric retry cap.
...
while !queue.is_empty() { ... }

Severity

Medium — A hostile LAN host can hold a user-started operation for roughly 640 minutes, but the source count is finite and cancellation remains available.

Additional runtime or deployment evidence could raise or lower this severity.

Impact assessment:

  • Level: medium
  • Rationale: One game operation can be held for many hours and consumes resources.

Likelihood assessment:

  • Level: medium
  • Rationale: Requires many identities plus a local user-started download.

Remediation

Add total per-chunk/download wall-clock and attempt budgets independent of source count, cap automatically tried identities, add per-origin identity quotas, and require explicit user retry after budget exhaustion.

[5] One peer can force continuous rendering of thousands of active calls

Field Value
Severity medium
Confidence high
Confidence rationale The semantic validation, one-second recomputation, and full list rendering are explicit.
Category resource-exhaustion
CWE CWE-400
Affected lines crates/lanspread-proto/src/lib.rs:17-20, crates/lanspread-tauri-deno-ts/src/hooks/useCallToPlay.ts:68-72, crates/lanspread-tauri-deno-ts/src/components/calltoplay/CallToPlayTicker.tsx:80-154

Summary

A valid 4,096-event author slice can contain thousands of simultaneous Create roots; the frontend reduces and sorts the full set every second and renders every nomination in the always-mounted ticker.

Root Cause

Wire-level event/byte limits are used as the only semantic and rendering budget; active roots and DOM rows have no smaller cap.

A single author may publish 4096 events — crates/lanspread-proto/src/lib.rs:17-20

The wire cap is not a smaller semantic active-call/display cap.

pub const MAX_CALL_TO_PLAY_EVENTS_PER_AUTHOR: usize = 4_096;
pub const MAX_CALL_TO_PLAY_AUTHOR_SNAPSHOT_BYTES: usize = 4 * 1024 * 1024;

Full reduction reruns each second — crates/lanspread-tauri-deno-ts/src/hooks/useCallToPlay.ts:68-72

now is a dependency of the complete call reduction.

const timer = window.setInterval(() => {
    setNow(Date.now());
}, 1_000);

Ticker renders every nomination — crates/lanspread-tauri-deno-ts/src/components/calltoplay/CallToPlayTicker.tsx:80-94

There is no pagination, virtualization, or visible-row cap in the always-mounted ticker.

const rows = nominations.map(nomination => ({ nomination, status: tickerStatusOf(nomination, now) })).sort(...);
...
{rows.map(({ nomination, status }) => {

Validation

Validated as distinct from aggregate Sybil retention: one identity and one maximal valid slice are sufficient.

Validation method: Static source trace of maximal valid author state through the Rust projection and frontend render loop.

  • Status: validated
  • Disposition: reportable

A single author may publish 4096 events — crates/lanspread-proto/src/lib.rs:17-20

The wire cap is not a smaller semantic active-call/display cap.

pub const MAX_CALL_TO_PLAY_EVENTS_PER_AUTHOR: usize = 4_096;
pub const MAX_CALL_TO_PLAY_AUTHOR_SNAPSHOT_BYTES: usize = 4 * 1024 * 1024;

Full reduction reruns each second — crates/lanspread-tauri-deno-ts/src/hooks/useCallToPlay.ts:68-72

now is a dependency of the complete call reduction.

const timer = window.setInterval(() => {
    setNow(Date.now());
}, 1_000);

Ticker renders every nomination — crates/lanspread-tauri-deno-ts/src/components/calltoplay/CallToPlayTicker.tsx:80-94

There is no pagination, virtualization, or visible-row cap in the always-mounted ticker.

const rows = nominations.map(nomination => ({ nomination, status: tickerStatusOf(nomination, now) })).sort(...);
...
{rows.map(({ nomination, status }) => {

Assertions:

  • 4096 valid Create events can represent 4096 active calls.
  • Full reduction reruns each second.
  • All nominations are rendered.

Counterevidence and remaining uncertainty:

  • Snapshot size and event count are finite.
  • Expired/terminal retention exists.
  • Per-card participant count is bounded.

Dataflow

Pinned author snapshot -> Rust CallToPlayView -> reducer -> one-second recomputation -> full ticker/overlay render.

  • Source: Attacker-controlled valid Create events.

  • Sink: Main renderer CPU, heap, and DOM.

  • Outcome: Unresponsive launcher.

A single author may publish 4096 events — crates/lanspread-proto/src/lib.rs:17-20

The wire cap is not a smaller semantic active-call/display cap.

pub const MAX_CALL_TO_PLAY_EVENTS_PER_AUTHOR: usize = 4_096;
pub const MAX_CALL_TO_PLAY_AUTHOR_SNAPSHOT_BYTES: usize = 4 * 1024 * 1024;

Full reduction reruns each second — crates/lanspread-tauri-deno-ts/src/hooks/useCallToPlay.ts:68-72

now is a dependency of the complete call reduction.

const timer = window.setInterval(() => {
    setNow(Date.now());
}, 1_000);

Ticker renders every nomination — crates/lanspread-tauri-deno-ts/src/components/calltoplay/CallToPlayTicker.tsx:80-94

There is no pagination, virtualization, or visible-row cap in the always-mounted ticker.

const rows = nominations.map(nomination => ({ nomination, status: tickerStatusOf(nomination, now) })).sort(...);
...
{rows.map(({ nomination, status }) => {

Reachability

Requires one connected hostile peer while sharing is enabled; no local click is needed after synchronization.

  • Attacker: Authenticated hostile LAN peer.

  • Entry point: HelloSnapshot Call-to-Play slice.

Preconditions:

  • Sharing enabled
  • Valid 4096-event author snapshot

Existing controls:

  • 4096-event limit
  • 4 MiB author snapshot limit
  • retention windows

A single author may publish 4096 events — crates/lanspread-proto/src/lib.rs:17-20

The wire cap is not a smaller semantic active-call/display cap.

pub const MAX_CALL_TO_PLAY_EVENTS_PER_AUTHOR: usize = 4_096;
pub const MAX_CALL_TO_PLAY_AUTHOR_SNAPSHOT_BYTES: usize = 4 * 1024 * 1024;

Severity

Medium — One authenticated LAN peer can freeze the renderer without further user interaction, but protocol byte/event limits bound the state.

Additional runtime or deployment evidence could raise or lower this severity.

Impact assessment:

  • Level: medium
  • Rationale: UI availability can be lost without native compromise.

Likelihood assessment:

  • Level: high
  • Rationale: One attacker identity can generate the valid event set.

Remediation

Enforce small per-author/global active-call caps before publication, render only a ranked ticker subset, virtualize/paginate the overlay, and avoid recomputing unchanged projections on every clock tick.

[6] Control-frame prefixes can reserve about 512 MiB across concurrent decoders

Field Value
Severity medium
Confidence high
Confidence rationale Repository concurrency/frame limits and the locked dependency's reserve behavior were inspected offline.
Category resource-exhaustion
CWE CWE-400
Affected lines crates/lanspread-proto/src/lib.rs:13-20, crates/lanspread-peer/src/services/server.rs:31-41, crates/lanspread-peer/src/services/stream.rs:37-67, crates/lanspread-peer/src/services/discovery.rs:30-32, Cargo.lock:4655-4659

Summary

The same 8 MiB control-frame allowance is multiplied across 64 concurrent inbound request decoders and 64 discovery Hello decoders; locked tokio-util eagerly reserves the declared body after only the length prefix.

Root Cause

A response-sized per-frame maximum is applied independently to many untrusted decoders without an aggregate receive-memory budget or incremental allocation.

Every control codec permits 8 MiB — crates/lanspread-proto/src/lib.rs:13-14

Inbound requests are much smaller, but share the response-sized maximum.

pub const MAX_CONTROL_FRAME_BYTES: usize = 8 * 1024 * 1024;
pub const MAX_STREAM_INSTALL_FRAME_BYTES: usize = 8 * 1024 * 1024;

Server admits 64 global decoders — crates/lanspread-peer/src/services/server.rs:31-41

Two connections can populate all 64 stream tasks.

const MAX_CONTROL_STREAM_TASKS: usize = 32;
const MAX_GLOBAL_CONTROL_STREAM_TASKS: usize = 64;

Decoder uses the shared maximum before parsing — crates/lanspread-peer/src/services/stream.rs:37-67

The whole declared body is awaited before Request::decode.

LengthDelimitedCodec::builder()
    .max_frame_length(MAX_CONTROL_FRAME_BYTES)
    .new_codec()
...
let first_frame = read_expected_frame(...).await;

Locked decoder version — Cargo.lock:4655-4659

Offline inspection of this locked source confirmed src.reserve(n.saturating_sub(src.len())) after decoding the header.

[[package]]
name = "tokio-util"
version = "0.7.19"
checksum = "494815d09bf52b5548659851081238f0ca39ff638363907596da739561c62c52"

Validation

Validated and merged with the discovery-prefix instance because both use the same locked decoder behavior and aggregate-budget failure.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Every control codec permits 8 MiB — crates/lanspread-proto/src/lib.rs:13-14

Inbound requests are much smaller, but share the response-sized maximum.

pub const MAX_CONTROL_FRAME_BYTES: usize = 8 * 1024 * 1024;
pub const MAX_STREAM_INSTALL_FRAME_BYTES: usize = 8 * 1024 * 1024;

Server admits 64 global decoders — crates/lanspread-peer/src/services/server.rs:31-41

Two connections can populate all 64 stream tasks.

const MAX_CONTROL_STREAM_TASKS: usize = 32;
const MAX_GLOBAL_CONTROL_STREAM_TASKS: usize = 64;

Decoder uses the shared maximum before parsing — crates/lanspread-peer/src/services/stream.rs:37-67

The whole declared body is awaited before Request::decode.

LengthDelimitedCodec::builder()
    .max_frame_length(MAX_CONTROL_FRAME_BYTES)
    .new_codec()
...
let first_frame = read_expected_frame(...).await;

Locked decoder version — Cargo.lock:4655-4659

Offline inspection of this locked source confirmed src.reserve(n.saturating_sub(src.len())) after decoding the header.

[[package]]
name = "tokio-util"
version = "0.7.19"
checksum = "494815d09bf52b5548659851081238f0ca39ff638363907596da739561c62c52"

Assertions:

  • 64 multiplied by 8 MiB is 512 MiB before overhead.
  • Only four prefix bytes are needed before tokio-util reserves.
  • Inbound and discovery response paths both use the shared maximum.

Counterevidence and remaining uncertainty:

  • Global task/candidate caps bound a single wave.
  • Ten-second deadlines release stalled decoders.
  • Discovery identities must authenticate as themselves, though inbound clients are anonymous.

Dataflow

Length prefix -> LengthDelimitedCodec header decode -> eager BytesMut reserve -> incomplete frame wait.

  • Source: Unauthenticated inbound clients or attacker-operated discovery responders.

  • Sink: Desktop heap and every global control/discovery slot.

  • Outcome: Abrupt memory pressure, swapping, or process termination.

Every control codec permits 8 MiB — crates/lanspread-proto/src/lib.rs:13-14

Inbound requests are much smaller, but share the response-sized maximum.

pub const MAX_CONTROL_FRAME_BYTES: usize = 8 * 1024 * 1024;
pub const MAX_STREAM_INSTALL_FRAME_BYTES: usize = 8 * 1024 * 1024;

Server admits 64 global decoders — crates/lanspread-peer/src/services/server.rs:31-41

Two connections can populate all 64 stream tasks.

const MAX_CONTROL_STREAM_TASKS: usize = 32;
const MAX_GLOBAL_CONTROL_STREAM_TASKS: usize = 64;

Decoder uses the shared maximum before parsing — crates/lanspread-peer/src/services/stream.rs:37-67

The whole declared body is awaited before Request::decode.

LengthDelimitedCodec::builder()
    .max_frame_length(MAX_CONTROL_FRAME_BYTES)
    .new_codec()
...
let first_frame = read_expected_frame(...).await;

Locked decoder version — Cargo.lock:4655-4659

Offline inspection of this locked source confirmed src.reserve(n.saturating_sub(src.len())) after decoding the header.

[[package]]
name = "tokio-util"
version = "0.7.19"
checksum = "494815d09bf52b5548659851081238f0ca39ff638363907596da739561c62c52"

Reachability

Inbound requires listener access; discovery requires 64 advertised identities/endpoints with matching keys.

  • Attacker: Same-LAN participant.

  • Entry point: Server bidirectional streams and discovery Hello responses.

Preconditions:

  • Sharing/discovery enabled
  • Concurrent streams or candidates

Existing controls:

  • 64-decoder/candidate caps
  • 10-second application deadlines
  • QUIC transport limits

Every control codec permits 8 MiB — crates/lanspread-proto/src/lib.rs:13-14

Inbound requests are much smaller, but share the response-sized maximum.

pub const MAX_CONTROL_FRAME_BYTES: usize = 8 * 1024 * 1024;
pub const MAX_STREAM_INSTALL_FRAME_BYTES: usize = 8 * 1024 * 1024;

Server admits 64 global decoders — crates/lanspread-peer/src/services/server.rs:31-41

Two connections can populate all 64 stream tasks.

const MAX_CONTROL_STREAM_TASKS: usize = 32;
const MAX_GLOBAL_CONTROL_STREAM_TASKS: usize = 64;

Decoder uses the shared maximum before parsing — crates/lanspread-peer/src/services/stream.rs:37-67

The whole declared body is awaited before Request::decode.

LengthDelimitedCodec::builder()
    .max_frame_length(MAX_CONTROL_FRAME_BYTES)
    .new_codec()
...
let first_frame = read_expected_frame(...).await;

Locked decoder version — Cargo.lock:4655-4659

Offline inspection of this locked source confirmed src.reserve(n.saturating_sub(src.len())) after decoding the header.

[[package]]
name = "tokio-util"
version = "0.7.19"
checksum = "494815d09bf52b5548659851081238f0ca39ff638363907596da739561c62c52"

Severity

Medium — A LAN attacker can induce abrupt half-gigabyte allocation pressure with negligible payload, but global caps and 10-second deadlines bound each wave.

Severity increases on memory-constrained desktops or if concurrency/frame limits grow.

Impact assessment:

  • Level: high
  • Rationale: A half-gigabyte allocation spike can terminate constrained desktops.

Likelihood assessment:

  • Level: medium
  • Rationale: Inbound requires only two connections; discovery requires more setup. Waves are finite but repeatable.

Remediation

Use a much smaller inbound Request-frame maximum; gate declared response bytes through a global memory semaphore or incremental buffering; reduce discovery fan-out as defense in depth.

[7] Catalog/build recipe arguments are interpolated as shell code

Field Value
Severity medium
Confidence high
Confidence rationale The raw templates and a harmless just --dry-run with literal command-substitution syntax confirm the rendered shell grammar.
Category command-injection
CWE CWE-78
Affected lines justfile:22-49, justfile:105-118, justfile:140-170

Summary

Documented just recipes embed path, selector, output, and environment-derived values directly into shell source; command substitution and quote-breaking run before Rust/Python argv parsing.

Root Cause

just template interpolation is used as shell quoting even though interpolation happens before shell parsing.

GAMES_DIR is embedded in shell text — justfile:22-31

Double quotes do not prevent shell command substitution after just renders the recipe.

default:
    #!/usr/bin/env bash
    if [ -n "{{GAMES_DIR}}" ]; then
        just run-production "{{GAMES_DIR}}"
    else
        just run-fixture
    fi

Fixture parameters are embedded directly — justfile:105-118

Quote-breaking or $() reaches the recipe shell before the CLI.

catalog-generate-fixture OUTPUT GAME_ROOT GAME_ID:
    cargo run ... --output "{{OUTPUT}}" --game-root "{{GAME_ROOT}}" --game-id "{{GAME_ID}}" --unrar "{{CATALOG_UNRAR}}"

Production values repeat across a shell conditional — justfile:140-170

All cache/publisher invocations share the injection surface.

catalog-generate-production PACKAGES_DIR:
    #!/usr/bin/env bash
    if ... --packages-dir "{{PACKAGES_DIR}}" ... --unrar "{{CATALOG_UNRAR}}"; then ... fi

Validation

Validated. just --dry-run catalog-generate-production '$(printf SAFE_DRY_RUN_MARKER)' preserved $() inside the rendered shell command; an actual shell would evaluate it.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

GAMES_DIR is embedded in shell text — justfile:22-31

Double quotes do not prevent shell command substitution after just renders the recipe.

default:
    #!/usr/bin/env bash
    if [ -n "{{GAMES_DIR}}" ]; then
        just run-production "{{GAMES_DIR}}"
    else
        just run-fixture
    fi

Fixture parameters are embedded directly — justfile:105-118

Quote-breaking or $() reaches the recipe shell before the CLI.

catalog-generate-fixture OUTPUT GAME_ROOT GAME_ID:
    cargo run ... --output "{{OUTPUT}}" --game-root "{{GAME_ROOT}}" --game-id "{{GAME_ID}}" --unrar "{{CATALOG_UNRAR}}"

Production values repeat across a shell conditional — justfile:140-170

All cache/publisher invocations share the injection surface.

catalog-generate-production PACKAGES_DIR:
    #!/usr/bin/env bash
    if ... --packages-dir "{{PACKAGES_DIR}}" ... --unrar "{{CATALOG_UNRAR}}"; then ... fi

Assertions:

  • Arguments are rendered into recipe source.
  • The shell parses command substitution inside double quotes.
  • Rust subprocess construction is safe but occurs after this boundary.

Counterevidence and remaining uncertainty:

  • Checked-in defaults and ordinary absolute paths are benign.
  • Exploitation needs attacker influence over operator arguments/environment, not merely package filenames.

Dataflow

just argument/environment -> {{...}} template -> bash recipe text -> command substitution/quote break -> arbitrary command.

  • Source: Operator-supplied recipe values.

  • Sink: Catalog/build shell with operator privileges.

  • Outcome: Arbitrary command execution and catalog/build compromise.

GAMES_DIR is embedded in shell text — justfile:22-31

Double quotes do not prevent shell command substitution after just renders the recipe.

default:
    #!/usr/bin/env bash
    if [ -n "{{GAMES_DIR}}" ]; then
        just run-production "{{GAMES_DIR}}"
    else
        just run-fixture
    fi

Fixture parameters are embedded directly — justfile:105-118

Quote-breaking or $() reaches the recipe shell before the CLI.

catalog-generate-fixture OUTPUT GAME_ROOT GAME_ID:
    cargo run ... --output "{{OUTPUT}}" --game-root "{{GAME_ROOT}}" --game-id "{{GAME_ID}}" --unrar "{{CATALOG_UNRAR}}"

Production values repeat across a shell conditional — justfile:140-170

All cache/publisher invocations share the injection surface.

catalog-generate-production PACKAGES_DIR:
    #!/usr/bin/env bash
    if ... --packages-dir "{{PACKAGES_DIR}}" ... --unrar "{{CATALOG_UNRAR}}"; then ... fi

Reachability

Conditional on an operator or CI passing an attacker-influenced value.

  • Attacker: Package/path supplier or CI input actor.

  • Entry point: catalog/build/run just recipes.

Preconditions:

  • Attacker-influenced just argument or LANSPREAD_UNRAR/GAMES_DIR
  • Operator executes recipe

Existing controls:

  • Safe argv handling inside Rust publisher
  • Benign defaults

GAMES_DIR is embedded in shell text — justfile:22-31

Double quotes do not prevent shell command substitution after just renders the recipe.

default:
    #!/usr/bin/env bash
    if [ -n "{{GAMES_DIR}}" ]; then
        just run-production "{{GAMES_DIR}}"
    else
        just run-fixture
    fi

Fixture parameters are embedded directly — justfile:105-118

Quote-breaking or $() reaches the recipe shell before the CLI.

catalog-generate-fixture OUTPUT GAME_ROOT GAME_ID:
    cargo run ... --output "{{OUTPUT}}" --game-root "{{GAME_ROOT}}" --game-id "{{GAME_ID}}" --unrar "{{CATALOG_UNRAR}}"

Production values repeat across a shell conditional — justfile:140-170

All cache/publisher invocations share the injection surface.

catalog-generate-production PACKAGES_DIR:
    #!/usr/bin/env bash
    if ... --packages-dir "{{PACKAGES_DIR}}" ... --unrar "{{CATALOG_UNRAR}}"; then ... fi

Severity

Medium — Successful exploitation executes with catalog/build operator authority, but requires attacker influence over an operator-supplied recipe argument or environment value.

Severity increases in automated CI or workflows that pass externally supplied paths/IDs directly to just.

Impact assessment:

  • Level: high
  • Rationale: Build secrets and trusted catalog/bundle inputs can be modified or exfiltrated.

Likelihood assessment:

  • Level: medium
  • Rationale: Documented commands accept paths, but operators often choose them themselves.

Remediation

Pass data through environment/argv to non-shell helpers or apply just's correct shell-quoting facility to every argument and environment-derived value; test $(), quotes, whitespace, leading dashes, and newlines.

[8] Sybil peers can exhaust aggregate state and unbounded UI publication

Field Value
Severity medium
Confidence high
Confidence rationale The identity generation, first-come caps, per-author byte allowance, full projection cloning, and unbounded sender are explicit in source.
Category resource-exhaustion
CWE CWE-400
Affected lines crates/lanspread-peer/src/call_to_play.rs:555-565, crates/lanspread-peer/src/events.rs:21-25, crates/lanspread-peer/src/peer_db.rs:356-360, crates/lanspread-proto/src/lib.rs:15-20

Summary

One LAN host can generate enough valid peer identities to fill peer/author slots, retain hundreds of MiB of bounded-per-author state, and repeatedly enqueue cloned full views without an aggregate byte budget.

Root Cause

Identity-count limits are first-come and per-author bounds are not paired with aggregate retained-byte or queued-view budgets.

Per-author state is retained until a global author-count cap — crates/lanspread-peer/src/call_to_play.rs:555-565

The cap counts identities, not aggregate encoded bytes or physical origins.

if self.remote.len() >= MAX_CALL_TO_PLAY_AUTHORS - 1 {
    return ObserveRemoteAuthorOutcome::AtCapacity;
}
self.remote.insert(author_id, RemoteAuthorSlice { ... });

Every publication clones visible events across all authors — crates/lanspread-peer/src/call_to_play.rs:835-855

Repeated commits rebuild complete owned views.

for (author_id, slice) in &self.remote {
    Self::extend_visible_author_events(*author_id, &slice.snapshot, now, &windows, &mut events);
}
events.sort_by_key(|event| (event.at, event.call_id, event.author_id, event.id));

Complete views enter an unbounded channel — crates/lanspread-peer/src/events.rs:21-25

There is no capacity, backpressure, or replace-latest coalescing at this boundary.

pub fn send(tx_notify_ui: &UnboundedSender<PeerEvent>, event: PeerEvent) {
    if let Err(err) = tx_notify_ui.send(event) { ... }
}

Large limits are per author/peer — crates/lanspread-proto/src/lib.rs:15-20

Sixty-three remote authors can retain about 252 MiB encoded before allocation overhead.

pub const MAX_LIBRARY_GAMES: usize = 4_096;
pub const MAX_CALL_TO_PLAY_EVENTS_PER_AUTHOR: usize = 4_096;
pub const MAX_CALL_TO_PLAY_AUTHOR_SNAPSHOT_BYTES: usize = 4 * 1024 * 1024;

Validation

Validated and merged with the duplicate peer/author-slot candidate; exact content verification limits integrity impact but does not bound retained/queued state.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Per-author state is retained until a global author-count cap — crates/lanspread-peer/src/call_to_play.rs:555-565

The cap counts identities, not aggregate encoded bytes or physical origins.

if self.remote.len() >= MAX_CALL_TO_PLAY_AUTHORS - 1 {
    return ObserveRemoteAuthorOutcome::AtCapacity;
}
self.remote.insert(author_id, RemoteAuthorSlice { ... });

Every publication clones visible events across all authors — crates/lanspread-peer/src/call_to_play.rs:835-855

Repeated commits rebuild complete owned views.

for (author_id, slice) in &self.remote {
    Self::extend_visible_author_events(*author_id, &slice.snapshot, now, &windows, &mut events);
}
events.sort_by_key(|event| (event.at, event.call_id, event.author_id, event.id));

Complete views enter an unbounded channel — crates/lanspread-peer/src/events.rs:21-25

There is no capacity, backpressure, or replace-latest coalescing at this boundary.

pub fn send(tx_notify_ui: &UnboundedSender<PeerEvent>, event: PeerEvent) {
    if let Err(err) = tx_notify_ui.send(event) { ... }
}

Large limits are per author/peer — crates/lanspread-proto/src/lib.rs:15-20

Sixty-three remote authors can retain about 252 MiB encoded before allocation overhead.

pub const MAX_LIBRARY_GAMES: usize = 4_096;
pub const MAX_CALL_TO_PLAY_EVENTS_PER_AUTHOR: usize = 4_096;
pub const MAX_CALL_TO_PLAY_AUTHOR_SNAPSHOT_BYTES: usize = 4 * 1024 * 1024;

Assertions:

  • One host can create many valid self-issued identities.
  • Per-author 4 MiB limits aggregate across 63 remote authors.
  • Full replacement views are owned clones sent through an unbounded channel.

Counterevidence and remaining uncertainty:

  • Peer and author counts are finite.
  • TLS prevents impersonation of an existing PeerId.
  • Invalid snapshots and wrong content bytes are rejected.

Dataflow

Self-issued identities -> pinned snapshots -> retained per-peer/author maps -> cloned aggregate projections -> unbounded Tauri event queue.

  • Source: Attacker-operated mDNS/QUIC responders with valid keys.

  • Sink: Desktop process heap and peer-to-Tauri event queue.

  • Outcome: CPU/memory exhaustion and exclusion of legitimate new peers.

Per-author state is retained until a global author-count cap — crates/lanspread-peer/src/call_to_play.rs:555-565

The cap counts identities, not aggregate encoded bytes or physical origins.

if self.remote.len() >= MAX_CALL_TO_PLAY_AUTHORS - 1 {
    return ObserveRemoteAuthorOutcome::AtCapacity;
}
self.remote.insert(author_id, RemoteAuthorSlice { ... });

Every publication clones visible events across all authors — crates/lanspread-peer/src/call_to_play.rs:835-855

Repeated commits rebuild complete owned views.

for (author_id, slice) in &self.remote {
    Self::extend_visible_author_events(*author_id, &slice.snapshot, now, &windows, &mut events);
}
events.sort_by_key(|event| (event.at, event.call_id, event.author_id, event.id));

Complete views enter an unbounded channel — crates/lanspread-peer/src/events.rs:21-25

There is no capacity, backpressure, or replace-latest coalescing at this boundary.

pub fn send(tx_notify_ui: &UnboundedSender<PeerEvent>, event: PeerEvent) {
    if let Err(err) = tx_notify_ui.send(event) { ... }
}

Large limits are per author/peer — crates/lanspread-proto/src/lib.rs:15-20

Sixty-three remote authors can retain about 252 MiB encoded before allocation overhead.

pub const MAX_LIBRARY_GAMES: usize = 4_096;
pub const MAX_CALL_TO_PLAY_EVENTS_PER_AUTHOR: usize = 4_096;
pub const MAX_CALL_TO_PLAY_AUTHOR_SNAPSHOT_BYTES: usize = 4 * 1024 * 1024;

Reachability

Reachable from the same LAN while sharing/discovery is enabled; no victim key compromise is required.

  • Attacker: Malicious same-LAN host.

  • Entry point: mDNS candidate negotiation and Hello snapshot commit.

Preconditions:

  • Sharing/discovery enabled
  • Dozens of distinct PeerIds and endpoints
  • Sustained valid snapshot traffic

Existing controls:

  • 64-peer and 64-author count caps
  • 4 MiB per-author encoded cap
  • TLS responder pinning

Per-author state is retained until a global author-count cap — crates/lanspread-peer/src/call_to_play.rs:555-565

The cap counts identities, not aggregate encoded bytes or physical origins.

if self.remote.len() >= MAX_CALL_TO_PLAY_AUTHORS - 1 {
    return ObserveRemoteAuthorOutcome::AtCapacity;
}
self.remote.insert(author_id, RemoteAuthorSlice { ... });

Every publication clones visible events across all authors — crates/lanspread-peer/src/call_to_play.rs:835-855

Repeated commits rebuild complete owned views.

for (author_id, slice) in &self.remote {
    Self::extend_visible_author_events(*author_id, &slice.snapshot, now, &windows, &mut events);
}
events.sort_by_key(|event| (event.at, event.call_id, event.author_id, event.id));

Complete views enter an unbounded channel — crates/lanspread-peer/src/events.rs:21-25

There is no capacity, backpressure, or replace-latest coalescing at this boundary.

pub fn send(tx_notify_ui: &UnboundedSender<PeerEvent>, event: PeerEvent) {
    if let Err(err) = tx_notify_ui.send(event) { ... }
}

Large limits are per author/peer — crates/lanspread-proto/src/lib.rs:15-20

Sixty-three remote authors can retain about 252 MiB encoded before allocation overhead.

pub const MAX_LIBRARY_GAMES: usize = 4_096;
pub const MAX_CALL_TO_PLAY_EVENTS_PER_AUTHOR: usize = 4_096;
pub const MAX_CALL_TO_PLAY_AUTHOR_SNAPSHOT_BYTES: usize = 4 * 1024 * 1024;

Severity

Medium — The impact can terminate the desktop process, but exploitation requires sustained LAN access, dozens of identities/endpoints, and substantial state transfer.

Severity increases if fewer identities can cross the host memory limit or if the UI consumer is routinely slow.

Impact assessment:

  • Level: high
  • Rationale: The application may freeze, swap heavily, or terminate and legitimate peers may be excluded.

Likelihood assessment:

  • Level: medium
  • Rationale: The attack is practical but requires many identities and substantial traffic.

Remediation

Enforce aggregate byte/event budgets across remote peers, coalesce complete UI state through bounded latest-value channels, avoid full cloning per commit, and add fair/per-origin admission for identities.

[9] Unauthenticated hints can make the victim pull arbitrary known peers

Field Value
Severity medium
Confidence high
Confidence rationale The unbound payload identity, scheduler key, mismatch decision, and full-pull sink are explicit.
Category confused-deputy
CWE CWE-441
Affected lines crates/lanspread-peer/src/services/stream.rs:265-271, crates/lanspread-peer/src/services/state_sync.rs:351-388, crates/lanspread-peer/src/services/remote_state.rs:147-159

Summary

Anonymous inbound connections may name any known PeerId in a change hint; a forged session/revision mismatch schedules a full pinned Hello pull to that unrelated peer.

Root Cause

A requester-anonymous protocol uses an untrusted claimed PeerId as a third-party work selector rather than binding or discarding hints.

Inbound connection identity is not checked — crates/lanspread-peer/src/services/stream.rs:265-271

The payload claim is accepted from any requester.

Request::LibraryChanged(hint) => {
    ctx.state_sync.schedule_hint(StateDomain::Library, hint);
    DispatchResult::close(framed_tx)
}

Claimed ID selects cached peer — crates/lanspread-peer/src/services/state_sync.rs:351-388

A random session forces a pull of the named known peer.

let snapshot = ctx.peer_liveness_for(peer_id).await;
...
perform_peer_refresh(ctx, snapshot).await
...
if snapshot.runtime_session_id != trigger.hint.runtime_session_id { return true; }

Reconciliation performs Hello — crates/lanspread-peer/src/services/remote_state.rs:147-159

Authoritative state remains pinned, but resource work is delegated.

let snapshot = exchange_hello(&ctx.quic, &endpoint, &ctx.cancellation).await?;
let prepared = PreparedSnapshot::prepare(endpoint.peer_id, generation, snapshot);
commit_prepared(ctx, endpoint, ticket, prepared).await

Validation

Validated. State integrity remains protected by the pinned pull, while resource consumption is the concrete impact.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Inbound connection identity is not checked — crates/lanspread-peer/src/services/stream.rs:265-271

The payload claim is accepted from any requester.

Request::LibraryChanged(hint) => {
    ctx.state_sync.schedule_hint(StateDomain::Library, hint);
    DispatchResult::close(framed_tx)
}

Claimed ID selects cached peer — crates/lanspread-peer/src/services/state_sync.rs:351-388

A random session forces a pull of the named known peer.

let snapshot = ctx.peer_liveness_for(peer_id).await;
...
perform_peer_refresh(ctx, snapshot).await
...
if snapshot.runtime_session_id != trigger.hint.runtime_session_id { return true; }

Reconciliation performs Hello — crates/lanspread-peer/src/services/remote_state.rs:147-159

Authoritative state remains pinned, but resource work is delegated.

let snapshot = exchange_hello(&ctx.quic, &endpoint, &ctx.cancellation).await?;
let prepared = PreparedSnapshot::prepare(endpoint.peer_id, generation, snapshot);
commit_prepared(ctx, endpoint, ticket, prepared).await

Assertions:

  • Server has no client auth.
  • Claimed PeerId is the scheduler key.
  • Session mismatch forces a full pull.

Counterevidence and remaining uncertainty:

  • Hint and pinned queues are bounded/separate.
  • At most eight pulls run concurrently.
  • Each peer is coalesced to one pull per five seconds.
  • Pulled state is TLS pinned.

Dataflow

Inbound hint -> claimed PeerId -> state-sync slot -> cached pinned endpoint -> full Hello exchange.

  • Source: Unauthenticated ChangeHint fields.

  • Sink: Victim connector and unrelated peer's Hello responder.

  • Outcome: Bandwidth and CPU amplification/availability degradation.

Inbound connection identity is not checked — crates/lanspread-peer/src/services/stream.rs:265-271

The payload claim is accepted from any requester.

Request::LibraryChanged(hint) => {
    ctx.state_sync.schedule_hint(StateDomain::Library, hint);
    DispatchResult::close(framed_tx)
}

Claimed ID selects cached peer — crates/lanspread-peer/src/services/state_sync.rs:351-388

A random session forces a pull of the named known peer.

let snapshot = ctx.peer_liveness_for(peer_id).await;
...
perform_peer_refresh(ctx, snapshot).await
...
if snapshot.runtime_session_id != trigger.hint.runtime_session_id { return true; }

Reconciliation performs Hello — crates/lanspread-peer/src/services/remote_state.rs:147-159

Authoritative state remains pinned, but resource work is delegated.

let snapshot = exchange_hello(&ctx.quic, &endpoint, &ctx.cancellation).await?;
let prepared = PreparedSnapshot::prepare(endpoint.peer_id, generation, snapshot);
commit_prepared(ctx, endpoint, ticket, prepared).await

Reachability

Direct while sharing is enabled and at least one peer is known.

  • Attacker: Any reachable LAN host.

  • Entry point: LibraryChanged or CallToPlayChanged.

Preconditions:

  • Sharing enabled
  • Victim has known peers
  • Repeated forged session/revision values

Existing controls:

  • 64-slot hint queue
  • 8 concurrent pulls
  • 5-second per-peer coalescing
  • Pinned TLS follow-up

Inbound connection identity is not checked — crates/lanspread-peer/src/services/stream.rs:265-271

The payload claim is accepted from any requester.

Request::LibraryChanged(hint) => {
    ctx.state_sync.schedule_hint(StateDomain::Library, hint);
    DispatchResult::close(framed_tx)
}

Claimed ID selects cached peer — crates/lanspread-peer/src/services/state_sync.rs:351-388

A random session forces a pull of the named known peer.

let snapshot = ctx.peer_liveness_for(peer_id).await;
...
perform_peer_refresh(ctx, snapshot).await
...
if snapshot.runtime_session_id != trigger.hint.runtime_session_id { return true; }

Reconciliation performs Hello — crates/lanspread-peer/src/services/remote_state.rs:147-159

Authoritative state remains pinned, but resource work is delegated.

let snapshot = exchange_hello(&ctx.quic, &endpoint, &ctx.cancellation).await?;
let prepared = PreparedSnapshot::prepare(endpoint.peer_id, generation, snapshot);
commit_prepared(ctx, endpoint, ticket, prepared).await

Severity

Medium — Small anonymous requests can repeatedly consume victim and third-party bandwidth/serialization CPU, but concurrency, tracked peers, and per-peer cadence are bounded.

Severity increases with large valid snapshots or metered/slow links.

Impact assessment:

  • Level: medium
  • Rationale: Can consume significant bandwidth/serialization work but cannot inject authoritative state.

Likelihood assessment:

  • Level: high
  • Rationale: No credentials or target private keys are required.

Remediation

If requester authentication remains absent, drop remote change hints and rely on pinned liveness reconciliation. Otherwise bind the hint to an authenticated client PeerId and remove the payload identity.

[10] Mutable game scripts are launched elevated without launch-time trust binding

Field Value
Severity medium
Confidence high
Confidence rationale The path checks, missing catalog/digest checks, and runas calls are explicit.
Category privilege-escalation
CWE CWE-250, CWE-73
Affected lines crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1866-1958, crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:2007-2064, crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1554-1582

Summary

Windows play/server commands follow mutable paths under any selected game root and pass setup/start scripts to cmd.exe with runas without rechecking catalog membership, digest, installed ownership, or reparse-free containment.

Root Cause

The Windows launch path is separate from the catalog-bound no-follow install/download capabilities and treats filename/existence plus user action as sufficient authority for elevation.

Game scripts are path-checked then elevated — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1891-1951

No manifest, digest, retained handle, or reparse check binds the launched script.

let game_path = games_folder.join(id.clone());
let game_setup_bin = game_path.join(GAME_SETUP_SCRIPT);
let game_start_bin = game_path.join(GAME_START_SCRIPT);
...
run_as_admin_and_wait("cmd.exe", &setup_params, &game_dir, ...)?;
...
run_as_admin_detached("cmd.exe", &script_params(&game_start_bin, ...), ...);

Server script has the same gap — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:2026-2057

Path-based is_file follows redirections and does not prove catalog authority.

let game_path = games_folder.join(id.clone());
let server_start_bin = game_path.join(SERVER_START_SCRIPT);
if !server_start_bin.is_file() { return Ok(false); }
...
run_as_admin_detached("cmd.exe", &server_script_params(&server_start_bin, ...), ...);

Detached launcher requests elevation — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1563-1577

The explicit UAC boundary makes mutable-script provenance security-sensitive.

let runas_wide = OsStr::new("runas").encode_wide().chain(Some(0)).collect();
ShellExecuteW(None, PCWSTR::from_raw(runas_wide.as_ptr()), ...);

Validation

Validated with severity reduced from high for Windows/UAC/local-write prerequisites. Remote peers alone cannot substitute bytes because downloads remain catalog-verified.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Game scripts are path-checked then elevated — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1891-1951

No manifest, digest, retained handle, or reparse check binds the launched script.

let game_path = games_folder.join(id.clone());
let game_setup_bin = game_path.join(GAME_SETUP_SCRIPT);
let game_start_bin = game_path.join(GAME_START_SCRIPT);
...
run_as_admin_and_wait("cmd.exe", &setup_params, &game_dir, ...)?;
...
run_as_admin_detached("cmd.exe", &script_params(&game_start_bin, ...), ...);

Server script has the same gap — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:2026-2057

Path-based is_file follows redirections and does not prove catalog authority.

let game_path = games_folder.join(id.clone());
let server_start_bin = game_path.join(SERVER_START_SCRIPT);
if !server_start_bin.is_file() { return Ok(false); }
...
run_as_admin_detached("cmd.exe", &server_script_params(&server_start_bin, ...), ...);

Detached launcher requests elevation — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1563-1577

The explicit UAC boundary makes mutable-script provenance security-sensitive.

let runas_wide = OsStr::new("runas").encode_wide().chain(Some(0)).collect();
ShellExecuteW(None, PCWSTR::from_raw(runas_wide.as_ptr()), ...);

Assertions:

  • Any existing selected directory can become the games root.
  • Sink functions accept single-component IDs without a catalog lookup.
  • Scripts are elevated by path after only existence/local checks.

Counterevidence and remaining uncertainty:

  • IDs are one component and user settings are sanitized.
  • Downloaded/streamed bytes are catalog verified.
  • The victim must invoke play/server and approve UAC.

Dataflow

Selected directory + game ID -> joined mutable script path -> string cmd.exe parameters -> ShellExecute runas.

  • Source: Locally/shared-tree controlled game scripts.

  • Sink: Elevated Windows command processor.

  • Outcome: Administrator execution of attacker-controlled batch content.

Game scripts are path-checked then elevated — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1891-1951

No manifest, digest, retained handle, or reparse check binds the launched script.

let game_path = games_folder.join(id.clone());
let game_setup_bin = game_path.join(GAME_SETUP_SCRIPT);
let game_start_bin = game_path.join(GAME_START_SCRIPT);
...
run_as_admin_and_wait("cmd.exe", &setup_params, &game_dir, ...)?;
...
run_as_admin_detached("cmd.exe", &script_params(&game_start_bin, ...), ...);

Server script has the same gap — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:2026-2057

Path-based is_file follows redirections and does not prove catalog authority.

let game_path = games_folder.join(id.clone());
let server_start_bin = game_path.join(SERVER_START_SCRIPT);
if !server_start_bin.is_file() { return Ok(false); }
...
run_as_admin_detached("cmd.exe", &server_script_params(&server_start_bin, ...), ...);

Detached launcher requests elevation — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1563-1577

The explicit UAC boundary makes mutable-script provenance security-sensitive.

let runas_wide = OsStr::new("runas").encode_wide().chain(Some(0)).collect();
ShellExecuteW(None, PCWSTR::from_raw(runas_wide.as_ptr()), ...);

Reachability

Conditional on Windows, selected-root write influence, local launch, and UAC approval.

  • Attacker: Lower-privileged local or shared-directory supplier.

  • Entry point: run_game or start_server Tauri command.

Preconditions:

  • Windows
  • Writable or crafted selected game root
  • Victim launch action
  • UAC approval

Existing controls:

  • Single-component game IDs
  • Catalog integrity for peer downloads
  • UAC prompt
  • Installed/local presence checks

Game scripts are path-checked then elevated — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1891-1951

No manifest, digest, retained handle, or reparse check binds the launched script.

let game_path = games_folder.join(id.clone());
let game_setup_bin = game_path.join(GAME_SETUP_SCRIPT);
let game_start_bin = game_path.join(GAME_START_SCRIPT);
...
run_as_admin_and_wait("cmd.exe", &setup_params, &game_dir, ...)?;
...
run_as_admin_detached("cmd.exe", &script_params(&game_start_bin, ...), ...);

Server script has the same gap — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:2026-2057

Path-based is_file follows redirections and does not prove catalog authority.

let game_path = games_folder.join(id.clone());
let server_start_bin = game_path.join(SERVER_START_SCRIPT);
if !server_start_bin.is_file() { return Ok(false); }
...
run_as_admin_detached("cmd.exe", &server_script_params(&server_start_bin, ...), ...);

Detached launcher requests elevation — crates/lanspread-tauri-deno-ts/src-tauri/src/lib.rs:1563-1577

The explicit UAC boundary makes mutable-script provenance security-sensitive.

let runas_wide = OsStr::new("runas").encode_wide().chain(Some(0)).collect();
ShellExecuteW(None, PCWSTR::from_raw(runas_wide.as_ptr()), ...);

Severity

Medium — The consequence is administrator code execution, but exploitation requires local/shared-tree write influence, a victim launch action, Windows, and UAC approval.

Severity increases where selected game directories are shared across trust boundaries or UAC prompts are routinely approved.

Impact assessment:

  • Level: high
  • Rationale: Successful exploitation executes attacker code with the elevated token.

Likelihood assessment:

  • Level: medium
  • Rationale: Multiple local/user-interaction prerequisites materially constrain exploitation.

Remediation

Run ordinary game/server scripts as the current user. For setup requiring elevation, require a catalog game and authoritative installed state, verify the exact script digest immediately before launch through no-follow handles, reject reparse points, and preserve the verified object identity into process creation.

[11] Selected game directories can trigger unbounded monitoring and migration work

Field Value
Severity low
Confidence high
Confidence rationale Unbounded enumeration, task spawn, WalkDir traversal, and whole-file reads are explicit.
Category resource-exhaustion
CWE CWE-400
Affected lines crates/lanspread-peer/src/services/local_monitor.rs:200-235, crates/lanspread-peer/src/services/local_monitor.rs:329-376, crates/lanspread-peer/src/local_games.rs:268-294, crates/lanspread-peer/src/migration.rs:284-297

Summary

The continuously monitored game root retains every top-level name, spawns one task per changed ID, recursively walks trees, and reads current/legacy state files without byte budgets.

Root Cause

Local filesystem inputs have shape/link checks but no aggregate cardinality, traversal, task, or persisted-file byte budgets.

Every root name enters the snapshot — crates/lanspread-peer/src/services/local_monitor.rs:200-235

No catalog intersection or entry cap precedes retention.

let mut games = BTreeMap::new();
for entry in fs::read_dir(game_dir) {
    ...
    games.insert(id.to_owned(), game_root);
}

Every changed ID spawns a task — crates/lanspread-peer/src/services/local_monitor.rs:329-376

Only duplicate work for the same ID coalesces; no global worker cap applies.

for id in ready_ids {
    queue_rescan(ctx, tx_notify_ui, gate, rescans, id).await;
}
...
rescans.spawn(async move { run_gated_rescan(...).await; });

Current index is read without a byte cap — crates/lanspread-peer/src/local_games.rs:268-284

A tampered app-state file can allocate arbitrarily.

let data = match std::fs::read_to_string(path) { ... };
match serde_json::from_str(&data) { ... }

Legacy migration duplicates an unbounded file — crates/lanspread-peer/src/migration.rs:284-297

Selection automatically crosses this legacy input boundary.

let data = fs::read(legacy_path)?;
write_bytes_atomically(target_path, &data)?;
remove_file_if_exists(legacy_path)?;

Validation

Validated and merged with the legacy-index candidate. Severity is low because meaningful influence is local/shared-root rather than ordinary LAN peer input.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Every root name enters the snapshot — crates/lanspread-peer/src/services/local_monitor.rs:200-235

No catalog intersection or entry cap precedes retention.

let mut games = BTreeMap::new();
for entry in fs::read_dir(game_dir) {
    ...
    games.insert(id.to_owned(), game_root);
}

Every changed ID spawns a task — crates/lanspread-peer/src/services/local_monitor.rs:329-376

Only duplicate work for the same ID coalesces; no global worker cap applies.

for id in ready_ids {
    queue_rescan(ctx, tx_notify_ui, gate, rescans, id).await;
}
...
rescans.spawn(async move { run_gated_rescan(...).await; });

Current index is read without a byte cap — crates/lanspread-peer/src/local_games.rs:268-284

A tampered app-state file can allocate arbitrarily.

let data = match std::fs::read_to_string(path) { ... };
match serde_json::from_str(&data) { ... }

Legacy migration duplicates an unbounded file — crates/lanspread-peer/src/migration.rs:284-297

Selection automatically crosses this legacy input boundary.

let data = fs::read(legacy_path)?;
write_bytes_atomically(target_path, &data)?;
remove_file_if_exists(legacy_path)?;

Assertions:

  • Polling occurs every second.
  • All root names are retained before catalog filtering.
  • Per-ID task fan-out is not globally bounded.
  • Index/migration reads allocate complete files.

Counterevidence and remaining uncertainty:

  • Symlinks/reparse points and special files are rejected.
  • Repeated work for one ID coalesces.
  • Remote catalog downloads cannot create arbitrary top-level entries.

Dataflow

Selected filesystem -> root snapshot/WalkDir/whole-file read -> task set/heap/logs.

  • Source: Locally or share-writable selected game directory and persisted index files.

  • Sink: Desktop heap, blocking pool, async task set, and log file.

  • Outcome: Persistent CPU/memory exhaustion or startup OOM.

Every root name enters the snapshot — crates/lanspread-peer/src/services/local_monitor.rs:200-235

No catalog intersection or entry cap precedes retention.

let mut games = BTreeMap::new();
for entry in fs::read_dir(game_dir) {
    ...
    games.insert(id.to_owned(), game_root);
}

Every changed ID spawns a task — crates/lanspread-peer/src/services/local_monitor.rs:329-376

Only duplicate work for the same ID coalesces; no global worker cap applies.

for id in ready_ids {
    queue_rescan(ctx, tx_notify_ui, gate, rescans, id).await;
}
...
rescans.spawn(async move { run_gated_rescan(...).await; });

Current index is read without a byte cap — crates/lanspread-peer/src/local_games.rs:268-284

A tampered app-state file can allocate arbitrarily.

let data = match std::fs::read_to_string(path) { ... };
match serde_json::from_str(&data) { ... }

Legacy migration duplicates an unbounded file — crates/lanspread-peer/src/migration.rs:284-297

Selection automatically crosses this legacy input boundary.

let data = fs::read(legacy_path)?;
write_bytes_atomically(target_path, &data)?;
remove_file_if_exists(legacy_path)?;

Reachability

Requires the operator to select or restore an attacker-influenced directory.

  • Attacker: Lower-privileged local/shared-filesystem actor.

  • Entry point: Game-directory activation and one-second local monitor.

Preconditions:

  • Attacker-controlled directory contents
  • Victim selects/restores directory

Existing controls:

  • Link/reparse rejection
  • Special-file filtering
  • Per-ID rescan coalescing
  • Missed-tick skipping

Every root name enters the snapshot — crates/lanspread-peer/src/services/local_monitor.rs:200-235

No catalog intersection or entry cap precedes retention.

let mut games = BTreeMap::new();
for entry in fs::read_dir(game_dir) {
    ...
    games.insert(id.to_owned(), game_root);
}

Every changed ID spawns a task — crates/lanspread-peer/src/services/local_monitor.rs:329-376

Only duplicate work for the same ID coalesces; no global worker cap applies.

for id in ready_ids {
    queue_rescan(ctx, tx_notify_ui, gate, rescans, id).await;
}
...
rescans.spawn(async move { run_gated_rescan(...).await; });

Current index is read without a byte cap — crates/lanspread-peer/src/local_games.rs:268-284

A tampered app-state file can allocate arbitrarily.

let data = match std::fs::read_to_string(path) { ... };
match serde_json::from_str(&data) { ... }

Legacy migration duplicates an unbounded file — crates/lanspread-peer/src/migration.rs:284-297

Selection automatically crosses this legacy input boundary.

let data = fs::read(legacy_path)?;
write_bytes_atomically(target_path, &data)?;
remove_file_if_exists(legacy_path)?;

Severity

Low — The desktop can be exhausted, but the attacker needs local/shared/removable-directory control plus operator selection; remote peers cannot create this fan-out.

Severity increases when selected game roots are writable by lower-privileged or remote filesystem users.

Impact assessment:

  • Level: medium
  • Rationale: Can stall or terminate the peer but does not grant file escape or code execution.

Likelihood assessment:

  • Level: low
  • Rationale: Requires local/shared filesystem placement and user selection.

Remediation

Intersect names with the catalog before retention/task admission; add root/per-game/depth/metadata budgets and a bounded rescan pool; bounded-read current and legacy indexes/version.ini and avoid raw invalid-content logging.

[12] Public state helpers permit marker writes outside the state directory

Field Value
Severity low
Confidence high
Confidence rationale The raw joins, public re-exports, and filesystem write are direct.
Category path-traversal
CWE CWE-22
Affected lines crates/lanspread-peer/src/state_paths.rs:44-59, crates/lanspread-peer/src/launch_settings.rs:168-175, crates/lanspread-peer/src/launch_settings.rs:383-389

Summary

Public per-game path and marker APIs join an unvalidated game ID; absolute or parent-containing IDs escape state_dir/games, after which the marker writer creates parents and overwrites a fixed file.

Root Cause

The public API represents game IDs as raw strings instead of a validated single-component type.

Raw game ID selects the state child — crates/lanspread-peer/src/state_paths.rs:44-59

Absolute and parent components are not rejected before Path::join.

pub(crate) fn game_state_dir(state_dir: &Path, game_id: &str) -> PathBuf {
    games_state_dir(state_dir).join(game_id)
}
...
pub fn launch_settings_applied_path(state_dir: &Path, game_id: &str) -> PathBuf {
    game_state_dir(state_dir, game_id).join(LAUNCH_SETTINGS_APPLIED_FILE)
}

Public API writes the escaped marker — crates/lanspread-peer/src/launch_settings.rs:168-175

The public function documents no validated-ID precondition.

pub fn mark_launch_settings_applied(state_dir: &Path, game_id: &str) -> eyre::Result<()> {
    scoped_blocking(|| mark_applied(&launch_settings_applied_path(state_dir, game_id)))
}

Parents are created and marker overwritten — crates/lanspread-peer/src/launch_settings.rs:383-389

The escaped path drives mutation with application privileges.

if let Some(parent) = marker.parent() {
    std::fs::create_dir_all(parent)?;
}
std::fs::write(marker, [])?;

Validation

Validated with low severity; no direct LAN route exists and current shipping callers use validated IDs.

Validation method: Static public-API trace from caller-controlled identifier through Path::join to filesystem write.

  • Status: validated
  • Disposition: reportable

Raw game ID selects the state child — crates/lanspread-peer/src/state_paths.rs:44-59

Absolute and parent components are not rejected before Path::join.

pub(crate) fn game_state_dir(state_dir: &Path, game_id: &str) -> PathBuf {
    games_state_dir(state_dir).join(game_id)
}
...
pub fn launch_settings_applied_path(state_dir: &Path, game_id: &str) -> PathBuf {
    game_state_dir(state_dir, game_id).join(LAUNCH_SETTINGS_APPLIED_FILE)
}

Public API writes the escaped marker — crates/lanspread-peer/src/launch_settings.rs:168-175

The public function documents no validated-ID precondition.

pub fn mark_launch_settings_applied(state_dir: &Path, game_id: &str) -> eyre::Result<()> {
    scoped_blocking(|| mark_applied(&launch_settings_applied_path(state_dir, game_id)))
}

Parents are created and marker overwritten — crates/lanspread-peer/src/launch_settings.rs:383-389

The escaped path drives mutation with application privileges.

if let Some(parent) = marker.parent() {
    std::fs::create_dir_all(parent)?;
}
std::fs::write(marker, [])?;

Assertions:

  • Absolute child replaces the accumulated PathBuf prefix.
  • Parent components escape when resolved.
  • Public marker API creates parents and writes.

Counterevidence and remaining uncertainty:

  • Windows run-game checks one component.
  • Internal StreamInstall calls use catalog IDs.
  • Only a fixed basename is written.

Dataflow

Raw game_id -> public path helper -> escaped PathBuf -> create_dir_all/write.

  • Source: Embedding application input.

  • Sink: Filesystem outside state_dir.

  • Outcome: Fixed marker file creation/overwrite.

Raw game ID selects the state child — crates/lanspread-peer/src/state_paths.rs:44-59

Absolute and parent components are not rejected before Path::join.

pub(crate) fn game_state_dir(state_dir: &Path, game_id: &str) -> PathBuf {
    games_state_dir(state_dir).join(game_id)
}
...
pub fn launch_settings_applied_path(state_dir: &Path, game_id: &str) -> PathBuf {
    game_state_dir(state_dir, game_id).join(LAUNCH_SETTINGS_APPLIED_FILE)
}

Public API writes the escaped marker — crates/lanspread-peer/src/launch_settings.rs:168-175

The public function documents no validated-ID precondition.

pub fn mark_launch_settings_applied(state_dir: &Path, game_id: &str) -> eyre::Result<()> {
    scoped_blocking(|| mark_applied(&launch_settings_applied_path(state_dir, game_id)))
}

Parents are created and marker overwritten — crates/lanspread-peer/src/launch_settings.rs:383-389

The escaped path drives mutation with application privileges.

if let Some(parent) = marker.parent() {
    std::fs::create_dir_all(parent)?;
}
std::fs::write(marker, [])?;

Reachability

Public Rust API boundary; no shipping LAN route was found.

  • Attacker: Caller controlling a game_id consumed by an embedding application.

  • Entry point: mark_launch_settings_applied or exported path helpers.

Preconditions:

  • Embedding caller forwards untrusted identifier

Existing controls:

  • Current internal catalog/single-component checks
  • Fixed marker basename

Public API writes the escaped marker — crates/lanspread-peer/src/launch_settings.rs:168-175

The public function documents no validated-ID precondition.

pub fn mark_launch_settings_applied(state_dir: &Path, game_id: &str) -> eyre::Result<()> {
    scoped_blocking(|| mark_applied(&launch_settings_applied_path(state_dir, game_id)))
}

Severity

Low — The write is constrained to a fixed basename and shipping callers validate/catalog-source IDs, but an embedding caller forwarding untrusted IDs crosses a real public library boundary.

Additional runtime or deployment evidence could raise or lower this severity.

Impact assessment:

  • Level: low
  • Rationale: Write target basename is fixed, but directories/path can escape.

Likelihood assessment:

  • Level: low
  • Rationale: Current workspace callers prevalidate; exploitation depends on another caller.

Remediation

Require a validated single-component GameId newtype or make helpers fallible and reject absolute/prefix/dot/parent/separator/reserved forms; write relative to a retained no-follow state-directory handle.

Field Value
Severity low
Confidence high
Confidence rationale Ordering, whole diagnostic, and non-Unix same_file=true are explicit.
Category path-traversal
CWE CWE-59, CWE-367
Affected lines crates/lanspread-compat/src/catalog_publisher/mod.rs:120-130, crates/lanspread-compat/src/catalog_publisher/package.rs:125-137, crates/lanspread-compat/src/catalog_publisher/package.rs:403-425

Summary

Version preflight joins package_root/version.ini before validating the game root, and Windows disables file-identity comparison, allowing ancestor-link traversal or a raced reparse target to be read and echoed.

Root Cause

Package reads are path-based rather than rooted in retained no-follow directory handles, and cross-platform object identity is not enforced.

Version read precedes root validation — crates/lanspread-compat/src/catalog_publisher/mod.rs:120-130

The later manifest builder's non-link directory validation has not run.

for game in &selected {
    package::validate_package_version(
        &options.packages_dir.join(&game.game_id),
        &game.game_version,
    )?;
}

Out-of-root bytes are echoed on mismatch — crates/lanspread-compat/src/catalog_publisher/package.rs:125-137

Ancestor links are followed by the path open; mismatching content reaches stderr.

let path = package_root.join("version.ini");
let bytes = read_bounded_regular_file(&path, MAX_VERSION_INI_BYTES)?;
let version = std::str::from_utf8(&bytes)?.trim();
if version != expected {
    eyre::bail!("... version.ini contains {version:?}");
}

Windows accepts every check/open identity — crates/lanspread-compat/src/catalog_publisher/package.rs:403-425

The pre-open reparse check is not bound to the opened handle on Windows.

#[cfg(not(unix))]
fn same_file(_before: &fs::Metadata, _after: &fs::Metadata) -> bool {
    true
}
...
#[cfg(windows)]
fn is_link_or_reparse(metadata: &fs::Metadata) -> bool { ... }

Validation

Validated and merged with the Windows TOCTOU candidate. Publication fail-closed behavior limits the impact to bounded disclosure/digest-oracle and provenance violation.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Version read precedes root validation — crates/lanspread-compat/src/catalog_publisher/mod.rs:120-130

The later manifest builder's non-link directory validation has not run.

for game in &selected {
    package::validate_package_version(
        &options.packages_dir.join(&game.game_id),
        &game.game_version,
    )?;
}

Out-of-root bytes are echoed on mismatch — crates/lanspread-compat/src/catalog_publisher/package.rs:125-137

Ancestor links are followed by the path open; mismatching content reaches stderr.

let path = package_root.join("version.ini");
let bytes = read_bounded_regular_file(&path, MAX_VERSION_INI_BYTES)?;
let version = std::str::from_utf8(&bytes)?.trim();
if version != expected {
    eyre::bail!("... version.ini contains {version:?}");
}

Windows accepts every check/open identity — crates/lanspread-compat/src/catalog_publisher/package.rs:403-425

The pre-open reparse check is not bound to the opened handle on Windows.

#[cfg(not(unix))]
fn same_file(_before: &fs::Metadata, _after: &fs::Metadata) -> bool {
    true
}
...
#[cfg(windows)]
fn is_link_or_reparse(metadata: &fs::Metadata) -> bool { ... }

Assertions:

  • Ancestor symlink validation is absent before preflight.
  • Final-component checks do not prove ancestor confinement.
  • Windows same_file unconditionally succeeds.
  • Mismatch errors include contents.

Counterevidence and remaining uncertainty:

  • Stable final-component links/reparse points are rejected.
  • Read is capped at 64 KiB.
  • Later manifest building rejects a stable linked root.
  • Unix final-component swaps are device/inode checked.

Dataflow

packages_dir/game_id path -> joined version.ini -> path-based lstat/open -> UTF-8 contents -> error log.

  • Source: Attacker-controlled package tree links/races.

  • Sink: Publisher memory and stderr/CI log.

  • Outcome: Bounded out-of-root disclosure; Windows hash path may expose a digest oracle.

Version read precedes root validation — crates/lanspread-compat/src/catalog_publisher/mod.rs:120-130

The later manifest builder's non-link directory validation has not run.

for game in &selected {
    package::validate_package_version(
        &options.packages_dir.join(&game.game_id),
        &game.game_version,
    )?;
}

Out-of-root bytes are echoed on mismatch — crates/lanspread-compat/src/catalog_publisher/package.rs:125-137

Ancestor links are followed by the path open; mismatching content reaches stderr.

let path = package_root.join("version.ini");
let bytes = read_bounded_regular_file(&path, MAX_VERSION_INI_BYTES)?;
let version = std::str::from_utf8(&bytes)?.trim();
if version != expected {
    eyre::bail!("... version.ini contains {version:?}");
}

Windows accepts every check/open identity — crates/lanspread-compat/src/catalog_publisher/package.rs:403-425

The pre-open reparse check is not bound to the opened handle on Windows.

#[cfg(not(unix))]
fn same_file(_before: &fs::Metadata, _after: &fs::Metadata) -> bool {
    true
}
...
#[cfg(windows)]
fn is_link_or_reparse(metadata: &fs::Metadata) -> bool { ... }

Reachability

Requires publisher execution on an attacker-controlled package tree; Windows race is platform-specific.

  • Attacker: Package-corpus supplier or concurrent local process.

  • Entry point: Catalog generation version preflight.

Preconditions:

  • Readable target named version.ini or race target
  • Access to resulting diagnostics for disclosure

Existing controls:

  • 64 KiB version limit
  • Final-component link/reparse check
  • Unix inode/device comparison
  • Later root validation

Version read precedes root validation — crates/lanspread-compat/src/catalog_publisher/mod.rs:120-130

The later manifest builder's non-link directory validation has not run.

for game in &selected {
    package::validate_package_version(
        &options.packages_dir.join(&game.game_id),
        &game.game_version,
    )?;
}

Out-of-root bytes are echoed on mismatch — crates/lanspread-compat/src/catalog_publisher/package.rs:125-137

Ancestor links are followed by the path open; mismatching content reaches stderr.

let path = package_root.join("version.ini");
let bytes = read_bounded_regular_file(&path, MAX_VERSION_INI_BYTES)?;
let version = std::str::from_utf8(&bytes)?.trim();
if version != expected {
    eyre::bail!("... version.ini contains {version:?}");
}

Windows accepts every check/open identity — crates/lanspread-compat/src/catalog_publisher/package.rs:403-425

The pre-open reparse check is not bound to the opened handle on Windows.

#[cfg(not(unix))]
fn same_file(_before: &fs::Metadata, _after: &fs::Metadata) -> bool {
    true
}
...
#[cfg(windows)]
fn is_link_or_reparse(metadata: &fs::Metadata) -> bool { ... }

Severity

Low — The read is bounded and publication later fails; disclosure requires package-tree control and access to operator/CI diagnostics, with Windows race prerequisites for the TOCTOU variant.

Severity increases when publisher logs are visible to package suppliers or the build account has sensitive readable version.ini files.

Impact assessment:

  • Level: medium
  • Rationale: Can expose bounded sensitive content but cannot publish a stable linked package.

Likelihood assessment:

  • Level: low
  • Rationale: Requires specially placed links or a filesystem race and often log visibility.

Remediation

Open the packages/game roots through retained no-follow handles and open version.ini relative to them; implement Windows file-ID/reparse-safe identity checks; never print raw untrusted version contents.

[14] Cross-author event-ID collisions can suppress Call-to-Play entries

Field Value
Severity low
Confidence high
Confidence rationale Producer preserves author_id while the reducer's global Map key omits it.
Category state-integrity
CWE CWE-694
Affected lines crates/lanspread-peer/src/call_to_play.rs:961-979, crates/lanspread-tauri-deno-ts/src/lib/callToPlay.ts:135-145

Summary

Rust validates EventNonce uniqueness only within each authenticated author's slice, but the frontend globally deduplicates events by nonce alone, letting a hostile author overwrite another author's event in the rendered view.

Root Cause

The frontend treats an author-scoped random nonce as a globally unique identifier.

Nonce uniqueness is per author snapshot — crates/lanspread-peer/src/call_to_play.rs:961-979

Equal nonces across authenticated authors remain valid.

let mut event_ids = HashSet::with_capacity(snapshot.events.len());
...
if !event_ids.insert(event.id) {
    return Err(CallToPlayValidationError::DuplicateEventId(event.id));
}

Rust projection preserves the namespace — crates/lanspread-peer/src/call_to_play.rs:877-884

The correct composite identity is available to consumers.

output.push(CallToPlayViewEvent {
    id: event.id,
    call_id: event.call_id,
    author_id,
    author_name: snapshot.display_name.clone(),
    ...
});

Frontend drops the author namespace — crates/lanspread-tauri-deno-ts/src/lib/callToPlay.ts:135-145

A later event with the same nonce replaces another author's event before grouping.

const unique = new Map(input.map(event => [event.id, event]));
const byCall = new Map<string, CallToPlayViewEvent[]>();
for (const event of unique.values()) { ... }

Validation

Validated. Creator-only Rust authorization remains effective, so severity is low and limited to rendered-state integrity/availability.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Nonce uniqueness is per author snapshot — crates/lanspread-peer/src/call_to_play.rs:961-979

Equal nonces across authenticated authors remain valid.

let mut event_ids = HashSet::with_capacity(snapshot.events.len());
...
if !event_ids.insert(event.id) {
    return Err(CallToPlayValidationError::DuplicateEventId(event.id));
}

Rust projection preserves the namespace — crates/lanspread-peer/src/call_to_play.rs:877-884

The correct composite identity is available to consumers.

output.push(CallToPlayViewEvent {
    id: event.id,
    call_id: event.call_id,
    author_id,
    author_name: snapshot.display_name.clone(),
    ...
});

Frontend drops the author namespace — crates/lanspread-tauri-deno-ts/src/lib/callToPlay.ts:135-145

A later event with the same nonce replaces another author's event before grouping.

const unique = new Map(input.map(event => [event.id, event]));
const byCall = new Map<string, CallToPlayViewEvent[]>();
for (const event of unique.values()) { ... }

Assertions:

  • Hostile authors can observe shared event nonces.
  • Cross-author duplicates survive Rust validation.
  • Frontend Map overwrite occurs before call grouping.

Counterevidence and remaining uncertainty:

  • Author identity is TLS-derived and preserved.
  • Creator-only actions cannot be forged.
  • Impact is confined to UI state.

Dataflow

Pinned remote snapshot -> authenticated Rust view with author_id -> frontend Map keyed only by event.id -> overwritten legitimate event.

  • Source: Attacker-controlled CallToPlayAuthorEvent.id.

  • Sink: Call-to-Play reducer and rendered nominations/messages.

  • Outcome: Legitimate calls or updates disappear or are substituted.

Nonce uniqueness is per author snapshot — crates/lanspread-peer/src/call_to_play.rs:961-979

Equal nonces across authenticated authors remain valid.

let mut event_ids = HashSet::with_capacity(snapshot.events.len());
...
if !event_ids.insert(event.id) {
    return Err(CallToPlayValidationError::DuplicateEventId(event.id));
}

Rust projection preserves the namespace — crates/lanspread-peer/src/call_to_play.rs:877-884

The correct composite identity is available to consumers.

output.push(CallToPlayViewEvent {
    id: event.id,
    call_id: event.call_id,
    author_id,
    author_name: snapshot.display_name.clone(),
    ...
});

Frontend drops the author namespace — crates/lanspread-tauri-deno-ts/src/lib/callToPlay.ts:135-145

A later event with the same nonce replaces another author's event before grouping.

const unique = new Map(input.map(event => [event.id, event]));
const byCall = new Map<string, CallToPlayViewEvent[]>();
for (const event of unique.values()) { ... }

Reachability

Requires a connected hostile peer that observes the shared snapshot and publishes a later valid author slice.

  • Attacker: Authenticated hostile LAN peer.

  • Entry point: HelloSnapshot Call-to-Play author slice.

Preconditions:

  • Attacker observes target nonce
  • Attacker publishes a colliding valid event

Existing controls:

  • Per-author duplicate rejection
  • Creator-only action checks
  • Authenticated author attribution

Nonce uniqueness is per author snapshot — crates/lanspread-peer/src/call_to_play.rs:961-979

Equal nonces across authenticated authors remain valid.

let mut event_ids = HashSet::with_capacity(snapshot.events.len());
...
if !event_ids.insert(event.id) {
    return Err(CallToPlayValidationError::DuplicateEventId(event.id));
}

Rust projection preserves the namespace — crates/lanspread-peer/src/call_to_play.rs:877-884

The correct composite identity is available to consumers.

output.push(CallToPlayViewEvent {
    id: event.id,
    call_id: event.call_id,
    author_id,
    author_name: snapshot.display_name.clone(),
    ...
});

Frontend drops the author namespace — crates/lanspread-tauri-deno-ts/src/lib/callToPlay.ts:135-145

A later event with the same nonce replaces another author's event before grouping.

const unique = new Map(input.map(event => [event.id, event]));
const byCall = new Map<string, CallToPlayViewEvent[]>();
for (const event of unique.values()) { ... }

Severity

Low — The attack can hide or substitute UI collaboration state but cannot forge authenticated author authority, modify files, or execute code.

Impact grows if Call-to-Play state later triggers privileged actions automatically.

Impact assessment:

  • Level: low
  • Rationale: Only ephemeral collaboration UI integrity is affected.

Likelihood assessment:

  • Level: high
  • Rationale: The nonce is visible to connected peers and can be copied exactly.

Remediation

Use (author_id, event.id) as the key for deduplication, messages, React keys, and ordering; add cross-author collision tests including collision with a creator's Create event.

[15] Forged mDNS candidates can monopolize discovery slots

Field Value
Severity low
Confidence high
Confidence rationale Pre-auth admission, full-set rejection, and uniqueness keys are explicit.
Category resource-exhaustion
CWE CWE-400
Affected lines crates/lanspread-peer/src/services/discovery.rs:30-50, crates/lanspread-peer/src/services/discovery.rs:233-259, crates/lanspread-peer/src/services/discovery.rs:294-309

Summary

Sixty-four unique attacker-controlled PeerId/address hints occupy every active and recent candidate slot before TLS proof, causing legitimate new candidates to be dropped while the attacker rotates records.

Root Cause

First-come discovery capacity is keyed only by unauthenticated claimed PeerId and full socket address, with no origin fairness.

Attacker controls both uniqueness keys — crates/lanspread-peer/src/services/discovery.rs:30-50

Distinct IDs and ports from one host fill the entire budget.

const MAX_ACTIVE_DISCOVERY_CANDIDATES: usize = 64;
...
endpoint.peer_id == candidate.peer_id || endpoint.addr == candidate.addr
...
|| self.entries.len() >= MAX_ACTIVE_DISCOVERY_CANDIDATES

Work starts from claimed fields — crates/lanspread-peer/src/services/discovery.rs:233-259

TLS proof happens after the slot is occupied.

if let Some(endpoint) = validated_candidate_endpoint(&info) {
    ...
    let handshake = ReservedCandidateHandshake::reserve(handshake_ctx, endpoint).await?;
    active_candidates.insert(endpoint);
    negotiations.push(run_protocol_negotiation(...));
}

Full set drops every later candidate — crates/lanspread-peer/src/services/discovery.rs:300-309

No fair queue or per-origin reserve remains for legitimate candidates.

active.len() < MAX_ACTIVE_DISCOVERY_CANDIDATES
    && !candidate_conflicts(active, candidate)
    && recent.try_record(candidate, now)

Validation

Validated with low severity. The candidate cap protects memory but not fair availability.

Validation method: Independent static source trace against the registered revision and strongest counterevidence.

  • Status: validated
  • Disposition: reportable

Attacker controls both uniqueness keys — crates/lanspread-peer/src/services/discovery.rs:30-50

Distinct IDs and ports from one host fill the entire budget.

const MAX_ACTIVE_DISCOVERY_CANDIDATES: usize = 64;
...
endpoint.peer_id == candidate.peer_id || endpoint.addr == candidate.addr
...
|| self.entries.len() >= MAX_ACTIVE_DISCOVERY_CANDIDATES

Work starts from claimed fields — crates/lanspread-peer/src/services/discovery.rs:233-259

TLS proof happens after the slot is occupied.

if let Some(endpoint) = validated_candidate_endpoint(&info) {
    ...
    let handshake = ReservedCandidateHandshake::reserve(handshake_ctx, endpoint).await?;
    active_candidates.insert(endpoint);
    negotiations.push(run_protocol_negotiation(...));
}

Full set drops every later candidate — crates/lanspread-peer/src/services/discovery.rs:300-309

No fair queue or per-origin reserve remains for legitimate candidates.

active.len() < MAX_ACTIVE_DISCOVERY_CANDIDATES
    && !candidate_conflicts(active, candidate)
    && recent.try_record(candidate, now)

Assertions:

  • No private key is required to occupy a slot until handshake fails.
  • All later candidates are rejected at 64 active entries.
  • An attacker can rotate IDs/ports after deadlines.

Counterevidence and remaining uncertainty:

  • Work is capped and timed.
  • Duplicate IDs/addresses coalesce.
  • No state commits without pinned TLS.

Dataflow

mDNS TXT/address -> PeerEndpoint -> active candidate set -> pinned negotiation -> failure/repeat.

  • Source: Attacker-controlled multicast advertisements.

  • Sink: Discovery candidate capacity.

  • Outcome: Legitimate new peers are not discovered.

Attacker controls both uniqueness keys — crates/lanspread-peer/src/services/discovery.rs:30-50

Distinct IDs and ports from one host fill the entire budget.

const MAX_ACTIVE_DISCOVERY_CANDIDATES: usize = 64;
...
endpoint.peer_id == candidate.peer_id || endpoint.addr == candidate.addr
...
|| self.entries.len() >= MAX_ACTIVE_DISCOVERY_CANDIDATES

Work starts from claimed fields — crates/lanspread-peer/src/services/discovery.rs:233-259

TLS proof happens after the slot is occupied.

if let Some(endpoint) = validated_candidate_endpoint(&info) {
    ...
    let handshake = ReservedCandidateHandshake::reserve(handshake_ctx, endpoint).await?;
    active_candidates.insert(endpoint);
    negotiations.push(run_protocol_negotiation(...));
}

Full set drops every later candidate — crates/lanspread-peer/src/services/discovery.rs:300-309

No fair queue or per-origin reserve remains for legitimate candidates.

active.len() < MAX_ACTIVE_DISCOVERY_CANDIDATES
    && !candidate_conflicts(active, candidate)
    && recent.try_record(candidate, now)

Reachability

Same multicast LAN while discovery is enabled.

  • Attacker: Hostile LAN participant.

  • Entry point: mDNS browser service observations.

Preconditions:

  • Discovery enabled
  • Ability to advertise 64 unique records continuously

Existing controls:

  • 64 active/recent cap
  • 5-second cooldown
  • Pinned TLS before commit

Attacker controls both uniqueness keys — crates/lanspread-peer/src/services/discovery.rs:30-50

Distinct IDs and ports from one host fill the entire budget.

const MAX_ACTIVE_DISCOVERY_CANDIDATES: usize = 64;
...
endpoint.peer_id == candidate.peer_id || endpoint.addr == candidate.addr
...
|| self.entries.len() >= MAX_ACTIVE_DISCOVERY_CANDIDATES

Work starts from claimed fields — crates/lanspread-peer/src/services/discovery.rs:233-259

TLS proof happens after the slot is occupied.

if let Some(endpoint) = validated_candidate_endpoint(&info) {
    ...
    let handshake = ReservedCandidateHandshake::reserve(handshake_ctx, endpoint).await?;
    active_candidates.insert(endpoint);
    negotiations.push(run_protocol_negotiation(...));
}

Full set drops every later candidate — crates/lanspread-peer/src/services/discovery.rs:300-309

No fair queue or per-origin reserve remains for legitimate candidates.

active.len() < MAX_ACTIVE_DISCOVERY_CANDIDATES
    && !candidate_conflicts(active, candidate)
    && recent.try_record(candidate, now)

Severity

Low — The attack suppresses discovery of new peers but is same-LAN, requires sustained advertisements, and cannot commit state or affect already known authenticated peers.

Severity rises if discovery is the only operational path and attacks persist throughout events.

Impact assessment:

  • Level: medium
  • Rationale: New peer discovery is denied; existing state and content remain protected.

Likelihood assessment:

  • Level: high
  • Rationale: Only forged advertisements are required.

Remediation

Add per-source-IP quotas, preserve capacity across origins/known peers, and use fair/randomized replacement or a cheap proof-of-key before the longer negotiation slot.

Reviewed Surfaces

Surface Risk Area Outcome Notes
Peer identity, authenticated endpoint generations, and aggregate remote state Identity and state resource limits Reported Reported aggregate Sybil-state exhaustion; responder pinning, session/generation fencing, and content authority otherwise held.
Anonymous QUIC admission, control frames, bulk transfers, and native StreamInstall work Remote resource exhaustion Reported Reported origin-unfair global pools/native extractor fanout and eager length-prefix allocation.
mDNS discovery, state hints, and liveness reconciliation Discovery availability and confused deputy Reported Reported pre-auth candidate monopoly and unbound third-party pull hints; pinned follow-up preserves state integrity.
Catalog transfer admission, manifest cache, ordinary downloads, and retries Transfer resource budgets Reported Reported pre-admission manifest caching and Sybil-multiplied per-chunk deadlines; chunk/path/hash verification held.
Download confinement, ordinary install/update/uninstall, Stream Install, and recovery Installed-content integrity Reported Reported uncatalogued root archive extraction. No remote path escape, chunk hash bypass, or Stream Install output bypass found.
Call-to-Play protocol, author ownership, frontend reduction, and rendering UI integrity and availability Reported Reported cross-author EventNonce collision and maximal active-call rendering cost; creator authority and responder attribution held.
Tauri commands, capabilities, storage, logs, and Windows process launch Native privilege boundary Reported Reported runas of mutable game scripts. No hostile-peer XSS, raw HTML/eval, arbitrary thumbnail/log read, or remote capability grant found.
Catalog publisher, package traversal, just recipes, build gates, and fixture/production separation Build and publication authority Reported Reported shell interpolation and bounded out-of-root preflight reads. Atomic publication and production fixture gate held.
Game-directory monitoring, migration, persisted indexes, and public per-game state helpers Local filesystem input Reported Reported unbounded local ingestion/migration work and public marker path traversal.
Protocol-v8 codecs, canonical IDs/paths, strict JSON, and legacy rejection not recorded No issue found Strict current-only shapes, canonical path/ID types, unknown-field rejection, and semantic domain validation were traced; the aggregate decoder allocation issue is separately reported.
Installation key persistence and secret handling not recorded No issue found Bounded strict identity parsing, certificate/key/SPKI/SAN consistency, no-follow/no-clobber persistence, Unix private mode, and redacted diagnostics were verified.
Cancellation, task/process ownership, generation shutdown, and crash recovery not recorded No issue found Owned child tasks, process reaping, network admission closure, operation drain, version/install intents, and quarantine paths were traced with no detached product mutation path found.
Frontend rendering, URLs, CSS, async ownership, and auxiliary windows not recorded No issue found Remote values are React-escaped and no raw HTML, eval, javascript URL, or remote navigation sink was found; CSP null and broad app permissions remain defense-in-depth concerns.
Peer CLI, Docker/just/Python scenario harnesses, and integration tests not recorded No issue found Developer-authority boundaries, argv construction, cleanup scopes, fixture separation, and async lifecycle tests were reviewed; local stdin self-exhaustion was not treated as a security boundary.
Discovery length-prefix allocation candidate not recorded Rejected Merged into resource-exhaustion.length-prefix-eager-reserve; same locked decoder, aggregate-memory failure, evidence, and remediation. Evidence: discovery.rs:30-259; network.rs:98-215.
Missing application-command ACL candidate not recorded Rejected No source-backed attacker-controlled script execution exists in either fixed local log window; fixed local URLs and React escaping are counterevidence. Retained as least-privilege hardening.
Broad main-window plugin authority candidate not recorded Rejected Requires a compromised main renderer, already intentionally trusted with native custom commands; no current injection/navigation route establishes the prerequisite.
Persistent Sybil peer/author slots candidate not recorded Rejected Merged into resource-exhaustion.sybil-aggregate-state; same identity multiplication, retained-state budget, unbounded publication, and remediation.
Unbounded peer CLI input candidate not recorded Rejected Local stdin controller already owns the developer harness and can block/terminate it; no lower-privilege or remote boundary is crossed. Evidence: peer-cli/main.rs:167-180,409-428.
Windows publisher TOCTOU candidate not recorded Rejected Merged into path-traversal.catalog-preflight-links; same path-based read/rooted-handle failure and remediation. Evidence: catalog_publisher/package.rs:352-425.
Markerless local uninstall candidate not recorded Rejected Explicit authorized uninstall semantics: local/ defines installed state and user-invoked uninstall intentionally removes it; marker creation proves the renamed backup is transaction-owned, not prior install provenance.
Markerless local update candidate not recorded Rejected Explicit authorized update semantics: update intentionally replaces existing local/, preserves it as backup until successful promotion, and restores on failure.
Path-only ownership generation candidate not recorded Rejected No meaningful attacker capability gain: an actor able to replace the entire game root already controls those files, and source tests intentionally preserve path ownership across recreation of the same configured root.
StreamInstall subprocess fanout candidate not recorded Rejected Merged into resource-exhaustion.anonymous-network-pools as the expensive bulk operation enabled by the same absent per-origin/costly-work quota.
Legacy library-index migration candidate not recorded Rejected Merged into resource-exhaustion.local-library-ingestion; same selected-filesystem byte/cardinality budget gap and remediation.
Sybil peers can exhaust aggregate state and unbounded UI publication not recorded Reported Validated finding 1.
Anonymous LAN requesters can monopolize global pools and native extractors not recorded Reported Validated finding 2.
Rejected bulk requests can populate the persistent manifest cache not recorded Reported Validated finding 3.
Control-frame prefixes can reserve about 512 MiB across concurrent decoders not recorded Reported Validated finding 4.
Mutable game scripts are launched elevated without launch-time trust binding not recorded Reported Validated finding 5.
Cross-author event-ID collisions can suppress Call-to-Play entries not recorded Reported Validated finding 6.
Unauthenticated hints can make the victim pull arbitrary known peers not recorded Reported Validated finding 7.
Forged mDNS candidates can monopolize discovery slots not recorded Reported Validated finding 8.
Selected game directories can trigger unbounded monitoring and migration work not recorded Reported Validated finding 9.
Catalog/build recipe arguments are interpolated as shell code not recorded Reported Validated finding 10.
Catalog preflight can read outside the package root through links and Windows races not recorded Reported Validated finding 11.
Ordinary install extracts uncatalogued root archives without output verification not recorded Reported Validated finding 12.
Discovery prefix allocation not recorded Rejected Merged into the reportable length-prefix finding: same locked decoder, aggregate-memory failure, and remediation; the discovery path is preserved as an affected entry point.
Application command ACL not recorded Rejected Not separately reportable: no source-backed attacker-controlled script execution exists in either fixed local log window; React text rendering and fixed URLs are counterevidence. Retained as least-privilege hardening.
Main-window plugin authority not recorded Rejected Not separately reportable: it requires a compromised main renderer, for which the application intentionally exposes a broad native command surface; no current injection/navigation route establishes that prerequisite.
Sybil peer/author slots not recorded Rejected Merged into the reportable aggregate Sybil-state finding: same first-come identity admission, retained-state budget, unbounded full-view publication, and remediation.
Unbounded peer CLI input not recorded Rejected Rejected as self-only developer-harness behavior: the local stdin controller already owns the harness and can terminate or block it; no lower-privilege or remote boundary is crossed.
Windows publisher TOCTOU not recorded Rejected Merged into the publisher link/TOCTOU finding because both arise from path-based reads without rooted no-follow identity and share the same remediation.
Uninstall markerless local not recorded Rejected Rejected as explicit authorized uninstall semantics. local/ defines installed state and the user-invoked uninstall intentionally removes it; .lanspread_owned is added so the renamed backup is transaction-owned, not as prior install provenance.
Update markerless local not recorded Rejected Rejected as explicit authorized update semantics. A user-invoked update intentionally replaces an existing local/ tree while preserving it as backup until promotion succeeds.
Path-only root generation ownership not recorded Rejected Rejected for lack of meaningful attacker capability gain: a same-authority actor able to replace the whole game root already controls those files, and tests/documentation intentionally preserve path ownership across recreation of the same configured root.
StreamInstall subprocess fanout not recorded Rejected Merged into the anonymous global-pools finding as the expensive bulk operation enabled by the same missing per-origin/global costly-work quota.
Legacy index migration not recorded Rejected Merged into the local-library ingestion finding because it is another whole-file/cardinality budget gap on the same selected-filesystem boundary.
Independent baseline audit not recorded Needs follow-up Two candidates.
Network, TLS, protocol, and transfer admission not recorded Needs follow-up Three candidates.
Tauri commands, frontend, windows, and process launch not recorded Needs follow-up Three candidates.
Discovery, liveness, peer state, and Call-to-Play not recorded Needs follow-up Four candidates.
Peer CLI, local library monitor, and runtime glue not recorded Needs follow-up Two candidates.
Catalog publisher, build gates, and package traversal not recorded Needs follow-up Three candidates.
Download confinement, install/update/uninstall, streamed install, and recovery not recorded Needs follow-up Seven candidates.
One peer can force continuous rendering of thousands of active calls not recorded Reported Validated residual frontend finding.
Sybil sources can multiply one chunk deadline into a multi-hour retry loop not recorded Reported Validated residual download finding.
Residual download planning, retry, progress, and drain modules not recorded Needs follow-up Retry-budget candidate remains pending.
Residual production frontend components and reducers not recorded Needs follow-up One semantic rendering-budget candidate checkpointed before validation.
Public state helpers permit marker writes outside the state directory not recorded Reported Validated public API path-traversal finding.
Residual peer-core lifecycle, state paths, quarantine, startup, and façades not recorded Needs follow-up One public state-path candidate checkpointed before validation.

Open Questions And Follow Up

  • The external 186-game production package corpus and generated production manifests are absent, so their byte provenance and aggregate manifest-memory size could not be verified.
    • Follow-up prompt: Re-run catalog provenance and manifest-size review with the retained production corpus and generated manifests.
  • Checked-in unrar sidecars are opaque binaries with no checked-in upstream version/source/signature provenance.
    • Follow-up prompt: Establish vendor release/source mapping and reproducible or signed provenance for each platform sidecar.
  • This was an offline static scan; physical-LAN behavior, Windows UAC/runtime paths, and live memory/DOM exhaustion were not reproduced.
    • Follow-up prompt: Run bounded adversarial integration tests on representative Windows and physical-LAN hosts.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-legacy-index-unbounded-migration and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-stream-install-subprocess-fanout and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-ownership-root-generation and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-update-adopts-foreign-local and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-uninstall-adopts-foreign-local and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-windows-package-toctou and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-cli-unbounded-jsonl and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-sybil-peer-author-slots and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-main-window-plugin-authority and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-app-command-acl and close its stated proof gap.
  • Pending parent validation.
    • Follow-up prompt: Review deferred unit cand-discovery-prefix-allocation and close its stated proof gap.