-
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
[Security Solution] Filter editing causing Error: e.getName is not a function
exception
#164265
Comments
Pinging @elastic/security-solution (Team: SecuritySolution) |
Pinging @elastic/security-detections-response (Team:Detections and Resp) |
@kqualters-elastic suggested to fix this with the next steps:
|
It would be great if we can fix this for 8.10 and 8.9.2 :) |
I think this is going to be a bigger fix than it may seem, as in, it will touch a lot of files, We may need to discuss any risk in backporting. |
Have not been able to reproduce this so far. Neither on cloud nor locally. @aarju are you comfortable with providing an exported version of the rule? And a few more details that could be heplful.. Is that a data stream the rule is querying? Is this a rule that was created fresh in 8.9.0 or was the rule pre-existing prior to 8.9.0? |
Just clarifying - I agree the code referenced is not safe, but I would feel more comfortable knowing it was fixed correctly if I was able to reproduce the bug. |
Hey @dhurley14 ! Was this addressed by #166318 ? |
@yctercero I believe so! Been a while since I've seen this but I looked at the code and it seems the typeguard here should prevent the error from occurring: https://github.com/elastic/kibana/pull/166318/files#diff-e6442176bd5f8e996ee191a1b34c716e43c58ff4644adfcfca6dc98a386cb8caR41-R43 |
Describe the bug:
Filter editing on rule's editing page can cause an exception:
After some investigation, we found that this happens here because
indexPattern
does not have agetName
method.The root cause is the incorrect type cast
indexPatterns as DataView[]
(fromDataViewBase
toDataView
) that we do in several places around security solution code: 1, 2, 3, 4.More details in slack https://elastic.slack.com/archives/CN7AD3605/p1692257845887359
Screenshots (if relevant):
20230817-0735-32.6812978.mp4
The text was updated successfully, but these errors were encountered: