[EDR Workflows] Add Microsoft Defender for Endpoint Custom scripts and runscript subactions#223085
Conversation
|
/ci |
|
Pinging @elastic/security-defend-workflows (Team:Defend Workflows) |
|
cc: @pmuellr could you take a look ? :) Thanks! |
|
Question from a UX perspective: For the Crodwstrike |
@natasha-moore-elastic , good observation: we decided to resemble external EDR's arguments, so the customers could potentially just copy paste the command from the other EDR to Elastic. |
pmuellr
left a comment
There was a problem hiding this comment.
LGTM, left a comment about a response type
|
|
||
| export const GetActionResultsParamsSchema = schema.object({ | ||
| id: schema.maybe( | ||
| schema.oneOf([ |
There was a problem hiding this comment.
From a user point-of-view, having the result be string | string[] seems unwieldy to deal with. Can we just make this string[]?
There was a problem hiding this comment.
Thanks! Good idea, I'll adjust it as agreed - in a following PR.
|
Starting backport for target branches: 8.19 https://github.com/elastic/kibana/actions/runs/15566648724 |
…d runscript subactions (elastic#223085) (cherry picked from commit 17d5854)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…ipts and runscript subactions (#223085) (#223276) # Backport This will backport the following commits from `main` to `8.19`: - [[EDR Workflows] Add Microsoft Defender for Endpoint Custom scripts and runscript subactions (#223085)](#223085) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Tomasz Ciecierski","email":"tomasz.ciecierski@elastic.co"},"sourceCommit":{"committedDate":"2025-06-10T17:51:30Z","message":"[EDR Workflows] Add Microsoft Defender for Endpoint Custom scripts and runscript subactions (#223085)","sha":"17d58545d96bf62601f53fef33fd48c10f933b21","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:Defend Workflows","backport:version","v9.1.0","v8.19.0"],"title":"[EDR Workflows] Add Microsoft Defender for Endpoint Custom scripts and runscript subactions","number":223085,"url":"https://github.com/elastic/kibana/pull/223085","mergeCommit":{"message":"[EDR Workflows] Add Microsoft Defender for Endpoint Custom scripts and runscript subactions (#223085)","sha":"17d58545d96bf62601f53fef33fd48c10f933b21"}},"sourceBranch":"main","suggestedTargetBranches":["8.19"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/223085","number":223085,"mergeCommit":{"message":"[EDR Workflows] Add Microsoft Defender for Endpoint Custom scripts and runscript subactions (#223085)","sha":"17d58545d96bf62601f53fef33fd48c10f933b21"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Tomasz Ciecierski <tomasz.ciecierski@elastic.co>
…d runscript subactions (elastic#223085)
…d runscript subactions (elastic#223085)
Overview
This PR adds support for custom script execution functionality in the Microsoft Defender Endpoint (MDE) connector, including the ability to run scripts and retrieve custom script libraries.
Connector Integration (
microsoft_defender_endpoint.ts)runScript()method: Executes live response scripts via Microsoft Defender API/api/machines/{id}/runliveresponseendpointRunScriptcommand type withScriptNameandArgsparameters--noargsfallbackgetLibraryFiles()method: Retrieves custom script library/api/libraryfilesendpointfileName,description,creationTimeRUN_SCRIPTsub-action withRunScriptParamsSchemavalidationGET_LIBRARY_FILESsub-action with empty params schemalibraryFilesendpoint to connector URLs