I think it even might be possible to route the isolated fix somewhere to automate that last step. Maybe invert the diff and pass it through automated code review for example, see the reasoning when the llm flags the change as dangerous.
It will be pretty obvious what are security issues in that case - i.e. all the code changes that don't have corresponding tests.