AWS Bedrock Agent or Action Group Manipulation
Description
Detects modification of deployed Amazon Bedrock agents and their action groups, collaborators, or aliases via the Bedrock Agent control plane. Adversaries with access to an AWS account can tamper with an existing, trusted agent by altering its instructions (UpdateAgent), adding or changing action groups that wire the agent to Lambda functions or APIs (CreateAgentActionGroup, UpdateAgentActionGroup), attaching or modifying collaborators (AssociateAgentCollaborator, UpdateAgentCollaborator), or repointing an alias to a tampered version (CreateAgentAlias, UpdateAgentAlias). A PrepareAgent call is required to make a tampered configuration live. By implanting malicious behavior into an agent that legitimate users continue to invoke, an attacker can maintain durable access through a trusted component. Creation of brand-new agents (CreateAgent) is intentionally excluded as lower-signal activity.
Query · kuery
data_stream.dataset: "aws.cloudtrail" and
event.provider: "bedrock.amazonaws.com" and
event.action: (
"UpdateAgent" or
"CreateAgentActionGroup" or
"UpdateAgentActionGroup" or
"AssociateAgentCollaborator" or
"UpdateAgentCollaborator" or
"CreateAgentAlias" or
"UpdateAgentAlias" or
"PrepareAgent"
) and
event.outcome: "success"
Investigation fields
Pivot points the source recommends for triage.
@timestampuser.nameuser_agent.originalsource.ipaws.cloudtrail.user_identity.arnaws.cloudtrail.user_identity.typeaws.cloudtrail.user_identity.access_key_idaws.cloudtrail.user_identity.invoked_byevent.actionevent.providerevent.outcomecloud.account.idcloud.regionaws.cloudtrail.request_parametersaws.cloudtrail.response_elements
Known false positives
- Bedrock agent and action group changes are common during legitimate development, prompt tuning, and CI/CD deployments. Verify whether the user identity, user agent, and/or source IP should be modifying agents in your environment, and confirm a corresponding change request exists. Automation roles (IaC pipelines, deployment tooling) may routinely call these APIs and can be exempted from the rule if they generate false positives.
Analyst notes
Investigating AWS Bedrock Agent or Action Group Manipulation
Amazon Bedrock agents orchestrate foundation models with developer-defined instructions and action groups that connect
the agent to Lambda functions or APIs. Because end users and applications repeatedly invoke deployed agents, an attacker
who modifies an existing agent's instructions, action groups, collaborators, or alias can implant durable malicious
behavior into a trusted component without deploying any new infrastructure. The PrepareAgent call makes a tampered
configuration live, and updating an alias repoints traffic to the tampered version.
This rule identifies changes to existing Bedrock agents while intentionally excluding CreateAgent, which represents
net-new resource creation rather than tampering with established, trusted agents.
Possible investigation steps
- Identify the actor and context
- Review
aws.cloudtrail.user_identity.arn,aws.cloudtrail.user_identity.type, andaws.cloudtrail.user_identity.access_key_idto determine who made the change. - Inspect
source.ip,user_agent.original, andaws.cloudtrail.user_identity.invoked_byto establish whether the change came from an interactive session, automation, or an unfamiliar location. - Confirm whether a corresponding change request or deployment exists for the affected agent.
- Examine the change
- Review
aws.cloudtrail.request_parametersandaws.cloudtrail.flattened.request_parametersfor the targeted agent ID, action group definition, Lambda ARN, collaborator, or alias routing configuration. - For
UpdateAgent, inspect the modified instruction text for prompt-injection or data-exfiltration intent. - For action group changes, validate the referenced Lambda function or API schema ownership and intent.
- For alias changes, confirm which agent version the alias now points to.
- Correlate activity
- Look for a
PrepareAgentcall following configuration changes, which indicates the tampered config was made live. - Search for surrounding IAM, Lambda, or STS activity from the same identity that could indicate broader compromise.
False positive analysis
- Planned development and tuning: Legitimate developers regularly update agent instructions and action groups. Validate against change tickets and known engineering activity.
- Automation: IaC pipelines and deployment tooling may call these APIs on every release. Exempt known automation roles if they cause recurring false positives.
Response and remediation
- If the change is unauthorized, revert the agent, action group, collaborator, and alias to a known-good version and
re-run
PrepareAgentto restore trusted behavior. - Disable or rotate the credentials identified in
aws.cloudtrail.user_identity.access_key_idif compromise is suspected. - Review the affected agent's action group Lambda functions and APIs for malicious code or data flows.
- Restrict
bedrock:UpdateAgent,bedrock:*AgentActionGroup,bedrock:*AgentCollaborator,bedrock:*AgentAlias, andbedrock:PrepareAgentpermissions to a small set of administrative roles.