In Flash AS3 what is the best way to protect my code?

Posted on 2012-08-22
Last Modified: 2012-09-07
dear gurus,

I have about 25 SWFs in my App which are loaded at runtime.
Now I want to protect my code in these SWFs.

I've tried some obfiscators including "SecureSWF" but have found them to be pretty insecure - I could decompile them easily with some Apps.

So I thought about encrypting my SWFs at build time and decrypting them in my loader class. I would load the SWF as a XYZ file and decrypt it as a byteArray and use "Loader" class "LoadBytes()" but it only works on SWFs which contain no code :(

Any ideas greatly appreciated :)
Question by:jasonb2
    LVL 51

    Expert Comment

    > thought about encrypting my SWFs at build time and decrypting them in my loader
    then you need to tell the loader the passphrase for decrypting, which then is at client side again

    your SWF is executed at the client, hence it has to have the decrypted code

    hence the simple answer to your simple question
      "what is the best way to protect my code?"

    is: don't publish the code.

    Accepted Solution

    thanks :)

    I've found a good way to obfuscate our project:

    Use "toKaos" to obfuscate the source code.
    then, use "SecureSWF" to obfuscate the compiled code.

    We do this and are happy with the result.

    Author Closing Comment

    i hope this helps everyone

    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    Join & Write a Comment

    Suggested Solutions

    Introduction This article is primarily concerned with ActionScript 3 and generally specific to AVM2.  Most suggestions would apply to ActionScript 2 as well, and I've noted those tips that differ between AS2 and AS3. With the advent of ActionS…
    In this tutorial I will show you how to provide a dynamic RTF document on your website generated with data from your database. For this tutorial you will need Microsoft Word or WordPad, WhizBase and Microsoft Access. In this tutorial I will show …
    The purpose of this video is to demonstrate how to set up basic WordPress SEO. This will be demonstrated using a Windows 8 PC. The plugin used will be WordPress SEO by Yoast. Go to your WordPress login page. This will look like the following: myw…
    The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

    732 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now