Skip to content

[codex] Harden MCP audit log bounds and redaction - #3287

Merged
Widthdom merged 4 commits into
mainfrom
codex/fix-issue3067-3106-3237-3180
Jun 5, 2026
Merged

[codex] Harden MCP audit log bounds and redaction#3287
Widthdom merged 4 commits into
mainfrom
codex/fix-issue3067-3106-3237-3180

Conversation

@Widthdom

@Widthdom Widthdom commented Jun 5, 2026

Copy link
Copy Markdown
Owner

Summary

  • Reject excessive --audit-log-max-bytes values above the documented 1 GiB cap.
  • Redact secret-like MCP audit arg_values keys and token-shaped values when include-values is enabled.
  • Budget include-values payloads and top-level property names before writing audit records.
  • Cap audit event key/request-id surfaces and fall back when records exceed the event byte budget.

Validation

  • dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj --no-build --filter "FullyQualifiedName~AuditLogSinkTests|FullyQualifiedName~McpAuditLogTests|FullyQualifiedName~McpServerTests.ProcessLineAsync_CapsTelemetryArgumentKeyCount|FullyQualifiedName~ProgramRunnerTests.TryConsumeAuditLogFlags_MaxBytes"
  • Codex adversarial review also ran dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj --no-restore --filter "AuditLogSinkTests|McpAuditLogTests|McpServerTests|ProgramRunnerTests" successfully.
  • dotnet run --no-restore --project tools/CodeIndex.Changelog -- check
  • git diff --check origin/main..HEAD
  • dotnet ./src/CodeIndex/bin/Debug/net8.0/cdidx.dll index . --rebuild --yes --json
  • dotnet ./src/CodeIndex/bin/Debug/net8.0/cdidx.dll status --check --json
  • Codex adversarial review: final pass found no new blocking/actionable correctness issues.

Fixes #3067
Fixes #3106
Fixes #3237
Fixes #3180

@Widthdom
Widthdom marked this pull request as ready for review June 5, 2026 03:45
@Widthdom
Widthdom merged commit ebb8220 into main Jun 5, 2026
10 checks passed
@Widthdom
Widthdom deleted the codex/fix-issue3067-3106-3237-3180 branch June 6, 2026 18:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant