{
  "schema": "aidefend-secureflow-metadata-v1",
  "flow_id": "aidefend-research-sf0057-agentcore-harness-shell-identity-credential",
  "title": "AgentCore Harness Identity Credential Exfiltration and Replay",
  "subtitle": "A controlled SupportCo test exfiltrated and replayed the operator's MCP service-account JWT, not an end-user JWT.",
  "summary": "Unit 42's controlled SupportCo scenario placed instructions in an inbound support ticket. With a permissive model and default shell tool, the agent fetched and ran a recon script as root in AgentCore Harness. The shell shared UID and readable /proc/1/mem access with the harness process; researchers recovered a plaintext JWT for the operator's downstream MCP service account and its endpoint. The injected script sent both in one HTTP POST to a simulated attacker webhook; the researchers replayed the JWT from a laptop and retrieved sample customer PII through the downstream MCP server. AWS treated this as shared-responsibility configuration guidance, not a patched service vulnerability.",
  "reviewed": true,
  "import_status": "curated-research",
  "ai_layers": [
    "autonomous-agents"
  ],
  "risk_impact": [
    "credential-identity-theft"
  ],
  "affected_components": [
    "inbound support ticket",
    "AgentCore Harness shell tool",
    "/proc/1/maps and /proc/1/mem",
    "operator MCP service-account JWT"
  ],
  "source_research": {
    "provider": "Palo Alto Networks Unit 42",
    "primary_url": "https://unit42.paloaltonetworks.com/securing-aws-agentcore-harness-credentials/",
    "published": "2026-09-18",
    "note": "AIDEFEND-curated public SecureFlow based on public reporting and supporting references. This is not a MITRE ATLAS case-study conversion."
  },
  "attack_steps": [
    {
      "id": "step-1",
      "title": "Put Diagnostic Instructions in a Support Ticket",
      "tactic": "AML.TA0001",
      "technique": "AML.T0065",
      "summary": "A hidden HTML comment in an inbound ticket tells the agent to fetch and run an attacker-controlled diagnostic script.",
      "zhTitle": "在客服票單放入偽裝成診斷要求的指示",
      "zhSummary": "進站票單的隱藏 HTML 註解要求代理下載並執行攻擊者控制的診斷程式。",
      "layout": {
        "x": -960,
        "y": 0
      }
    },
    {
      "id": "step-2",
      "title": "Agent Calls the Default Shell Tool",
      "tactic": "AML.TA0005",
      "technique": "AML.T0053",
      "summary": "The permissive test model follows the ticket and uses the built-in shell, which is enabled unless allowedTools is scoped at InvokeHarness.",
      "zhTitle": "代理呼叫預設開啟的 shell 工具",
      "zhSummary": "受測的較寬鬆模型依票單內容呼叫內建 shell；除非在 InvokeHarness 以 allowedTools 限縮，否則此工具預設可用。",
      "layout": {
        "x": -480,
        "y": 0
      }
    },
    {
      "id": "step-3",
      "title": "Shell Reads Harness Process Memory",
      "tactic": "AML.TA0013",
      "technique": "AML.T0090",
      "summary": "The shell runs as root and has the same UID as PID 1; the researchers read /proc/1/maps and readable regions of /proc/1/mem.",
      "zhTitle": "shell 讀取 Harness 主程序記憶體",
      "zhSummary": "shell 以 root 執行，與 PID 1 共用 UID；研究者讀取 /proc/1/maps 與 /proc/1/mem 中可讀的記憶體區段。",
      "layout": {
        "x": 0,
        "y": 0
      }
    },
    {
      "id": "step-4",
      "title": "Recover Operator MCP Service Credential",
      "tactic": "AML.TA0013",
      "technique": "AML.T0090",
      "summary": "The memory scan finds the operator's MCP service-account JWT and downstream server URL. It is not the invoking end user's token.",
      "zhTitle": "取得營運方 MCP 服務帳號憑證",
      "zhSummary": "記憶體掃描找到營運方的 MCP 服務帳號 JWT 與下游伺服器網址；這不是發起呼叫的終端使用者憑證。",
      "layout": {
        "x": 480,
        "y": 0
      }
    },
    {
      "id": "step-5",
      "title": "Exfiltrate Service Credential via HTTP POST",
      "tactic": "AML.TA0010",
      "technique": "AML.T0025",
      "summary": "The injected script sent the 1,034-byte operator service-account JWT and MCP server URL in one HTTP POST to the researchers' simulated attacker webhook.",
      "zhTitle": "以 HTTP POST 將服務憑證傳到模擬攻擊者的接收端",
      "zhSummary": "注入後執行的程式，以一次 HTTP POST 把 1,034 位元組的營運方服務帳號 JWT 與 MCP 伺服器網址，傳到研究人員模擬的攻擊者 webhook。",
      "layout": {
        "x": 960,
        "y": 0
      }
    },
    {
      "id": "step-6",
      "title": "Replay the JWT Against the Downstream MCP Server",
      "tactic": "AML.TA0004",
      "technique": "AML.T0012",
      "summary": "From a separate laptop, the researchers replayed the JWT, listed MCP tools, and called lookup_customer to retrieve sample customer PII in the controlled SupportCo test.",
      "zhTitle": "從另一台電腦重用 JWT 存取下游 MCP 服務",
      "zhSummary": "研究人員從另一台電腦，以取得的 JWT 連上原設定的 MCP 伺服器，列出可用工具並呼叫 lookup_customer，讀取虛構 SupportCo 測試中的客戶個資範例。",
      "layout": {
        "x": 1440,
        "y": 0
      }
    }
  ],
  "threat_refs": [
    {
      "id": "AML.T0051.001",
      "name": "LLM Prompt Injection: Indirect"
    },
    {
      "id": "AML.T0053",
      "name": "AI Agent Tool Invocation"
    },
    {
      "id": "AML.T0090",
      "name": "OS Credential Dumping"
    },
    {
      "id": "AML.T0025",
      "name": "Exfiltration via Cyber Means"
    },
    {
      "id": "AML.T0012",
      "name": "Valid Accounts"
    }
  ]
}
