IncapWhitelistCompliance
Get all sites from Incapsula. For each site, the script, through a ssh server (one that should NOT be in the allow list), make sure the site is compliant ( allow list is being enforced ). If not, a warning mail will be sent to the domain owner.
python · Imperva Incapsula
Details
| ID | IncapWhitelistCompliance |
|---|---|
| Language | python |
| From Version | 5.0.0 |
| Docker Image | demisto/python3:3.12.13.10116658 |
| Tags | Incapsula |
README
Get all sites from Incapsula.
For each site, the script, through a ssh server (one that should NOT be in the allow list), make sure the site is compliant ( allow list is being enforced ).
If not, a warning mail will be sent to the domain owner.
Script Data
| Name | Description |
|---|---|
| Script Type | python3 |
| Tags | Incapsula |
| Cortex XSOAR Version | 5.0.0 |
Dependencies
This script uses the following commands and scripts.
- incap-list-sites
- RemoteExec
- SendEmail
- incap-get-domain-approver-email
Inputs
| Argument Name | Description |
|---|---|
| SSHValidationServer | Name of the non-allow list SSH server instance |
Outputs
There are no outputs for this script.
import IncapWhitelistCompliance import pytest @pytest.mark.parametrize("severity, expected_result", [(0, None), (4, "mail send successfully")]) def test_escalation(severity, expected_result, mocker): owner_mock_mail = "mail" mock_url = "url" mocker.patch.object(IncapWhitelistCompliance, "sendMail", return_value="mail send successfully") res = IncapWhitelistCompliance.escalation(mock_url, severity, owner_mock_mail) assert res == expected_result