In this article, I show how you can use the "X as Code" approach to test the system security as you do it to test the application security.