node.js – Code Protection?
You could accomplish this with a NativeExtension for node You’d have a boostrap.js file that adds a extension handler for .jse files // register extension require.extensions[“.jse”] = function (m) { m.exports = MyNativeExtension.decrypt(fs.readFileSync(m.filename)); }; require(“YourCode.jse”); YourCode.jse would be the encrypted version of your source code (the key for decryption wouldn’t be anywhere in plain-text because … Read more