A security review flags that your Python automation sets firewall rules too broadly. Your code updates rules based on user-provided inputs. Which mitigation best addresses both authorization and injection risks?

Answer

Apply strict input validation (allowlists), map inputs to predefined rule templates, and enforce RBAC/IAM checks for every operation

Explanation

Allowlisting and template mapping reduce injection/excess permission risk, while enforcing IAM/RBAC ensures only authorized changes are executed.

Last reviewed: October 2026

Reviewed by FirstInTest Editorial Team

Report an error
QuestionBack to list