Skip to content

fix(plugins/cloudtrail): support for assumedrole in cloudtrail#1247

Merged
poiana merged 2 commits intofalcosecurity:mainfrom
fcracker79:fix/mirko/cloudtrail-user-in-assumed-role
Mar 11, 2026
Merged

fix(plugins/cloudtrail): support for assumedrole in cloudtrail#1247
poiana merged 2 commits intofalcosecurity:mainfrom
fcracker79:fix/mirko/cloudtrail-user-in-assumed-role

Conversation

@fcracker79
Copy link
Contributor

What type of PR is this?

/kind bug
/area plugins

What this PR does / why we need it:
The PR ensures that the ct.user field is correctly populated in case of assumed role.
It does the following attempts:

  1. Takes the userIdentity.arn field and extracts the session name
  2. If not valid/missing, takes the userIdentity.principalId and takes the role session name
  3. If not valid/missing, takes the original userIdentity.sessionContext.sessionIssuer.userName field

@poiana
Copy link
Contributor

poiana commented Mar 10, 2026

Welcome @fcracker79! It looks like this is your first PR to falcosecurity/plugins 🎉

@poiana poiana added the size/M label Mar 10, 2026
@fcracker79 fcracker79 force-pushed the fix/mirko/cloudtrail-user-in-assumed-role branch from 6ad9a7e to 688108d Compare March 10, 2026 17:41
@poiana
Copy link
Contributor

poiana commented Mar 11, 2026

@legobrick: changing LGTM is restricted to collaborators

Details

In response to this:

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Copy link
Contributor

@ekoops ekoops left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, thank you for this contribution! 😄
This introduces a change in the field, behaviour, so we should document it in

{Type: "string", Name: "ct.user", Display: "User Name", Desc: "the user of the cloudtrail event (userIdentity.userName in the json).", Properties: []string{"conversation"}},
.
Could you please modify the field description and re-generate the couldtrail plugin's README.md accordingly?

@poiana poiana added size/L and removed size/M labels Mar 11, 2026
@fcracker79 fcracker79 requested a review from ekoops March 11, 2026 09:15
… back to the identity userName

Signed-off-by: Mirko Bonasorte <mirko.bonasorte@sysdig.com>
… back to the identity userName

Signed-off-by: Mirko Bonasorte <mirko.bonasorte@sysdig.com>
@fcracker79 fcracker79 force-pushed the fix/mirko/cloudtrail-user-in-assumed-role branch from cb03793 to eaf1072 Compare March 11, 2026 10:13
@ekoops ekoops changed the title Support for assumedrole in cloudtrail fix(plugins/cloudtrail): support for assumedrole in cloudtrail Mar 11, 2026
Copy link
Contributor

@ekoops ekoops left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! 😄
/approve

@poiana poiana added the lgtm label Mar 11, 2026
@poiana
Copy link
Contributor

poiana commented Mar 11, 2026

LGTM label has been added.

DetailsGit tree hash: 3ec49c510cfb57717d7f7cd9e5ffe5b001908c81

@poiana
Copy link
Contributor

poiana commented Mar 11, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ekoops, fcracker79, legobrick

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@poiana poiana merged commit bfee0e3 into falcosecurity:main Mar 11, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants