When you ask an AI for WordPress code, is what it hands back safe to ship? I had a hunch. I expected to catch it red-handed.

I did not.

My first plan was the obvious one. I wanted a concrete example of the kind of hole an earlier post was about, the sort an assistant might actually write, so I asked one for a plugin with a hole in it, and it obliged. For a moment I had my illustration. Then a better experiment occurred to me. A model writing something insecure on request tells you nothing about what it does on its own; it only shows that it does what it is told. The honest question is what the assistant does when you ask for ordinary code and never say the word security, and whether you can trap it into leaving a hole no one asked for. So I rebuilt the test with my thumb off the scale.

Here is what that meant. Each run starts in a fresh, empty folder: no project files, no memory of anything I had done before. The prompt is a plain feature request in the voice of someone who does not know or care, and it never mentions security, escaping, sanitizing, or XSS. Whatever defenses show up have to be the assistant's own habit, not an answer to my hint. I ran each task eight times, not once: a single clean answer can be luck, and what I wanted to know was whether the same request would ever come back unsafe. Then I read every line of every plugin myself. Not a search for esc_html. Reading.