You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 28, 2023. It is now read-only.
This seems like it could be consistent. NaCl sel_ldr has command line flags [-h d:D] [-r d:D] [-w d:D] for mapping host file descriptors into the sandbox:
-h
-r
-w associate a host POSIX descriptor D with app desc d
that was opened in O_RDWR, O_RDONLY, and O_WRONLY modes
respectively
Perhaps we could remove the existing special case for FDs 0, 1, and 2. IIRC these are currently kind of magically pre-opened?
Would libpreopen need to be involved at all? I mean would __wasilibc_register_preopened_fd need to be called or could we just start using these fds in syscall right away lib fd 0,1, 2?
This could be used to solve a major ergonomic issue with CLI WASI applications too! It'd be simple for a runtime to detect if arguments going to the WASI program are paths and then automatically preopen them.
Currently WASI only supports pre-opened directories. It'd be useful to have a preopen type indicating a file rather than just a directory.
The text was updated successfully, but these errors were encountered: