# AI Security ### Mitigation Strategies ## Overview ### About * Defensive principles for AI systems * Securing AI beyond basic input filtering Notes: Not all is doom and gloom. Now we will discuss mitigation strategies for prompt injection and jailbreak attacks. Since these attacks exploit the fundamental nature of how AI processes language, we must adopt a layered defense approach. ## Defensive techniques ### Input and Output Validation * Input filtering is a good layer of mitigation * It should never be considered adequate protection alone * Monitor for output validation failures Notes: While input filtering alone should never be considered adequate protection because attackers constantly find bypasses, it is still a necessary layer of defense. Additionally, developers must actively monitor for output validation failures, which are strong indicators of probing and exploitation. ### Principle of Least Privilege * Risk accumulates as attack surface increases * AI agents should be heavily isolated * Plugins must have the minimum permissions required to function Notes: To mitigate the impact of a compromised agent, developers must apply the principle of least privilege to AI plugins. Risk accumulates as the attack surface increases; if a service or integration is not essential, it shouldn't be exposed. ### Human-in-the-Loop * Automated decision making is dangerous * Require trusted human approval for sensitive actions Notes: For sensitive functionality, relying purely on the system's automated decisions is dangerous. Similar to how traditional applications should require re-authentication, such as a PIN, before executing highly sensitive actions, AI systems must require explicit human approval before executing destructive or sensitive plugin actions. ## Epilogue ### Summary * Input filtering is not sufficient * Output validation failures indicate active probing * Restrict agents using the principle of least privilege * Implement human-in-the-loop architectures for critical actions Notes: To summarize, securing AI systems against injection and jailbreaking requires assuming that input filters will eventually fail. By monitoring outputs, enforcing strict least privilege for agent plugins, and implementing human-in-the-loop approvals, organizations can build robust and resilient AI integrations. ### Let's hack!