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
[Auditbeat] Auditd: Change user fields to ECS #10456
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I find it confusing to have the
effective
&saved
fields defined here, and theaudit
&filesystem
fields defined only in the auditd module. Especially since they're defined mixed in the ECSuser
field set.I think it would make most sense to have them grouped together here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would assume Auditbeat's FIM has events with
ouid
andogid
(file owner). I think it would make sense to define them here as (and adjust FIM to use them ;-) ).I've seen them pop up in the Filebeat auditd module, so you can pilfer the definitions from there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To clarify about FIM above: I would define the fields in this PR. Addressing whether FIM emits owner IDs in these fields can be addressed as a separate PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 I'll make the change
I think we have a few options. But regardless, I don't think we should address it here in this PR.
The FIM file metadata has a
uid
,gid
,owner
, andgroup
. This is also what is currently in ECS.Our options for moving the fields:
user.*
:user.id
,user.name
,user.group.id
,user.group.name
- no new definitions required, easy field names, but problematic if we ever have another user object (e.g. the user that modified the file)user.owner.*
:user.owner.id
,user.owner.name
,user.owner.group.id
,user.owner.group.name
- more future proof, somewhat longer field namesfile.user.*
:file.user.owner.id
,file.user.owner.name
,file.user.owner.group.id
,file.user.owner.group.name
file.owner.*
:file.owner.id
,file.owner.name
,file.owner.group.id
,file.owner.group.name
The benefit the last two options under
file
have is that it would allow us to keep thefile
object of the FIM module and theauditd.paths
object (containing multiple files) of the Auditd module to share the same fields for users. They're a bit disparate at the moment, with FIM usinguid/gid
and Auditd usingouid/ogid
for the same data.Again, I think we should address this whole thing in another PR, including any field definitions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for moving the fields defs :-)
I agree the owner stuff is to be addressed in another PR, if we address it.
The discrepancy in representing users in
file.*
in ECS saddens me a bit, haha. This one slipped by. But I think we should leave it as is and concentrate on polishing everything that's already in flight, for FF. I don't think we should open this can of worms as well.