question about emscripten client side

27 views
Skip to first unread message

Alessio Mochi

unread,
Nov 4, 2020, 11:09:39 AM11/4/20
to emscripten-discuss
Hello,

is it possible on the client side to download the whole application from the chrome debugger and get a working version? I see that it is possible to download the generated javascript and the wasm from emscripten via the debugger. I tried to download the project files to my local pc but I couldn't play them. The question is this: can a user use my javascript and wasm modules as if they were libraries by downloading them from the chrome debugger?

Thanks in advance.

Brion Vibber

unread,
Nov 4, 2020, 11:37:13 AM11/4/20
to emscripten Mailing List
Yes, but also with wget or curl. There's nothing special about the Chrome debugger in that regard.

If you have the files, you can load and execute them.

However using them usefully is a question of knowing what to do with them, just like downloading a .dll on Windows or .so on Linux or .dylib on macOS. You must know what inputs and outputs they expect to call them.

-- brion

--
You received this message because you are subscribed to the Google Groups "emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to emscripten-disc...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/9d8051b7-8249-4109-9697-bf3aa756622cn%40googlegroups.com.

Floh

unread,
Nov 4, 2020, 12:01:10 PM11/4/20
to emscripten-discuss
In general people can download all the files needed to run the WASM app from your webpage and host them somewhere else - if that's what you're afraid of. To prevent this you need to put the important parts into some server backend and behind some sort of authentication.

For instance in the context of a web game, think of the game client as a "dumb client" that isn't useful on its own without connecting to a server backend which runs the actual game logic (and handles payment etc). That way the game client isn't really the important part, people could copy this for free or even write their own client if they want, but in the end they need to connect to your game server to "run the game". Just don't accidentally leak the game server ;)

Alessio Mochi

unread,
Nov 4, 2020, 12:59:28 PM11/4/20
to emscripten-discuss
thanks you, 
I am evaluating alternatives on how to implement my application, in particular whether to use three.js to render from javascript and then use kernel functions in emscripten modules or to do all the kernel and rendering on the emscripten side. The second option seems safer to me ... In the first option once you understand the parameters of the modules you can reuse them to build another application, which I see difficult in the second option. 
Reply all
Reply to author
Forward
0 new messages