forked from opensearch-project/OpenSearch
-
Notifications
You must be signed in to change notification settings - Fork 26
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
Command manager development #349
Labels
Comments
25 tasks
5 tasks
2 tasks
4 tasks
This was referenced Oct 9, 2024
AlexRuiz7
changed the title
Command manager development
Command manager development MVP
Dec 11, 2024
AlexRuiz7
changed the title
Command manager development MVP
Command manager development
Dec 11, 2024
This was referenced Dec 23, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
The Command Manager accepts command requests from Server's
Engine
andManagement API
as well as Indexer'sContent manager
.These command requests are expanded into orders and written to the orders stream. Orders have information such as:
agent.groups
command.source
Users/Services
(via Management API),Engine
(via Management API),Content manager
(directly)].command.user
command.target.id
command.target.type
group
,agent
,server
],command.action.name
restart
,update
,change_group
,apply_policy
, ...command.action.args
command.action.version
command.timeout
command.status
pending
,sent
,success
,failure
].command.result.code
command.result.message
command.result.data
command.request_id
command.order_id
Roughly speaking, the Command Manager is composed of two main parts:
For Agents to poll for orders, they must use the Comms API's
/poll_commands
endpoint. Agents must maintain this polling at all times by sending the/poll_commands
request in case it drops.The orders stream must be maintained. Only relevant orders should be preserved, while the rest should be cleaned/archived.
For example:
Test
group.Test
group. These orders are written into the orders stream./poll_commands
endpoint.Test
groups has been updated, they report back to theComms API
with the result.Comms API
updates the order status in the orders stream based on the Agent's response.Functional requirements
Plan
Spike
wazuh-indexer
packages #407MVP
Checkpoint
POST /events/stateful
endpoint when receiving commands results wazuh#25835MVP redesign
action.args
toobject
#618command.action.args
models wazuh-indexer-plugins#248The text was updated successfully, but these errors were encountered: