How to protect swf file from being decompiled?

一世执手 提交于 2019-12-23 15:46:27

问题


I'm working on important project using Flex framework and i want to keep my algorithms and code secret. Is it possible to somehow protect swf file from being decompiled? I don't want someone extract my code using flash decompilers.

Thanks.


回答1:


While there is no full-proof way to secure code from decompilers there are some tricks to reduce the chances of this happening.

  1. host the .swf on a https server then it doesnt get cached
  2. You can obfuscate the code to make it impossible to understand even if it is decompiled.
  3. Change the file extension of the .swf file to something like a .jpg file or a .png file, the browser should still detect that it is a .swf and display it correctly, but it will be stored in the cache as an image file



回答2:


It's simple. Just keep it on your PC and don't put it on the web.
ALL can be decompiled, reverse engineered and hacked, even programs written in c++/c/asm. If you want to make this task of decompiling a bit harder use some obfuscators for flash




回答3:


There is a product that encrypts the code inside the swf. It's not bullet proof but does protect.




回答4:


There are many tools to "encrypt" SWF even though I don't think we can actually discuss encryption here. Encryption is not obfuscation.

I've reviewed one such obfuscation tool just recently, see Protect your ActionScript code with SWF Protector.

Although it does pretty well for an obfuscator, you need to realise that:

  • obfuscation increases file size;
  • most obfuscation algorithms in use today are still pretty easy to reverse engineer, so it's certainly not a bullet-proof solution. It's just obfuscation and is likely to keep off amateurs and pros who find it easier to rewrite from scratch rather than mess with reversing the obfuscation.



回答5:


you can protect them by setting a password while compiling. can this solve your security issue?



来源:https://stackoverflow.com/questions/2251651/how-to-protect-swf-file-from-being-decompiled

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!