-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Description
Operation created via API always uses "ad-hoc" adversary even when valid adversary_id is provided
Description
When creating an operation via the API, even though I provide a valid adversary_id
in the payload, the operation is always created with the "ad-hoc"
adversary (an empty profile). As a result, the operation does not run as expected.
Steps followed
Steps to reproduce the behavior:
- Created an adversary with abilities assigned (verified in the Caldera UI).
- Used the API to create an operation with a payload like:
{ "name": "react", "adversary_id": "426382f6-9811-4751-be04-2642f5f3db8c", "planner": { "id": "aaa7c857-37a0-4c4a-85f7-4e9f7f30e31a" }, "agent_group": ["reharu"] }
- The operation is created, but the response shows:
{ "adversary": { "adversary_id": "ad-hoc", "name": "ad-hoc", "description": "an empty adversary profile", "atomic_ordering": [], }}
- The operation does not run as expected.
Expected behavior
The operation should use the adversary specified by adversary_id and run with its assigned abilities.
Environment:
Caldera version: 5.3.0
API endpoint: /api/v2/operations
How I'm calling the API: using fetch
Additional context
Double checked:
The adversary exists and has abilities assigned.
The same adversary works when creating operations via the Caldera web UI.
No errors are returned in the API response.
Screenshots / Logs
Operation stops instantly without running: