TheGunners
TheGunners

Reputation: 205

restrict swf file from playing on its own

I'm creating a app for android using flash AS3. In my app, there are external swf files which are mostly games and slides. What I'm concerned about is, if you have apk file then you can extract swf files from it . So how can i restrict that swf file from playing if it is used without the main app. Is it possible without using another software ?

Upvotes: 0

Views: 127

Answers (1)

Namit Sinha
Namit Sinha

Reputation: 1445

What you are saying is impossible there is no trick for complete avoidance of reverse engineering. if your user gets his hands on your apk file he can easily extract it and get the swf files you put there .

You can use a hack for naive users you can set your frame 2 to go back to frame 1 ie make a loop from frame 1-2-1-2... and start your actual file from frame 5 making it hard to see what's inside, And use it accordingly in your app.

use tools to encrypt or obfuscate SWF files see this though even this is not full-proof method.

Check everything in your swf that will allow it to run only on a particular OS ie sniff the OS it is running on if it is not the desired OS destroy stage and close . This can be done using flash.system.Capabilities class

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/system/Capabilities.html#version

Upvotes: 1

Related Questions