# Correlation analysis in elasticsearch

**URL:** <https://discuss.elastic.co/t/correlation-analysis-in-elasticsearch/270346>\
**Category:** Elasticsearch\
**Created:** [April 16, 2021, 8:14am UTC](https://discuss.elastic.co/t/correlation-analysis-in-elasticsearch/270346 "2021-04-16T08:14:22Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![111387](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/111387/32/75408_2.png) [@111387](https://discuss.elastic.co/u/111387)\
**Post date:** [April 16, 2021, 8:14am UTC](https://discuss.elastic.co/t/correlation-analysis-in-elasticsearch/270346/1 "2021-04-16T08:14:22Z")

</div>

I am collecting suricata events with elasticsearch.  
I want to create an alert through correlation analysis for suricata event.

For example, when the following events are saved

```auto
{
    rule.event: "event a"
    src.ip: "10.0.0.1"
    dst.ip: "10.0.0.2"
},
{
    rule.event: "event b"
    src.ip: "10.0.0.2"
    dst.ip: "10.0.0.1"
}

```

I want to create an alert by combining events with the same src.ip and dst.ip.  
Are these queries possible with DQL?

I want to make correlation rules for logs of devices other than suricata.  
Are all of these operations possible with query in elasticsearch?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [May 14, 2021, 8:15am UTC](https://discuss.elastic.co/t/correlation-analysis-in-elasticsearch/270346/2 "2021-05-14T08:15:02Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
