The vulnerability exists due to a missing authorization check in the communication channel between the web page context and the extension's privileged background script. The root cause is the handleArtifactsBridge function in the content script (automation.content.ts), which listens for window.postMessage events. This function unconditionally forwards messages formatted for 'summarize-artifacts' to the background script. A malicious script on a webpage can exploit this by sending a crafted message to trigger actions.
The message is then received by the background script's handler, created by createRuntimeActionsHandler. Prior to the patch, this handler did not validate if the tab sending the artifact request was authorized to do so. It would blindly execute operations like reading, creating, or deleting automation artifacts.
The patch remediates this by removing the insecure handleArtifactsBridge entirely and introducing an "arming" mechanism. Now, a trusted part of the extension must explicitly arm a tab, and the createRuntimeActionsHandler verifies this armed status using getArtifactsGuardError before processing any artifact-related requests, effectively closing the authorization gap.