Skip to content

Commit

Permalink
no_new_privs test container
Browse files Browse the repository at this point in the history
Signed-off-by: Jess Frazelle <acidburn@google.com>
  • Loading branch information
jessfraz committed Jun 6, 2017
1 parent a9b27fb commit dfb1db2
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
6 changes: 6 additions & 0 deletions no_new_privs/Dockerfile
@@ -0,0 +1,6 @@
FROM alpine:latest

COPY nnp /usr/local/bin/nnp
RUN chmod +s /usr/local/bin/nnp

CMD ["/usr/local/bin/nnp"]
Binary file added no_new_privs/nnp
Binary file not shown.
8 changes: 8 additions & 0 deletions no_new_privs/nnp.c
@@ -0,0 +1,8 @@
#include <stdio.h>
#include <unistd.h>
#include <sys/types.h>

int main(int argc, char *argv[]){
printf("Effective uid: %d\n", geteuid());
return 0;
}

0 comments on commit dfb1db2

Please sign in to comment.