Skip to content

Commit

Permalink
tetragon:username: use login name instead of display name
Browse files Browse the repository at this point in the history
[ OSS main 96e5028 fix ]

Main uses cache where 1.1 does not use a cache.

Signed-off-by: Djalal Harouni <tixxdz@gmail.com>
  • Loading branch information
tixxdz committed Jun 19, 2024
1 parent 818168d commit 19c1ba9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/sensors/exec/exec.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ func msgToExecveAccountUnix(m *exec.MsgExecveEventUnix) {
if ns.Mnt.IsHost && ns.User.IsHost {
// use Golang user.LookupId() as we want to only parse /etc/passwd for now
if userInfo, err := user.LookupId(strconv.FormatUint(uint64(m.Unix.Process.UID), 10)); err == nil {
m.Unix.Process.User.Name = userInfo.Name
m.Unix.Process.User.Name = userInfo.Username
}
}
}
Expand Down

0 comments on commit 19c1ba9

Please sign in to comment.