<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Goodroom</title>
    <description>The latest articles on DEV Community by Goodroom (@goodroom).</description>
    <link>https://dev.to/goodroom</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4056368%2F07cbe8cb-d112-46ed-9727-313d8959cbe6.png</url>
      <title>DEV Community: Goodroom</title>
      <link>https://dev.to/goodroom</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/goodroom"/>
    <language>en</language>
    <item>
      <title>Adding passkey-backed human approval to high-risk MCP actions</title>
      <dc:creator>Goodroom</dc:creator>
      <pubDate>Fri, 31 Jul 2026 13:23:59 +0000</pubDate>
      <link>https://dev.to/goodroom/adding-passkey-backed-human-approval-to-high-risk-mcp-actions-38h</link>
      <guid>https://dev.to/goodroom/adding-passkey-backed-human-approval-to-high-risk-mcp-actions-38h</guid>
      <description>&lt;p&gt;AI agents are increasingly able to deploy code, modify infrastructure, query sensitive systems, and initiate financial operations. A conversational &lt;strong&gt;“Are you sure?”&lt;/strong&gt; prompt is useful, but it is not independent authorization. The same agent that proposed the action may also control the confirmation flow.&lt;/p&gt;

&lt;p&gt;I wanted an approval mechanism with four properties:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;A person approves one specific action.&lt;/li&gt;
&lt;li&gt;The approval expires quickly.&lt;/li&gt;
&lt;li&gt;It cannot be replayed for another tool call.&lt;/li&gt;
&lt;li&gt;The approval service does not need the agent's prompt or source code.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The resulting design is &lt;strong&gt;GoodRoom.verify&lt;/strong&gt;, an MCP sidecar that pauses a configured high-risk action while an operator verifies with a passkey.&lt;/p&gt;

&lt;h2&gt;
  
  
  The approval flow
&lt;/h2&gt;

&lt;p&gt;The agent calls an MCP tool with a human-readable summary, a SHA-256 hash of the canonical action, a risk level, and an audience identifying the protected tool.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"action_summary"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Deploy migration to production"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"action_hash"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"sha256:..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"risk_level"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"CRITICAL"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"audience"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"tool:db_migrate"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The gateway sends those fields to the approval API and receives separate approval and polling capabilities. The approval page displays the summary and requests WebAuthn user verification.&lt;/p&gt;

&lt;p&gt;After successful verification, the API atomically consumes the challenge and issues a short-lived Ed25519 proof. The MCP gateway downloads the public JWKS and verifies the signature, issuer, audience, action hash, key ID, and expiry locally.&lt;/p&gt;

&lt;p&gt;The protected operation should independently require that proof. Without that enforcement point, an approval UI is only advisory.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why passkeys?
&lt;/h2&gt;

&lt;p&gt;WebAuthn provides phishing-resistant user verification tied to the relying party. The private credential remains in the platform authenticator or hardware key. It also makes physical operator presence a clearer security boundary than another button controlled by the agent runtime.&lt;/p&gt;

&lt;h2&gt;
  
  
  Minimize what crosses the boundary
&lt;/h2&gt;

&lt;p&gt;The approval service does not need the prompt, conversation, source code, or raw tool arguments. GoodRoom.verify receives a bounded display summary and an action hash.&lt;/p&gt;

&lt;p&gt;Persistent audit records can retain the hash, result, proof identifier, and timestamps without retaining the summary.&lt;/p&gt;

&lt;h2&gt;
  
  
  What the proof must bind
&lt;/h2&gt;

&lt;p&gt;A useful execution proof needs more than an “approved” boolean. The GoodRoom.verify design binds it to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the account and challenge;&lt;/li&gt;
&lt;li&gt;the canonical action hash;&lt;/li&gt;
&lt;li&gt;the protected tool audience;&lt;/li&gt;
&lt;li&gt;the risk level;&lt;/li&gt;
&lt;li&gt;a unique proof identifier;&lt;/li&gt;
&lt;li&gt;a short validity window.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The protected tool must reject a mismatched audience or action hash, an expired signature, an unknown signing key, and a reused proof identifier.&lt;/p&gt;

&lt;h2&gt;
  
  
  What this does not solve
&lt;/h2&gt;

&lt;p&gt;This design does not determine whether an action is safe, sandbox the tool, or prevent a runtime from bypassing the approval tool. The agent runtime or tool wrapper must enforce proof verification, and it must hash the same canonical action that will execute.&lt;/p&gt;

&lt;p&gt;That last point matters: if the reviewed payload and executed payload can differ, the approval is meaningless.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where should enforcement live?
&lt;/h2&gt;

&lt;p&gt;There are three plausible places:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Runtime policy:&lt;/strong&gt; easy to apply consistently, but only as strong as the runtime boundary.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;MCP server middleware:&lt;/strong&gt; close to tool dispatch and reusable across tools, but bypassable if another path reaches the tool.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The final tool or API:&lt;/strong&gt; strongest binding to execution, but requires the deepest integration.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;My current preference is defense in depth: runtime or MCP policy for usability, with final verification at the sensitive tool boundary whenever possible.&lt;/p&gt;

&lt;p&gt;GoodRoom.verify is currently a &lt;strong&gt;private-beta MVP&lt;/strong&gt;, not a finished security product. I am looking for feedback from developers building agents with sensitive tools, particularly on proof enforcement and action canonicalization.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://goodroom.in/?utm_source=devto&amp;amp;utm_medium=article&amp;amp;utm_campaign=private_beta" rel="noopener noreferrer"&gt;See the architecture and request beta access&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;What is the riskiest tool your agent can call today, and where do you enforce human approval?&lt;/p&gt;

</description>
      <category>ai</category>
      <category>security</category>
      <category>mcp</category>
      <category>typescript</category>
    </item>
  </channel>
</rss>
