Mitigating AI-Based Cyberattacks