pmq20 / node-packer

Packing your Node.js application into a single executable.
MIT License
3.07k stars 202 forks source link

Can the packaged executable file effectively protect the source code? #156

Closed unitwk closed 3 years ago

unitwk commented 3 years ago

I hope to avoid leaking the JavaScript source code. I wonder if the packaged executable program can avoid this?

mister-perfect commented 3 years ago

I do not think the executable file would protect the source code. The data of the squashfs image is just a C array: const uint8_t enclose_io_memfs[#{bytes.size}] = { #{bytes[0]}". The hacker could decompile, extract these bytes then mount xxx.sqsh /mnt/xxx. All codes is here.

@Suwings