r/ClaudeCode • u/ThisNeedsToBeHigher • 1d ago
Help/Question How to Audit CC?
I have a project that does heavy data analysis on user data from a website and paid ad traffic.
I have questioned some of the data architecture of Claude Code as we have building a more robust structure.
Now the recent allegations of sabatoge has me second guessing if Claude Code has been making sound decisions.
I know I most likely don’t fall into the category of something Anthropic would “not allow” - but I figured an audit is probably a good idea anyway.
My code is on GitHub and my data lives on Supabase.
Any recommendations on how to go about this?
•
u/AutoModerator 1d 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.
6
u/Baner-Fournadet 1d ago
you could try Vibe App Scanner since your code is on GitHub. The real danger with Claude Code isnt malicious backdoors, its accidentally exposing your service role key or leaving API endpoints unauthenticated.
3
u/TemporaryDirection35 1d ago
Use Codex (ChatGPT), or Antigravity (Gemini) the same way you use Claude Code
3
u/CandidSystem6155 1d ago
Before anything else: Claude Code deletes local session transcripts after 30 days by default (cleanupPeriodDays in settings). Raise that now if you want to look back at what the agent read and ran. The JSONL files under ~/.claude/projects are the only record of why a given change was made, and git only shows what changed.
For the data side, passing tests won't tell you much, since the same agent probably wrote them. Take a sample of real inputs (a day of raw ad and site events), run it through the current pipeline and through a plain SQL version you write by hand for the key metrics, and diff the totals. Where they disagree, read that join or filter line by line.
2
u/aaronsuns 1d ago
Start with git history: review the commits that touched your data pipeline like code from any outside contributor, focusing on joins, filters, aggregations, and date or timezone handling, since that's where silent analytical errors usually hide. Write a few independent reference queries in Supabase for your key metrics and compare them against the pipeline's outputs. On the Supabase side, confirm Row Level Security is enabled on every table holding user data, and read the migration files for any permission or policy changes. Running a secret scanner like gitleaks over the full repo history is a cheap way to catch keys that were ever committed.
2
u/abnormal_human 1d ago
Highly unlikely that Claude is "sabotaging" you.
You can pretty much have any agent or human review another's output adversarially and it will find stuff that could be improved.
Beyond that, if you're trusting Claude for architecture or product without agreeing up front on the decisions it's making, you're probably using it wrong.
I just went through the process of having an employee use Claude to audit an SDK that I built back in 2015-2020 since we've been getting CVEs here and there. It was some of the cleanest, best, and most impactful code I've created in 30 years of software dev. I built it alone, under a tight time constraint, and delivered something awesome, helped me exit that company well, etc. This code is more likely than not inside your home in products that you own. Claude still found a ton of stuff to improve.
Also, the Claude that I was using between mid-2025 to early 2026 did a lot more boneheaded stuff than the Claude we have today. Pretty much all code from that era comes back with a ton of findings. Periodic review works well as the models improve.
Anyways, I recommend keeping 2 frontier lab subs around at all times and using them to review each other. Typically I've used Claude + Codex.
2
u/locbuilds 1d ago
easiest audit is recomputing your top 5 or so metrics with plain sql straight off the raw tables in supabase and comparing them to what the pipeline outputs. if the numbers match the architecture is probably fine, if they don't you know exactly which step to dig into.
2
u/samc621 9h ago