Skip to content

Commit

Permalink
fake_id0: hook mknod to always succeed
Browse files Browse the repository at this point in the history
  • Loading branch information
Rémi Duraffort committed Jul 4, 2013
1 parent 103bb66 commit d1be631
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/extension/fake_id0/enter.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ case PR_getresuid:
case PR_getresuid32:
case PR_getresgid:
case PR_getresgid32:
case PR_mknod:
/* Force the sysexit stage under seccomp. */
tracee->restart_how = PTRACE_SYSCALL;
default:
Expand Down
1 change: 1 addition & 0 deletions src/extension/fake_id0/exit.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ case PR_setuid32:
case PR_setgid32:
case PR_setfsuid32:
case PR_setfsgid32:
case PR_mknod:
/* Force success. */
poke_reg(tracee, SYSARG_RESULT, 0);
return 0;
Expand Down
1 change: 1 addition & 0 deletions src/extension/fake_id0/filter.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
{ PR_lchown32, 0 },
{ PR_lstat, 0 },
{ PR_lstat64, 0 },
{ PR_mknod, 0 },
{ PR_newfstatat, 0 },
{ PR_oldlstat, 0 },
{ PR_oldstat, 0 },
Expand Down

1 comment on commit d1be631

@oxr463
Copy link
Collaborator

@oxr463 oxr463 commented on d1be631 Mar 6, 2019

Choose a reason for hiding this comment

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

Please sign in to comment.