Skip to content
This repository has been archived by the owner on Nov 9, 2023. It is now read-only.

Run WebAssembly Executables #99

Open
kazu0617 opened this issue Sep 8, 2022 · 5 comments
Open

Run WebAssembly Executables #99

kazu0617 opened this issue Sep 8, 2022 · 5 comments
Labels
Help Wanted Extra attention is needed LogiX New Component

Comments

@kazu0617
Copy link

kazu0617 commented Sep 8, 2022

Neos-Metaverse/NeosPublic#2818

@jeanahelver
Copy link
Contributor

potential candidate library for wasm is WasmerSharp

@Frozenreflex Frozenreflex changed the title execute WabAssembly Run WebAssembly Executables Jan 8, 2023
@Frozenreflex
Copy link
Collaborator

This library doesn't use an external dependency, and compiles to an IL assembly, so it should work on more platforms and be easier to distribute. I'm not super familiar with WebAssembly, so there's lots of different aspects I don't know about. but given the nature of it, I presume the effective implementation would amount to custom Logix nodes and custom component drivers, perhaps with separate "WasmBinary" objects to allow for reusing code as sudo-libraries. Beyond that, I'm again not familiar enough with WebAssembly to speculate implementation details.

@Frozenreflex Frozenreflex added Help Wanted Extra attention is needed New Component LogiX labels Jan 8, 2023
@jeanahelver
Copy link
Contributor

that seems like a very bad idea since this will give full access to the system since its IL and can call system libraries.
you want the interpreted version that has a "fuel" cost so you can halt it from infinite loops and the likes.

@Frozenreflex
Copy link
Collaborator

Frozenreflex commented Jan 8, 2023

Unless the compiler is giving access to stuff it shouldn't, and if I'm reading the docs properly, the only way it would have access to the system is if said system libraries are imported, which we have control over and wouldn't give access to. You aren't able to just "create file IO instructions that steals your neos session key", you're limited to Wasm operations and whatever the compiler creates out of that. Fuel cost seems to be a hand-wavey argument to me, if we need to prevent infinite loops there's ways of doing it.

@Xlinka
Copy link
Owner

Xlinka commented Sep 5, 2023

i feel like we might have to build our own runner to run these webasm most of the stuff is out of date and idk about others considerations on this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Help Wanted Extra attention is needed LogiX New Component
Projects
None yet
Development

No branches or pull requests

4 participants