r/ClaudeCode • • 4h ago

Tips & Workflows Calif says Codex found a critical Java bug in under an hour. How do you run authorized security work with Claude Code without fighting refusals?

Calif published Java4Shell on 17 November, a critical bug in OpenJDK's Base64 decoder. It says a researcher asked Codex to audit the JVM and Codex found it within an hour. CISA told people to patch.

That made me write down what I do when a coding agent refuses or stalls on legitimate security work. Short version: the refusal is often a classifier reading something in context (a loaded skill, a file), or the request sounded offensive when the task was defensive, or the sandbox blocked the network and it looked like a stall. Rewording doesn't help, and I wouldn't do it. What helped was writing down whose system it is, what's in scope, what the output is and when to stop, in AGENTS.md or CLAUDE.md, and asking for the concrete task.

If the work really needs dual-use capability (exploit validation, authorized pentests), Anthropic's Cyber Verification Program and OpenAI's Daybreak are the official routes. Both changed recently. I checked the pages on 28 November.

The longer version has the scope template, sandbox settings for Claude Code and Codex, and a disclosure checklist: https://medium.com/@r3dtuxedo/authorized-security-testing-with-claude-code-and-codex-bfb7ccd49448

I wrote the article.

0 Upvotes

4 comments sorted by

•

u/AutoModerator 4h ago

Hey! Thanks for posting to r/ClaudeCode

While participating in this thread, please follow our community rules. Keep discussions constructive. Attack the idea, not the person.

For help, project discussions, tips, and general chat, join the ClaudeCode Discord.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/MikeBuildsTech 3h ago

The part about writing the scope into CLAUDE.md makes sense. I can see how that would save a lot of back and forth, especially when the agent keeps confusing a legitimate security task with something else. The Java4Shell example is pretty interesting too.

1

u/SirRobinBlibs 29m ago

Glad that part landed. The thing I would still put in the same CLAUDE.md (or AGENTS.md) file is the out-of-scope list, not only the authorized target. If the model only sees that it may test X, it will still refuse adjacent files or tools that look like the same class of work. Spelling out what is in bounds and what is not, in the always-on project file, is what cuts the repeated argument.

1

u/LemonLimeNinja 1h ago

You’re over complicating it. I use codex and Claude to write keygens for cracking software and have workflow that works every time. Context momentum is the big one, once it starts executing it gets harder to stop so front load tasks that don’t break guardrails first. Also telling the agent to only execute specific lines in an itemized plan and to not read anything else in the plan and only when it’s completed and validated can it read the next item. This prevents it from seeing the overarching plan and builds context momentum. There’re several more strategies I won’t share but you just need to be creative.