actionscript 3 - How to Site-Lock a Flash Application? -
I have a flash application that I will put on my website shortly I want to be able to "lock" the site to stop it:
- SWF hosting (after illegal download) on another site, and
- open SWF But if it is included in IFrame on any other site
when giving permission:
- Whitelist URLs of sites that are not / without me Define all forms of i.e. (i.e.: www.abc.com, abc.com, abc.com/game/, games.abc.com, etc.)
Customs The applications that spend hundreds of dollars to do this work, but I'm pretty sure this can be done with:
root.loaderInfo.url . Does anyone know how to go about doing this? My biggest concern is the prevention of IFrame, because when sites cheat flash, they usually do IFrame on their site to save bandwidth costs.
I am using Flex SDK (not Flash IDE) so some pure AS3 code will do the trick for me.
This code will report back to the loading URL. You can show an unauthorized message in your main loader or do not load it if it does not match your expectations: This is not exactly the case:
Public stable work domain (root: Sprite): String {Var currentman: string = root.loaderInfoEur.equal split ("/") [2]; Var fqdn: array = current daaman. Split ("."); Var rdi: int = 1; Var tli: int = 2; If (fqdn.length == 2) {rdi--; Tli--; } Return fqdn [rdi] + "." + FCDN [Tally]; }
Comments
Post a Comment