Canada's Cyber Centre Says a Single Model's Self-Review Is a Weak Control on Its Own

Guidance from the Canadian Centre for Cyber Security says an AI model can be prompted to review code it has generated, but that a single model's self-review is a weak control on its own. Where appropriate it says to use a separate AI tool for review, and it says qualified people must still review important decisions and approve the final code before deployment.

AI tools can now generate code from plain-language instructions. The Canadian Centre for Cyber Security says the approach is known as vibe coding. Its guidance on managing the security risks took effect on October 29, 2026. It is written for anyone in an organization who uses or oversees vibe coding.

In vibe coding, the guidance says, the tool generates the code. The user remains responsible for directing the work and validating the results. AI-generated code may not work as intended, it says, and can contain errors, vulnerabilities or poor design choices.

AI models "are rapidly changing and improving," the guidance says, which means the limitations and the associated risks will also change. Parts of the guidance follow, not the whole.

Illustration

A Tool Trained to Agree

One of the key limitations the guidance names is that AI "is trained to agree with the user." Models favor alignment and validation with their perception of what the user wants, it says. This is called sycophancy. The guidance says it can be a serious cyber security risk.

If the agent generates responses that reinforce the user's expectations, the user may overlook inaccuracies or security risks. In vibe coding, the guidance says, an agent that behaves this way can jeopardize the robustness and security of the code. It can produce weak or unsecure code.

The guidance says not to treat the AI's agreement with the user's decision "as proof that the code is correct, robust or secure." It says to ask neutral questions that do not suggest a preferred answer. The agent will then have a harder time judging where the user stands, it says, and will likely avoid a sycophantic response.

Who Reviews the Code

Users can and should constantly challenge the AI, the guidance says. They can ask the tool to explain its decisions. They can ask it to review the code it has written. But the guidance says not to rely on the explanation or the self-review as the only control, especially where important organizational tasks are concerned.

A model can be prompted to review code it has generated. The guidance calls a single model's self-review "a weak control on its own." Where appropriate, it says to use a separate AI tool for review.

Rigorous human-in-the-loop or governance-in-the-loop oversight remains essential, the guidance says. In other words, it adds, qualified people must still review important decisions and approve the final code before deployment.

The guidance makes room for one AI tool to check another's code. It does not give that tool the last word. The approval stays with qualified people.

On the origin of AI-generated code, the guidance says a user can prompt the model to review and assess its own code, or use a separate AI tool to check for vulnerabilities. Many vulnerabilities can go undetected, it says. Using an AI tool for review may not find vulnerabilities the AI has intentionally inserted. An organization must have human-in-the-loop or governance-in-the-loop oversight, it says, to confirm that its code contains no malicious packages.

People with limited programming experience may not recognize complex defects in AI-generated code, the guidance says. A qualified computer programmer or reviewer should verify, correct and approve such code before deployment. One of its listed best practices is to require qualified human review of code at each step. It also says to review AI-generated code with more than one AI tool, if the organization has the ability and resources to do so.

Human Factors in Oversight

Human reviewers are essential to code review and maintenance, the guidance says. They can still make mistakes. It says organizations should account for human factors when they design their oversight processes. It describes automation bias and oversight fatigue.

Automation bias is the tendency to have more confidence in automation systems than in one's own judgment and experience. Reviewers may still accept AI suggestions even if they are incorrect, the guidance says, due to the belief that technology has a better analytical process.

Oversight fatigue can occur when reviewers become exhausted or overwhelmed by a large volume of alerts and threats, or by repetitive tasks. The amount of code generated in vibe coding, and the oversight and decision-making tasks that result, can cause it, the guidance says.

The guidance says an organization may consider various in-house mitigations, depending on the size of its operation and its project requirements. It says to ensure that employees are informed, well-trained and confident in their jobs. Organizations should also develop strategies to manage cognitive load and encourage critical analysis for anyone working in vibe coding.

A human review is a control only while the reviewer is still reading closely. How would an organization see the day that stopped?

Matching Oversight to the Risk

Vibe coding risks fall along a spectrum, the guidance says. Matching the level of oversight to the risk of the code being developed is key. A prototype or internally coded tool that does not use sensitive data carries less risk, it says, than an authentication tool that handles secrets or personal information or supports critical infrastructure.

The guidance says to weigh the expected benefits against the risks before using vibe coding. It says to increase review, testing and approval requirements as risk rises. It also says to use independent testing and qualified human reviewers based on the system's risk profile.

Among its considerations before introducing vibe coding, the guidance asks whether the intended system provides a safety-critical function. Its example is a power grid monitoring system. It says to avoid vibe coding when a security flaw would have serious consequences.

Sources

  1. Canadian Centre for Cyber Security. Managing security risks in vibe coding (ITSM.60.043). October 29, 2026 (the page prints 'This publication takes effect on October 29, 2026', 'First release: October 29, 2026' and 'Date modified: 2026-10-29'). cyber agency