コード例 #1
0
    def test_declines_unrecognized_alert(self):
        msg = _ssh_sensitive_host_alert()

        # Without the `session` tag, the alert should not fire.
        msg["_source"]["classname"] = "test"

        result = bot.try_make_outbound(msg, self.mock_config, "")

        assert result is None
コード例 #2
0
    def test_recognizes_ssh_access_releng(self):
        msg = _ssh_access_releng_alert()

        result = bot.try_make_outbound(msg, self.mock_config, "")

        assert result is not None
コード例 #3
0
    def test_recognizes_duo_bypass_codes_used(self):
        msg = _duo_bypass_code_used_alert()

        result = bot.try_make_outbound(msg, self.mock_config, "")

        assert result is not None
コード例 #4
0
    def test_recognizes_ssh_sensitive_host(self):
        msg = _ssh_sensitive_host_alert()

        result = bot.try_make_outbound(msg, self.mock_config, "")

        assert result is not None