Skip to content

Conversation

@JamesMenetrey
Copy link
Contributor

Hello,

A limitation of the current implementation of SGX IPFS in WAMR prevented to openof files which were not in the current directory. This restriction is lifted and can now open files in paths, similarly to the WASI openat call, which takes into account the sandbox of the file system.

Under the scenes, SGX IPFS retrieves the path of the symbolic link of the file descriptor using /proc/self and resolves the path of the opened file using readlink.

Cheers

…sing IPFS.

A limitation of the current implementation of SGX IPFS in WAMR prevented to open of
files which were not in the current directory. This restriction is lifted and can
now open files in paths, similarly to the WASI openat call, which takes into
account the sandbox of the file system.
@JamesMenetrey
Copy link
Contributor Author

Hey @wenyongh,

Thanks for your insights! I have reviewed, commented and applied the changes.
Let me know if you have other feedback or concerns.

Cheers

@wenyongh
Copy link
Collaborator

wenyongh commented Nov 7, 2022

@JamesMenetrey Thanks a lot! It is much better now, I will merge the PR after the CI checks finish.

@wenyongh wenyongh merged commit 328fd59 into bytecodealliance:main Nov 7, 2022
NingW101 pushed a commit to NingW101/wasm-micro-runtime that referenced this pull request Dec 1, 2022
…ing IPFS (bytecodealliance#1685)

A limitation of the current implementation of SGX IPFS in WAMR is that
it prevents to open files which are not in the current directory.
This restriction is lifted and can now open files in paths, similarly to the
WASI openat call, which takes into account the sandbox of the file system.
wenyongh pushed a commit that referenced this pull request Dec 6, 2022
…ing IPFS (#1685)

A limitation of the current implementation of SGX IPFS in WAMR is that
it prevents to open files which are not in the current directory.
This restriction is lifted and can now open files in paths, similarly to the
WASI openat call, which takes into account the sandbox of the file system.
vickiegpt pushed a commit to vickiegpt/wamr-aot-gc-checkpoint-restore that referenced this pull request May 27, 2024
…ing IPFS (bytecodealliance#1685)

A limitation of the current implementation of SGX IPFS in WAMR is that
it prevents to open files which are not in the current directory.
This restriction is lifted and can now open files in paths, similarly to the
WASI openat call, which takes into account the sandbox of the file system.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants