Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[8.16] [Security Solution] Fix an error with nested fields being trea…
…ted as keyword (elastic#201473) (elastic#201482) # Backport This will backport the following commits from `main` to `8.16`: - [[Security Solution] Fix an error with nested fields being treated as keyword (elastic#201473)](elastic#201473) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Kevin Qualters","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-23T00:11:12Z","message":"[Security Solution] Fix an error with nested fields being treated as keyword (elastic#201473)\n\n## Summary\r\nWhen formatting elasticsearch responses for the frontend, the timelines\r\nsearch strategies will treat unmapped fields as type: keyword. If the\r\nunderlying field is actually an object, but is seen as a string in the\r\ncode, this for (key in source) loop will fail, as it's trying to loop\r\nover a string. Fix below should have minimal effect as the data is\r\naccessible at the further nested keys.\r\n\r\n\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios","sha":"c6cb05996188ec7613d38f10de57dade356d12f7","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","Team:Threat Hunting:Investigations","backport:prev-major"],"title":"[Security Solution] Fix an error with nested fields being treated as keyword","number":201473,"url":"https://github.com/elastic/kibana/pull/201473","mergeCommit":{"message":"[Security Solution] Fix an error with nested fields being treated as keyword (elastic#201473)\n\n## Summary\r\nWhen formatting elasticsearch responses for the frontend, the timelines\r\nsearch strategies will treat unmapped fields as type: keyword. If the\r\nunderlying field is actually an object, but is seen as a string in the\r\ncode, this for (key in source) loop will fail, as it's trying to loop\r\nover a string. Fix below should have minimal effect as the data is\r\naccessible at the further nested keys.\r\n\r\n\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios","sha":"c6cb05996188ec7613d38f10de57dade356d12f7"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/201473","number":201473,"mergeCommit":{"message":"[Security Solution] Fix an error with nested fields being treated as keyword (elastic#201473)\n\n## Summary\r\nWhen formatting elasticsearch responses for the frontend, the timelines\r\nsearch strategies will treat unmapped fields as type: keyword. If the\r\nunderlying field is actually an object, but is seen as a string in the\r\ncode, this for (key in source) loop will fail, as it's trying to loop\r\nover a string. Fix below should have minimal effect as the data is\r\naccessible at the further nested keys.\r\n\r\n\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios","sha":"c6cb05996188ec7613d38f10de57dade356d12f7"}}]}] BACKPORT--> Co-authored-by: Kevin Qualters <[email protected]>
- Loading branch information