Protecting the sources of HTML5 game

后端 未结 8 650
小蘑菇
小蘑菇 2021-02-04 12:00

People have been saying so many good words for HTML5, but one of my main concern is how to protect the source code of my game.

essentially..

  1. How to prevent
相关标签:
8条回答
  • 2021-02-04 12:51

    Minifying your js code will make it much harder to reuse but not impossible

    0 讨论(0)
  • 2021-02-04 12:54

    Obfuscating your javascript code could be one important step. Obfuscation can make the code so complex that no sane person would try to hack it.

    I have been using jscrambler.com with good results. That said, obfuscation will not solve every problem. Users will still be able to view all the traffic exchanged between the browser and the server. So they will know how the API works and how to use it.

    To avoid this you can use encryption of messages using javascript. This could be helpful in securing the content. I found a post on stackoverflow that discuss encryption using javascript: Javascript AES encryption. There are a few implementations that can be used that have a low performance impact.

    Last but not least, all inputs should be thoroughly checked on the server side. All logic that can be implemented on the server side should remain there.

    0 讨论(0)
提交回复
热议问题