node.js - Code Protection?

后端 未结 13 2110
感动是毒
感动是毒 2020-11-29 15:21

I want to use node.js in my next project, but my boss does not like that our competitors can read the source code.

Is there a way to protect the JavaScript code?

13条回答
  •  北海茫月
    2020-11-29 16:12

    I have an idea. Protect a cpp or java application instead of js.

    1. Wrap your code in an encryption format, and compile it as a utf-8 file resource.
    2. Use your cpp or java application to upload the entire file to a linux pc or arm computer, make sure you have a strong password or close ssh port or disable the video port and browse the linux pc only by web.
    3. There is a cpp program to decrypt the file in the linux pc.
    4. Develop a webserver to controll your linux pc.

    So this is much like a black box, the clients can do nothing to your code.

提交回复
热议问题