Generate a patch for a finding, download it, or publish it as a draft pull request.
For a finding, Anitu can generate a proposed code change that addresses it. You decide what happens to it: download the patch, or publish it to your repository as a draft for review. Anitu never merges a change.
Generate a fix
Open a finding in Findings.
Select Generate code fix.
When the fix is ready, review the patch and its validation status.
Generating a fix uses your plan allowance.
Validation status
Every generated fix is checked before you see it. The status tells you how far:
Status
Meaning
Behavior checks passed
The patch applies cleanly and the application’s behavior was tested with it in place.
Structural checks passed · Behavior not tested
The patch applies cleanly and is well-formed, but no behavior test was run. Review it as you would any untested change.
Draft: confirm which status customers currently get. At the time of writing, generated fixes are structurally checked only.
Use the fix
Download patch gives you a patch file to apply yourself.
Publish draft PR opens a draft pull request on GitHub, or a draft merge request on GitLab, containing the fix. It needs write access to the repository: see Connect GitHub or Connect GitLab.
Publishing is confirmed only once the draft is open; the link appears on the fix when it is. A draft pull request is not a merge and not a deployment.
Fixes for a whole repository
From Vulnerability Management, Start code-fix review runs a fresh review aimed at producing fixes for a connected repository.
Draft: explain how a code-fix review differs from fixing findings one at a time.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Anitu Super Security","description":"Documentation for Anitu Super Security: AI-driven security review of your source code, with evidence-backed findings and code fixes.","colors":{"primary":"#7153db","light":"#9a7cff","dark":"#7153db"},"favicon":"/logo/symbol-dark.png","appearance":{"default":"system"},"footer":{"links":[{"header":"Anitu Security Labs","items":[{"label":"Security and data handling","href":"/security/data-handling"},{"label":"Troubleshooting","href":"/troubleshooting"}]}]},"seo":{"metatags":{"robots":"noindex"}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"integrations":{"telemetry":{"enabled":false}},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"hasAudioNarration":false,"customDomains":[],"gitSource":{"type":"github","owner":"local","repo":"local","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":"local","isBase":true},"buildId":"local","clientVersion":"0.0.4271"},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[],"googleFontsInlined":false,"isLoggedInCli":false,"mintExport":{}},"customCss":[]}
{"page":{"pagePath":"guides/code-fixes","slug":"/guides/code-fixes","pageMetadata":{"title":"Code fixes","description":"Generate a patch for a finding, download it, or publish it as a draft pull request.","href":"/guides/code-fixes"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Generate a patch for a finding, download it, or publish it as a draft pull request.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,li:`li`,ol:`ol`,p:`p`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{Heading,Table,Warning}=_components;if(!Heading)_missingMdxReference(`Heading`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`For a finding, Anitu can generate a proposed code change that addresses it. You decide what happens to it: download the patch, or publish it to your repository as a draft for review. Anitu never merges a change.`}),`\n`,_jsx(Heading,{level:`2`,id:`generate-a-fix`,children:`Generate a fix`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[`Open a finding in `,_jsx(_components.strong,{children:`Findings`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Select `,_jsx(_components.strong,{children:`Generate code fix`}),`.`]}),`\n`,_jsx(_components.li,{children:`When the fix is ready, review the patch and its validation status.`}),`\n`]}),`\n`,_jsx(_components.p,{children:`Generating a fix uses your plan allowance.`}),`\n`,_jsx(Heading,{level:`2`,id:`validation-status`,children:`Validation status`}),`\n`,_jsx(_components.p,{children:`Every generated fix is checked before you see it. The status tells you how far:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Status`}),_jsx(_components.th,{children:`Meaning`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Behavior checks passed`})}),_jsx(_components.td,{children:`The patch applies cleanly and the application’s behavior was tested with it in place.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.strong,{children:`Structural checks passed · Behavior not tested`})}),_jsx(_components.td,{children:`The patch applies cleanly and is well-formed, but no behavior test was run. Review it as you would any untested change.`})]})]})]}),`\n`,_jsxs(Warning,{children:[_jsx(_components.strong,{children:`Draft:`}),` confirm which status customers currently get. At the time of writing, generated fixes are structurally checked only.`]}),`\n`,_jsx(Heading,{level:`2`,id:`use-the-fix`,children:`Use the fix`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Download patch`}),` gives you a patch file to apply yourself.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Publish draft PR`}),` opens a draft pull request on GitHub, or a draft merge request on GitLab, containing the fix. It needs write access to the repository: see `,_jsx(_components.a,{href:`/guides/connect-github`,children:`Connect GitHub`}),` or `,_jsx(_components.a,{href:`/guides/connect-gitlab`,children:`Connect GitLab`}),`.`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`Publishing is confirmed only once the draft is open; the link appears on the fix when it is. A draft pull request is not a merge and not a deployment.`}),`\n`,_jsx(Heading,{level:`2`,id:`fixes-for-a-whole-repository`,children:`Fixes for a whole repository`}),`\n`,_jsxs(_components.p,{children:[`From `,_jsx(_components.strong,{children:`Vulnerability Management`}),`, `,_jsx(_components.strong,{children:`Start code-fix review`}),` runs a fresh review aimed at producing fixes for a connected repository.`]}),`\n`,_jsxs(Warning,{children:[_jsx(_components.strong,{children:`Draft:`}),` explain how a code-fix review differs from fixing findings one at a time.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Code fixes","description":"Generate a patch for a finding, download it, or publish it as a draft pull request.","href":"/guides/code-fixes"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Generate a fix","slug":"generate-a-fix","depth":2,"children":[]},{"title":"Validation status","slug":"validation-status","depth":2,"children":[]},{"title":"Use the fix","slug":"use-the-fix","depth":2,"children":[]},{"title":"Fixes for a whole repository","slug":"fixes-for-a-whole-repository","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"localhost","siteName":"Anitu Super Security","title":"Code fixes - Anitu Super Security","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"originalFileLocation":"guides/code-fixes.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Generate a patch for a finding, download it, or publish it as a draft pull request.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Anitu Super Security\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003cmeta data-mint-head name=\"robots\" content=\"noindex\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/favicons/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/favicons/favicon-32x32.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/favicons/favicon-16x16.png\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/favicons/favicon.ico\">\u003cmeta data-mint-head property=\"og:title\" content=\"Code fixes - Anitu Super Security\">\u003cmeta data-mint-head property=\"og:description\" content=\"Generate a patch for a finding, download it, or publish it as a draft pull request.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Anitu Super Security\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://local./guides/code-fixes\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Code fixes - Anitu Super Security\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Generate a patch for a finding, download it, or publish it as a draft pull request.\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/favicons/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Anitu Super Security\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#7153db\">\u003clink data-mint-head rel=\"canonical\" href=\"https://local./guides/code-fixes\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/guides/code-fixes.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Anitu Super Security\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Anitu Super Security\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/guides/code-fixes.md","siteName":"Anitu Super Security","nav":{"tabs":[{"tab":"Documentation","groups":[{"group":"Get started","pages":[{"title":"Introduction","href":""},{"title":"Quickstart","href":"/quickstart"}]},{"group":"Concepts","pages":[{"title":"How reviews work","href":"/concepts/how-reviews-work"},{"title":"Findings and evidence","href":"/concepts/findings-and-evidence"},{"title":"Glossary","href":"/concepts/glossary"}]},{"group":"Connect your code","pages":[{"title":"Connect GitHub","href":"/guides/connect-github"},{"title":"Connect GitLab","href":"/guides/connect-gitlab"}]},{"group":"Work with results","pages":[{"title":"Run a review","href":"/guides/run-a-review"},{"title":"Findings and reports","href":"/guides/findings-and-reports"},{"title":"Threat model and tests","description":"The threat model of your application, and the proof records behind tested findings.","href":"/guides/threat-model-and-tests"},{"title":"Code fixes","href":"/guides/code-fixes"},{"title":"Vulnerability management","description":"Track findings across reviews and verify whether they have been fixed.","href":"/guides/vulnerability-management"}]},{"group":"Integrations","pages":[{"title":"Slack","href":"/guides/slack"},{"title":"Agent access","href":"/guides/agent-access"},{"title":"GitHub Code Scanning","href":"/guides/github-code-scanning"}]},{"group":"Account","pages":[{"title":"Billing and usage","href":"/account/billing"},{"title":"Account and workspace","href":"/account/settings"}]},{"group":"Security","pages":[{"title":"Security and data handling","href":"/security/data-handling"}]},{"group":"Help","pages":[{"title":"Troubleshooting","href":"/troubleshooting"}]}]},{"tab":"Reference","pages":[{"title":"Reference","href":"/reference/review-statuses"}]}]},"basePath":"","title":"Code fixes - Anitu Super Security","buildId":"997e403e4737","dynamics":[],"chunks":[]}