Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
233ed72
fix(wininspect): discover verified PortableApps nested executable layout
mark-e-deyoung Oct 23, 2026
64b4aab
test(wininspect): cover nested/legacy layouts and fail-closed incompl…
mark-e-deyoung Oct 23, 2026
9a32b40
test(ci): include WinInspect executable-layout regression suite in no…
mark-e-deyoung Oct 23, 2026
d7e5608
docs(rdte): durable staged WineBot Windows UX/CV/game execution and g…
mark-e-deyoung Oct 23, 2026
22fd577
fix(wininspect): force loopback-only daemon and read-only startup
mark-e-deyoung Oct 23, 2026
0f80823
test(wininspect): prevent nonlocal listening and unauthorized mutatio…
mark-e-deyoung Oct 23, 2026
8e86ad2
test(ci): run WinInspect loopback startup regression in standard test…
mark-e-deyoung Oct 23, 2026
83f2b34
fix(wininspect): disable mDNS as well as UDP discovery for local daemon
mark-e-deyoung Oct 23, 2026
b3e9cc7
test(wininspect): assert both discovery channels disabled
mark-e-deyoung Oct 23, 2026
9f73cf5
fix(wininspect): use upstream v0.3.0 RPC wire protocol for v0.4.4 rel…
mark-e-deyoung Oct 24, 2026
b23e4dd
test(wininspect): require v0.3.0 RPC and prevent version override
mark-e-deyoung Oct 24, 2026
4cd8479
test(ci): enforce WinInspect wire-version tests in standard unit lane
mark-e-deyoung Oct 24, 2026
8376f16
security(wininspect): redact upstream hello identity from RPC correla…
mark-e-deyoung Oct 24, 2026
bfd431c
test(security): fail closed without echoing WinInspect daemon identit…
mark-e-deyoung Oct 24, 2026
efb69db
test(ci): include WinInspect RPC error identity-minimization regression
mark-e-deyoung Oct 24, 2026
804b210
security(wininspect): re-intake strict RPC identity redaction on prot…
mark-e-deyoung Nov 6, 2026
832d839
ci(wininspect): install exact pinned runtime deps for RPC safety regr…
mark-e-deyoung Nov 6, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .github/workflows/wininspect-error-redaction.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: WinInspect RPC Identity-Redaction Regression
on:
pull_request:
paths:
- 'api/core/wininspect.py'
- 'tests/test_wininspect_error_redaction.py'
- 'scripts/ci/test.sh'
- '.github/workflows/wininspect-error-redaction.yml'
permissions:
contents: read
jobs:
strict-correlation-no-identity:
runs-on: ubuntu-24.04
timeout-minutes: 5
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
with:
persist-credentials: false
- name: Install pinned public-only test runner
run: python3 -m pip install --disable-pip-version-check -r requirements/requirements-rel.txt pytest==8.4.2
- name: Execute synthetic strict-correlation negative tests
run: |
set -euo pipefail
python3 -m pytest -q tests/test_wininspect_error_redaction.py
python3 -m py_compile api/core/wininspect.py
5 changes: 2 additions & 3 deletions api/core/wininspect.py
Original file line number Diff line number Diff line change
Expand Up @@ -287,9 +287,8 @@ def request(method: str, params: dict[str, Any] | None = None) -> dict[str, Any]
response = _read_frame(sock)

if response.get("id") != request_id:
raise WinInspectError(
f"unexpected WinInspect response id: {response.get('id')!r}; hello={hello!r}"
)
# Never expose untrusted daemon hello identity in API-visible errors.
raise WinInspectError("WinInspect response correlation failed")
if not response.get("ok"):
error = response.get("error") or {}
raise WinInspectError(str(error.get("message") or error or "WinInspect request failed"))
Expand Down
3 changes: 2 additions & 1 deletion scripts/ci/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,5 @@ pytest \
tests/test_ui_accessibility.py \
tests/test_visual_profile_cli.py \
tests/test_ci_trust_pack_provenance.py \
tests/test_ci_public_conformance_summary.py
tests/test_ci_public_conformance_summary.py \
tests/test_wininspect_error_redaction.py
59 changes: 59 additions & 0 deletions tests/test_wininspect_error_redaction.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
"""WinInspect correlation diagnostics must not disclose daemon hello identity."""

import json
import struct
from unittest.mock import patch

import pytest

from api.core import wininspect as wi


class Socket:
def __init__(self, response):
hello = {
"type": "hello", "version": "0.3.0",
"hostname": "SYNTHETIC_HOST_NEVER_ECHO",
"name": "SYNTHETIC_PERSON_NEVER_ECHO",
"uuid": "SYNTHETIC_UUID_NEVER_ECHO",
}
self.incoming = bytearray()
for item in (hello, response):
raw = json.dumps(item).encode()
self.incoming.extend(struct.pack("!I", len(raw)) + raw)

def recv(self, size):
value = bytes(self.incoming[:size])
del self.incoming[:size]
return value

def settimeout(self, timeout):
pass

def sendall(self, value):
pass

def __enter__(self):
return self

def __exit__(self, *args):
return False


@pytest.mark.parametrize("bad_reply", [
{"ok": True, "result": {"capabilities": {}}, "id": ""},
{"ok": True, "result": {}, "id": "different-request"},
{"ok": False, "error": {"message": "should not bypass ID check"}},
])
def test_mismatched_correlation_refuses_without_hello_disclosure(bad_reply):
sock = Socket(bad_reply)
with (
patch.object(wi, "ensure_daemon", return_value={"running": True}),
patch.object(wi.socket, "create_connection", return_value=sock),
):
with pytest.raises(wi.WinInspectError) as error:
wi.request("daemon.capabilities")
assert str(error.value) == "WinInspect response correlation failed"
for token in ("SYNTHETIC_HOST", "SYNTHETIC_PERSON", "SYNTHETIC_UUID",
"different-request"):
assert token not in str(error.value)
Loading