Add a switch in mainWindow to control the security statement.