Stream: git-wasmtime

Topic: wasmtime / issue #12912 wasi:fs mutate-directory ignored


view this post on Zulip Wasmtime GitHub notifications bot (Mar 31 2026 at 17:58):

MendyBerger opened issue #12912:

Overview

As far as I can tell, wasmtime never checks descriptor-flags.mutate-directory.

Also, wasmtime seems to be passing down mutate-directory in open-at even when the caller/guest doesn't ask for it.

See line 1054 where the parent's permissions are just passed down:
https://github.com/bytecodealliance/wasmtime/blob/33e8b3d955697587b23cf39d87fbcbdb4d26b0c9/crates/wasi/src/filesystem.rs#L1052-L1058

Expected Results

mutate-directory should be required when editing directories, and should not be passed down from the parent automatically.

Actual Results

mutate-directory is ignored, and is passed down from the parent automatically.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 31 2026 at 17:58):

MendyBerger added the bug label to Issue #12912.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 31 2026 at 19:03):

alexcrichton removed the bug label from Issue #12912.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 31 2026 at 19:03):

alexcrichton added the wasi:impl label to Issue #12912.

view this post on Zulip Wasmtime GitHub notifications bot (Mar 31 2026 at 19:04):

alexcrichton commented on issue #12912:

I mentioned a bit of this on Zulip as well, but I suspect this is a mixture of being historically ambitious about what would be done coupled with this hasn't really aged well coupled with a lack of tests. I think it's reasonable to tweak behavior here as necessary and avoid taking Wasmtime as the source of truth. Would you be up for sending a PR to adjust the aspects you feel need changing?

view this post on Zulip Wasmtime GitHub notifications bot (Mar 31 2026 at 20:10):

MendyBerger commented on issue #12912:

Sure, will take a stab at it


Last updated: Apr 12 2026 at 23:10 UTC