3.6.3. Trustworthy AI: Hallucinations, Bias, Explainability, and Ethics
💡 First Principle: An AI system can be wrong, unfair, or opaque with no attacker involved — and in security terms those are integrity, compliance, and accountability failures. A model produces the statistically likely answer, not a verified one, so its output must be treated as untrusted until it is validated, exactly like user input.
| Risk | What goes wrong | Why it is a security or business risk |
|---|---|---|
| Hallucinations | The model produces confident, plausible, but fabricated output — invented citations, nonexistent CVEs or commands, made-up software packages | Integrity failure: decisions and configurations built on false output. Attackers have even registered package names that AI coding assistants invent, waiting for developers to install them |
| Bias | Skewed or unrepresentative training data produces systematically unfair or inaccurate results for some groups or situations | Discrimination and regulatory exposure (hiring, lending), reputational harm, and blind spots — an anomaly model trained on one region's traffic misjudges another's |
| Explainability (lack of) | No one can tell why the model produced its output | Decisions can't be audited, justified to regulators, or investigated after an incident; poisoning and bias stay hidden |
| Ethical considerations | AI used without fairness, transparency, consent, or accountability | Legal and reputational risk: undisclosed AI use, training on data without rights or consent, no human accountable for automated decisions, misuse such as deepfakes |
Mitigations at Security+ depth. No single control solves AI risk, so layer them:
- Input filtering and validation — screen prompts and retrieved content for injection patterns, limit input size, and keep untrusted content clearly separated from instructions. It reduces prompt injection but cannot eliminate it, because attackers rephrase.
- Output filtering and handling — inspect responses with DLP and content filters, encode output before rendering it, and never pass it unvalidated to a shell, database, or
eval(). - Least privilege for AI agents — give each agent its own scoped identity, read-only access where possible, an allowlist of tools, and retrieval that uses the requesting user's permissions.
- Human in the loop — require human approval for high-impact actions (payments, account changes, deletions, external emails) and human review of AI output used in consequential decisions.
- Data governance — classify and approve the data used for training and retrieval, track its provenance, restrict who can change it, and publish an AI acceptable use policy listing approved tools.
- AI red teaming and monitoring — test models with adversarial prompts, jailbreaks, and poisoned inputs before and after deployment, and log prompts, responses, and tool calls so misuse can be detected and investigated.
The NIST AI RMF organizes this work into four functions — Govern, Map, Measure, Manage — and describes trustworthy AI as valid and reliable, safe, secure and resilient, accountable and transparent, explainable and interpretable, privacy-enhanced, and fair with harmful bias managed. Notice how the exam's bullets (bias, explainability, privacy, ethics) map directly onto those characteristics.
⚠️ Exam Trap: A hallucination is not an attack — no adversary is needed — yet it is still a security issue because it is an integrity failure. If a scenario says an AI tool confidently produced a fake reference or a nonexistent setting and someone acted on it, the risk is hallucination and the mitigation is human verification of output, not input filtering.