Is it possible to use regular expression in filter ?
See original GitHub issuehi all,
I try to using regular expression in my rule as below, it’s will alert when id is 1.1 and msg contain type.24:6
filter:
- and:
- term:
id: "1.1"
- query:
query_string:
query: "msg:\"Type.[0-9]{1,2}\\:6\""
but it’s cannot alert ,Is it possible to use regular expression in filter ?
Thanks by advance
Issue Analytics
- State:
- Created 7 years ago
- Comments:24 (11 by maintainers)
Top Results From Across the Web
Use regular expressions in filters and automated rules
Start creating a filter or automated rule. · Select a setting or metric from the + Attribute or metric list. · Select the...
Read more >Regex Filter transform - IBM
The Regex Filter transform filters messages in the data stream according to a regular expression (regex) pattern, which you can define.
Read more >4.1 Creating Filters with Regular Expressions
Where available, include and exclude filters can be used independently or together to give you a great deal of control in looking for...
Read more >How does the Regular Expression (RegEx) filter work?
Our RegEx filter allows you to extract text data from your PDF documents based on regular expression.
Read more >How to Filter Queries Using Regular Expressions
Regular Expressions are special characters that help search data and match complex patterns using placeholder characters called operators, such ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@abhishekjiitr What about using complex queries like this one below:
I am getting the same error ‘found unknown escape character’.
Edit: Each of reserved characters should be escaped. So the last line should look like this:
Is
field
analyzed? If so, you’ll definitely need field.raw or field.keyword. I would have tried option # 1 so if that doesn’t work I can’t help you.