Skip to content

Commit

Permalink
Debris removed after functionreturn
Browse files Browse the repository at this point in the history
Signed-off-by: GLVS Kiriti <glvskiriti2003369@gmail.com>
  • Loading branch information
GLVSKiriti authored and poiana committed Apr 8, 2024
1 parent a98f78b commit d2ef0d6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions events/syscall/fileless_execution_via_memfd_create.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ func FilelessExecutionViaMemfdCreate(h events.Helper) error {
h.Log().WithError(err).Error("failed to write binary data to memory")
return err
}
defer unix.Close(fd)

// Execute the binary from memory
executeCmd := exec.Command("/proc/self/fd/" + fmt.Sprintf("%d", fd))
Expand Down

0 comments on commit d2ef0d6

Please sign in to comment.