{
  "date": "2026-10-18",
  "system": {
    "macOS": "27.0.1",
    "build": "26A434",
    "Darwin": "27.0.0",
    "xnu": "13432.1.9~1",
    "bash": "5.3.20"
  },
  "native_iterm": {
    "results": [
      {
        "event": "failure",
        "mode": "concurrent",
        "attempt": 11,
        "pid": 89246,
        "sid": 89233,
        "child_pgid_before": 89233,
        "child_pgid_after": 89246,
        "child_result": -1,
        "child_error": 1,
        "parent_result": 0,
        "parent_error": 0,
        "final_pgid": 89246
      },
      {
        "event": "failure",
        "mode": "concurrent",
        "attempt": 26,
        "pid": 89261,
        "sid": 89233,
        "child_pgid_before": 89233,
        "child_pgid_after": 89261,
        "child_result": 0,
        "child_error": 0,
        "parent_result": -1,
        "parent_error": 1,
        "final_pgid": 89261
      },
      {
        "event": "failure",
        "mode": "concurrent",
        "attempt": 60,
        "pid": 89295,
        "sid": 89233,
        "child_pgid_before": 89233,
        "child_pgid_after": 89295,
        "child_result": 0,
        "child_error": 0,
        "parent_result": -1,
        "parent_error": 1,
        "final_pgid": 89295
      },
      {
        "event": "failure",
        "mode": "concurrent",
        "attempt": 69,
        "pid": 89304,
        "sid": 89233,
        "child_pgid_before": 89233,
        "child_pgid_after": 89304,
        "child_result": -1,
        "child_error": 1,
        "parent_result": 0,
        "parent_error": 0,
        "final_pgid": 89304
      },
      {
        "event": "failure",
        "mode": "concurrent",
        "attempt": 101,
        "pid": 89336,
        "sid": 89233,
        "child_pgid_before": 89233,
        "child_pgid_after": 89336,
        "child_result": 0,
        "child_error": 0,
        "parent_result": -1,
        "parent_error": 1,
        "final_pgid": 89336
      },
      {
        "event": "failure",
        "mode": "concurrent",
        "attempt": 129,
        "pid": 89365,
        "sid": 89233,
        "child_pgid_before": 89233,
        "child_pgid_after": 89365,
        "child_result": -1,
        "child_error": 1,
        "parent_result": 0,
        "parent_error": 0,
        "final_pgid": 89365
      },
      {
        "event": "summary",
        "mode": "concurrent",
        "iterations": 1000,
        "child_failures": 12,
        "parent_failures": 6,
        "wrong_final_groups": 0
      },
      {
        "event": "summary",
        "mode": "parent-then-child",
        "iterations": 1000,
        "child_failures": 0,
        "parent_failures": 0,
        "wrong_final_groups": 0
      }
    ],
    "program_dependencies": [
      "/usr/lib/libSystem.B.dylib"
    ]
  },
  "other_controls": [
    {
      "mode": "concurrent",
      "iterations": 1000,
      "child_failures": 25,
      "parent_failures": 6,
      "wrong_final_groups": 0
    },
    {
      "mode": "child-only",
      "iterations": 1000,
      "child_failures": 0,
      "parent_failures": 0,
      "wrong_final_groups": 0
    },
    {
      "mode": "parent-then-child",
      "iterations": 1000,
      "child_failures": 0,
      "parent_failures": 0,
      "wrong_final_groups": 0
    },
    {
      "mode": "child-then-parent",
      "iterations": 1000,
      "child_failures": 0,
      "parent_failures": 0,
      "wrong_final_groups": 0
    }
  ],
  "interpretation": "Overlapping valid setpgid requests can return EPERM even though one request succeeds and the final process group is correct. The same requests serialized did not fail in these tests.",
  "limits": "The precise failing branch inside the installed kernel was not traced. No software fix or workaround was installed.",
  "audit_2026_10_19": {
    "method": "Independently written socketpair-based C harness, invoking syscall(SYS_setpgid, ...) directly instead of the setpgid wrapper; no Bash startup files or diagnostic interposer.",
    "results": [
      {
        "api": "direct syscall",
        "mode": "concurrent",
        "iterations": 2000,
        "parent_errors": 5,
        "child_errors": 26,
        "non_eperm_errors": 0,
        "both_failed": 0,
        "wrong_groups": 0,
        "session_changes": 0
      },
      {
        "api": "direct syscall",
        "mode": "parent-first",
        "iterations": 1000,
        "parent_errors": 0,
        "child_errors": 0,
        "non_eperm_errors": 0,
        "both_failed": 0,
        "wrong_groups": 0,
        "session_changes": 0
      },
      {
        "api": "direct syscall",
        "mode": "child-first",
        "iterations": 1000,
        "parent_errors": 0,
        "child_errors": 0,
        "non_eperm_errors": 0,
        "both_failed": 0,
        "wrong_groups": 0,
        "session_changes": 0
      },
      {
        "api": "direct syscall",
        "mode": "child-only",
        "iterations": 1000,
        "parent_errors": 0,
        "child_errors": 0,
        "non_eperm_errors": 0,
        "both_failed": 0,
        "wrong_groups": 0,
        "session_changes": 0
      }
    ],
    "reviewed_original_harness": "Child remains alive until parent has collected the result and final PGID; no exec or setsid calls; parent and child stay in the same session; errno captured immediately after the failing call.",
    "confirmed": "On this installation, overlapping requests to establish the same process group can return EPERM on one side, while the other succeeds and the final PGID is correct.",
    "not_established": [
      "The exact failing code path inside the installed kernel",
      "Which macOS version introduced the behavior",
      "An Apple acknowledgement or confirmed fixed OS version",
      "That every occurrence of this Bash diagnostic has this cause",
      "That the warning is harmless in every program"
    ],
    "reporting_recommendation": "Report the system-call behavior to Apple; optionally notify Bash maintainers about the user-visible diagnostic. An iTerm-specific root cause is not supported by these reproductions."
  }
}
