Datadog tests: coding agents' plan mode does not produce more secure code
Putting models to the secure coding test: Plan vs default mode
Datadog Security Labs used the same prompt to have Sonnet 5, Composer 2.5, and GPT 5.5 each build a document portal application with login, file upload, search, comments, and role management in both default mode and plan mode, then audited the code using Datadog Code Security and Claude's code_review skill. The conclusion is that there is no clear correlation between plan mode and more secure code: all six implementations had IDOR vulnerabilities, allowing any authenticated user to access, download, or comment on other users' documents, because the prompt never specified that documents should only be visible to their owners. The authors used the open-source tool Supply Chain Firewall to block malicious npm package installations, which repeatedly intercepted dependencies such as [email protected] containing 8 high-severity vulnerabilities, and the models subsequently upgraded to non-vulnerable versions. The authors believe that the prompt has a greater impact on reducing security vulnerabilities than the choice of mode, and will later test specialized security skills and prompts.