Verify AI Coding Assistant Security Claims: A Guide
In this article
This guide shows you how to independently verify and reproduce security claims made by an AI coding assistant, such as "no data retention," "code is not used for training," or "vulnerabilities are automatically patched." You'll learn practical, step-by-step methods to test these claims in your own environment, so you can trust (or debunk) what the tool promises.
What You'll Need
- A test project or repository (can be a dummy project with sample code)
- Access to the AI coding assistant's settings and documentation
- Network monitoring tools (e.g., Wireshark, mitmproxy, or browser dev tools)
- A sandboxed environment (VM, container, or separate machine) to isolate tests
- Version control (git) to track changes
- Basic command-line knowledge
Step-by-Step
- Review the official documentation and privacy policy. Start by reading the assistant's security and privacy pages. Note every specific claim you want to verify. For example: "We do not store your code," "Your prompts are encrypted in transit," or "We scan for secrets before sending." Write these down.
- Set up a controlled test environment. Use a virtual machine or container that is isolated from your main network. Install the AI coding assistant there. This prevents accidental data leaks to your real projects and gives you a clean slate to observe behavior.
- Create a dummy project with sensitive-looking data. Include files with fake API keys, passwords, personal information, and proprietary code patterns. Use obviously fake data (e.g.,
sk-test-1234567890) so you can spot it if it appears anywhere unexpected. - Enable network logging. Run a packet capture tool like Wireshark on the host, or set up a proxy like mitmproxy to intercept HTTPS traffic. Configure the assistant to use the proxy if possible. You'll want to see what data is sent to which endpoints.
- Perform a baseline interaction. Ask the assistant a simple question (e.g., "Explain this function") and observe the network traffic. Note the destination IPs/domains and the payload size. Check if any file contents are sent in the request body.
- Test the "no data retention" claim. After a session, search your local filesystem for any logs, caches, or temporary files created by the assistant. On Linux/macOS, check
~/.cache,~/.config, and/tmp. On Windows, check%APPDATA%and%TEMP%. Look for any files containing your dummy data. - Test the "not used for training" claim. This is harder to verify directly. One approach: use a unique, nonsensical code snippet (e.g., a variable name like
xyzzy_plugh_42) and ask the assistant about it. Later, in a separate session (or after a few days), ask the assistant to "complete" or "suggest" code that includes that unique string. If it appears, that suggests your data influenced the model. - Test vulnerability scanning claims. If the assistant claims to detect security vulnerabilities, deliberately introduce a known vulnerability (e.g., SQL injection in a Python function) and ask the assistant to review it. See if it flags it. Then, check if it offers to fix it, and if so, review the fix manually to ensure it's actually secure.
- Test secret detection. Place a dummy secret in a file and ask the assistant to refactor or summarize the code. Then check network logs to see if the secret was sent to the server. Also, see if the assistant warns you about the secret before sending.
- Reproduce the claim in a different scenario. Repeat the above steps with different types of code (e.g., JavaScript, SQL, configuration files) and different prompt types (e.g., "fix this bug," "explain this"). Some claims may only hold under specific conditions.
- Document your findings. For each claim, note whether it was verified, partially verified, or not verified. Include evidence (screenshots, logs, timestamps). This documentation is your final deliverable.
Common Mistakes
- Testing on your main machine. You might accidentally send real code or secrets to the assistant. Always use a sandbox.
- Ignoring local logs. The assistant may store data locally even if it doesn't send it to the cloud. Check all local storage.
- Not using a unique marker. Without a unique string, you can't tell if the assistant's output came from your data or from its training data.
- Assuming HTTPS inspection is impossible. Even with encryption, you can see the destination domain and the size of the payload. Use a proxy to decrypt traffic if you have the certificate installed.
- Testing only one feature. A claim like "we don't store code" might be true for chat but false for telemetry. Test all features.
Tips
- Use a dedicated email and account for the assistant to avoid cross-contamination with your personal data.
- Check the assistant's network calls over time. Some tools send data only during updates or background tasks, not just when you prompt.
- Look for opt-out settings. Many assistants have toggles for telemetry, training, or data sharing. Test both states (on/off) to see if the claim changes.
- Use a firewall to block the assistant's domains. If the assistant still works offline, that's a good sign for privacy claims.
- Keep a checklist. Write down each claim and the test you performed. This keeps you organized.
Troubleshooting
- Can't see network traffic. If you're using a proxy, make sure the assistant respects system proxy settings. If not, use a virtual network (e.g., with VirtualBox's host-only adapter) and capture traffic on the host interface.
- The assistant refuses to work in a VM. Some tools detect virtualized environments and disable features. Try using a Docker container with a GUI, or a remote sandbox service.
- You don't see any local files. The assistant might store data in memory only, or in a database. Use a file system monitor like
inotifywait(Linux) orfs_usage(macOS) to catch writes in real time. - The unique string doesn't appear in later sessions. That doesn't necessarily mean the claim is true. The model might not reproduce it due to randomness. Try multiple times and with different unique strings.
- Vulnerability scanning seems inconsistent. Check if the assistant has different modes (e.g., "quick" vs. "deep"). Some claims only apply to certain modes.
Frequently Asked Questions
Can I legally test an AI assistant's security claims?
Yes, as long as you are testing the tool's behavior on your own data and within your own environment. You are not hacking into their systems; you are observing what the tool does with your input.
What if I find a discrepancy?
Document it thoroughly and report it to the vendor. If it's a security vulnerability, consider responsible disclosure. Also, update your own risk assessment accordingly.
Do I need to be a security expert to do this?
No, but you need to be comfortable with basic networking and file system inspection. The steps above are designed to be accessible to a developer with moderate experience.
How long does this verification take?
It depends on the number of claims and features. A basic check can take a few hours; a thorough audit might take a few days.
Can I trust the assistant's own security report?
It's a good starting point, but independent verification is always better. The whole point of this guide is to not rely solely on the vendor's word.
What if the assistant is a cloud-based service with no local install?
You can still test it by using the web interface and monitoring your browser's developer tools. You won't be able to inspect local files, but you can see network requests and responses.