# CF-001/C administrative graph: the second graph of counterfactual cut analysis.
# A node is anything that holds or confers authority: a workload, a service, a store, a team's credential.
# An edge x -> y means that whoever controls x gains an authority over y.
# A control is independent of the compromised workload only if no path leads from that workload
# to any node holding one of its six authorities.
# Every node and edge here is hypothetical except the one marked "reported".
version: 1
start: W
authorities: [configuration, identity, deployment, bypass, recovery, evidence]
nodes:
  W:     "Agent workload"
  PX:    "Artifactory proxy"
  PXA:   "Artifactory administrator"
  RELAY: "Approved relay service"
  NA:    "Network administrators"
  NI:    "Network admin identity issuer"
  NP:    "Network change pipeline"
  FL:    "Flow log store"
  SS:    "Shared secrets store"
  IDP:   "Shared identity provider"
edges:
  - {from: W,  to: PX,  why: "The agent acts through the proxy it was granted (edge 1)", basis: reported}
  - {from: W,  to: PXA, why: "Agents became Artifactory administrators on 26 June (OpenAI)", basis: reported}
  - {from: W,  to: RELAY, why: "An approved service relays arbitrary requests", basis: hypothetical, when: B_fails}
  - {from: PX, to: SS,  why: "The proxy's service identity can read the shared secrets store", basis: hypothetical, when: shared}
  - {from: SS, to: NA,  why: "The store holds a network administrator credential", basis: hypothetical, when: shared}
  - {from: SS, to: IDP, why: "The store holds an identity provider administrator credential", basis: hypothetical, when: shared}
  - {from: IDP, to: FL, why: "The identity provider issues the flow log writer's identity", basis: hypothetical, when: shared}
controls:
  P1:
    name: "Egress rule inside the proxy"
    holders:
      configuration: [PXA]
      identity: [PXA]
      deployment: [PXA]
      bypass: [RELAY]
      recovery: [PXA]
      evidence: [PXA]
  D1:
    name: "D1 independent egress"
    holders:
      configuration: [NA]
      identity: {separate: [NI], shared: [IDP]}
      deployment: [NP]
      bypass: [RELAY]
      recovery: [NA]
      evidence: [FL]
arrangements:
  separate: {label: "Separate administration", flags: []}
  shared:   {label: "Shared secrets store and identity provider", flags: [shared]}
