tree: ec4d0271ea720fe747098784f71f5952d9d637db [path history] [tgz]
  1. generator/
  3. DEPS
  4. irt_entry_mojo.c
  5. mojo_syscall.h
  6. mojo_syscall_internal.h
  8. monacl_sel_main.h


This is a prototype for plumbing Mojo into the NaCl sandbox. It is currently insecure (see below), does not provide a stable ABI (IRT support must be added), and does not support Mojo functions that return pointers (for example, MojoMapBuffer).


To use this prototype, point your .gclient file to DEPS.nacl instead of DEPS and then run gclient sync.

When you run mojo/tools/ gn, add --nacl to the command line.

Run mojo/tools/ nacltest for additional nacl-specific tests.


generator/ contains a programmatic description of the stable Mojo interface. This will need to be updated as the interface changes. Run generator/ to generate the bindings that plumb this interface into the NaCl sandbox.

Security TODO

  • Separate trusted and untrusted Mojo handles.
  • Validate and copy option structures.
  • Protect untrusted buffers passed into Mojo:
    • NaClVmIoWillStart/HasEnded.
    • volatile accesses to untrusted memory (untrusted code could race).
  • Overflow checking in array bounds validation.