Hacking on Minijail


You'll need these to build the source:

You'll need to install the relevant packages from your distro.


For local experimentation (using Minijail libraries from the source directory):

$ make LIBDIR=/lib64
$ sudo ./minijail0 --preload-library=./libminijailpreload.so \
  -u ${USER} -g 5000 -- /usr/bin/id

For system-wide usage, install libminijail.so and libminijailpreload.so to /lib64 and minijail0 to a directory in your PATH (e.g. /usr/bin).


We use Google Test (i.e. gtest & gmock) for unit tests. You can download a suitable copy of Google Test using the get_googletest.sh script.

$ ./get_googletest.sh
$ make tests

Building the tests will automatically execute them.

Source Style



Minijail uses markdown for general/source documentation. We follow the Google Markdown style guide.

Man Pages

For users of Minijail (e.g. minijail0), we use man pages. For style guides, check out the [Linux man-pages project] for general guidance. It has a number of useful references for syntax and such.

minijail0.1 documents the command line interface. Please keep it in sync with minijail0_cli.c.

minijail0.5 documents the syntax of config files (e.g. seccomp filters).