Safeguard
AI Security•

Should you scan training and eval data for secrets and personal data?

Yes. Scan datasets before training, fine-tuning or evals for keys, personal data and poisoned records, because models can repeat what they were given.

Safeguard Security Team
3 min read

Yes, scan training, fine-tuning, and evaluation data for secrets and personal data before use. Anything in a dataset can end up in a model, a prompt log, or a test report. Scanning is cheap compared with retraining, and it gives you a record to show customers who ask how data is handled.

Why datasets are a risk surface

OWASP lists sensitive information disclosure as LLM02:2025 and data and model poisoning as LLM04:2025. Both start with the data. Keys pasted into support tickets, personal details in chat logs, and customer files used as eval cases all travel into places they were never meant to go: fine-tuned weights, shared notebooks, vendor platforms.

What to look for

FindingWhy it mattersTypical action
API keys, tokens, passwordsCan be repeated by a model or exposed in logsRemove and rotate the key
Personal dataPrivacy law and contract dutiesRemove, mask, or confirm lawful basis
Customer confidential contentContract limits on useExclude unless the contract allows
Duplicated or odd recordsPossible poisoning or quality issueReview and quarantine
Licensed or restricted contentUsage termsCheck before inclusion

A workable process

  1. Inventory datasets. Record source, owner, and purpose for each one.
  2. Scan on ingestion. Run secrets detection and a personal data pattern check before data lands in the training bucket.
  3. Rotate, do not just delete. A key found in data should be treated as exposed. Revoke it.
  4. Keep customer data out of shared evals unless the contract and your retention terms allow it. Prefer synthetic or masked cases.
  5. Version datasets so you can show which data a given model saw.
  6. Re-scan when data is refreshed.

Be careful with eval reports

Eval outputs often contain raw prompts and answers. Treat the report as data with the same sensitivity as the inputs, and restrict who can open it.

Tie it to your commitments

If your policy says you do not train on customer data, the scan and the dataset inventory are your evidence. Answers in security questionnaires should match what the pipeline actually enforces.

A short note on Safeguard

Safeguard offers secrets detection and compliance and evidence automation, which can hold the records described above. Try a free scan at gold.safeguard.sh/scan.

Quick check

Is deleting a leaked key from the dataset enough?

No. Assume it was copied. Revoke and replace it.

Can we use customer data for evals?

Only if your contract allows it. Masked or synthetic data avoids the question.

Sources

Last reviewed: 19 October 2026.

Never miss an update

Weekly insights on software supply chain security, delivered to your inbox.

Self-healing security runs on Safeguard.

Your first fix PR is minutes away.

No sales call required, even your agent can complete the purchase over MCP.