-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SIEM] Fixes escape bug for filterQuery #43030
Conversation
Pinging @elastic/siem |
💚 Build Succeeded |
💚 Build Succeeded |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested it out and played with it and it fixes the issue.
If there are changes required of the downstream libs and a new PR for the downstream lib is created just tack it on optionally I would say.
💔 Build Failed |
update: @XavierM and i need to pair on this further |
💔 Build Failed |
💚 Build Succeeded |
💔 Build Failed |
💔 Build Failed |
💚 Build Succeeded |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested locally, and I agreed that match_phrase
will do the job, no need to be stubburn and use only used match
in dsl
💚 Build Succeeded |
…ete-for-distance_feature * 'master' of github.com:elastic/kibana: [SIEM] Fixes escape bug for filterQuery (elastic#43030) Export saved objects based on search criteria (elastic#44723) refactor(webhook-whitelisting): Removed unneeded schema config (elastic#44974) [APM] Make number of x ticks responsive to the plot width (elastic#44870) [ML] Single metric viewer: Fix top nav refresh behaviour. (elastic#44860)
Summary
@spong noticed a bug where when searching fields with escaped values, nothing would get returned: #42866
After playing with the query, I noticed Elasticsearch does not enjoy getting escaped values on strings.
This does not have matches:
This has matches
I fixed the bug by surrounding all strings in returned in
escapeQueryValue
with"
. This way we only need to escape"
and it eliminates the bugs we were seeing.To test:
Check the following timeline links return results:
Checklist
Use
strikethroughsto remove checklist items you don't feel are applicable to this PR.This was checked for cross-browser compatibility, including a check against IE11Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n supportDocumentation was added for features that require explanation or tutorialsThis was checked for keyboard-only and screenreader accessibilityFor maintainers
This was checked for breaking API changes and was labeled appropriatelyThis includes a feature addition or change that requires a release note and was labeled appropriately