예제 #1
0
def test_check_suricata():
    class caller(object):
        results = {
            "suricata": {
                "alerts": [{
                    "signature": "SID_TEST",
                }],
            },
        }

    s = Signature(caller)
    assert s.check_suricata_alerts(".*TEST.*")
예제 #2
0
def test_check_suricata():
    class caller(object):
        results = {
            "suricata": {
                "alerts": [{
                    "signature": "SID_TEST",
                }],
            },
        }

    s = Signature(caller)
    assert s.check_suricata_alerts(".*TEST.*")
예제 #3
0
    def report(self, obj):
        class caller(object):
            results = obj

        return Signature(caller())