tokaos the action script obfuscator

toKaos is a desktop windows software application which allows you to encrypt/obfuscate your action script AS3 source code.

toKaos is the only product able to operate directly on a copy of your source code providing you with a new encrypted/obfuscated source code. After the process you can compile and deploy your product (SWF or SWC).

Having the encrypted/obfuscated source code available is a more powerful tool than having only an encrypted SWF/SWC, because you have a total control of the software that you are deploying. Furthermore you will be able to verify what the SWF/SWC source hacker will be able to see.

Install and use toKaos for free. Personal use and Commercial use without limitation.

toKaos Overview

Our encryption/obfuscation works directly on a copy of your source code encrypting identifiers

Packages identifier. Classes identifier. Functions identifier (private, internal, protected and public). Functions parameters identifier. Functions variables identifier. Class variables identifier (private, internal, protected and public).

Not only encryption, but toKaos can obfuscate your source code

Change package structure. Source compacting. Explode included files. Remove comments. String literal obfuscation.

toKaos provides the developer with the user preferences

You can decide which items will be encrypted. You can specify the source path of the used libraries (look at guidelines for libraries encryption). You can specify one or more named identifier to prevent the encryption.

toKaos provides the developer with the KTM (toKaos Translation Map)

By using the KTM only the developer will be able to understand the obfuscated source code. The KTM provides a matching table between the original identifier and the encrypted identifier.

Opening

You can open a Flex Application, ActionScript Project, Flash file (.fla) and an ActionScript Source Path.

Choose your encryption type

Maximum length identifier. Medium length identifier. Variable length identifier. Minimum length identifier. Minimum length identifier (Random). Lowercase. Add your personal prefix to identifiers.

How to use toKaos

Project Reader currently is available in two different editions which mainly differ in functionality. Compare and choose the right edition based on needs.

  • Select your action script AS3 source code. You have three possibilities:
    • Flex Application, typically created with Flex Builder AS3 (Web application runs in Flash Player or Desktop application runs in Adobe AIR)
    • Flash file (FLA), typically created with Flash CS3 Professional. It contains your project
    • Source path containing your action script classes .as and .mxml and packages; typically this directory is named src
  • Decide the general items to encrypt
  • Start Analysis (.... now toKaos will analyze your action script source code and it will show the output of the analysis before encrypting/obfuscating it)
  • Navigate, as you like it, through the objects of your project specifying which identifier must not be encrypted
  • Start the encryption process


  • At the end of the process you will find:
    • in case of Flex Application, a new Flex project named yourprojectname-toKaos containing the complete project
    • in case of Flash file (FLA), a new directory dir_containing_fla_file-toKaos containing all files for compiling your project
    • in case of Source path, a new directory source_path-toKaos containing the encrypted source code and others linked files


    Only two minutes to operate with the encrypted/obfuscated source code:
    • in case of Flex Application, you can import the project yourprojectname-toKaos Adobe Flex Builder 3 environment and compile it producing your SWF or SWC file
    • in case of Flash file (FLA),using Adobe Flash CS3 open your .FLA contained into the folder named dir_containig_fla_file-toKaos; compile your .FLA file producing the SWF file
    • in case of Source path, you have to integrate, as you like it, the encrypted/obfuscated source code contained in source_path-toKaos in your working environment proceeding to the compilation and producing your SWF or SWC files

tokaos in action



Guidelines for libraries encryption and obfuscation

Below you will find information about encrypting libraries. In detail we will show how to encrypt a standalone library and how to encrypt Flex application (.mxml) with your owned linked libraries.

 How to encrypt libraries preserving the documented public interfaces

In opening you have to use the Source path option.

Usually the libraries used from others developers are well documented in a Reference Manual (or ASDoc). This reference manual will contain all the usable public objects (packages, classes, public variables and public functions).

To preserve the programming interface you have two way:

Fast configuration

  • uncheck the option Encrypt package identifier
  • uncheck the option Encrypt class identifier
  • uncheck the option Encrypt public variable identifier
  • uncheck the option Encrypt public function identifier
  • uncheck the option Encrypt public function parameter identifier
    

Using this approach all the public interfaces will be preserved, however the encryption/obfuscation will be at the minimum level, the encryption will be applied only to:

  • private, internal, protected variables identifier
  • private, internal, protected functions identifier
  • functions parameters

Ad-hoc configuration

  • check the option Encrypt package identifier
  • check the option Encrypt class identifier
  • check the option Encrypt public variable identifier
  • check the option Encrypt public function identifier
  • uncheck the option Encrypt public function parameter identifier
    

After the analysis phase, you have to navigate on the structure of your sources configuring as below:

  • On the tree (left side) select the project path and on the right side list uncheck the packages documented on Reference Manual
        
  • On the tree (left side) select the packages previous unchecked and on the right side list uncheck the classes documented on Reference Manual
        
  • On the tree (left side) select the classes previous unchecked and on the right side list uncheck the public variables and functions documented on Reference Manual
        

 How to encrypt Flex application together with your owned linked libraries (libraries with available sources)

In opening you have to use the Flex application option.

On General option panel you have to choose the Libraries tab. In this section you can add or change the source path of the used libraries.

Configuring the libraries source path allows to analyze all the sources and also the libraries source code used in your main project will be encrypted. During the encryption the libreries source code will be imported into the main Flex project.

After the compilation you will have only the SWF file without the linked libraries, because the source code of the linked libraries has been included in the main project.

Adding the source path of the used libraries allows to have an high level of encryption.

tokaos Command-Line Usage Guide

Below you will find information about Command-Line usage.

 Sintax

toKaos.exe [-g:config-file] as-project

config-file [optional] configuration file absolute path. If not specified toKaos looks for user settings of the last processing using toKaos gui. If the project was never processed with toKaos gui the standard default values will be taken.

as-project mandatory. Absolute path of an .mxml file or .as file or .fla file or a source directory.


 Examples

"C:\Program Files\KSOL\toKaos\toKaos.exe" –g:C:\Projects\MyProjectX\MyProjectX.cfg C:\Projects\MyProjectX\src\MyProjectX.mxml

"C:\Program Files\KSOL\toKaos\toKaos.exe" C:\Projects\MyProjectX\src\MyProjectX.mxml

"C:\Program Files\KSOL\toKaos\toKaos.exe" –g:C:\Projects\MyProjectY\MyProjectY.cfg C:\Projects\MyProjectY\src\MyProjectY.as

"C:\Program Files\KSOL\toKaos\toKaos.exe" C:\Projects\MyProjectY\src\MyProjectY.as

"C:\Program Files\KSOL\toKaos\toKaos.exe" –g:C:\Projects\MyProjectZ\MyProjectZ.cfg C:\Projects\MyProjectZ\src\MyProjectZ.fla

"C:\Program Files\KSOL\toKaos\toKaos.exe" C:\Projects\MyProjectZ\src\MyProjectZ.fla

"C:\Program Files\KSOL\toKaos\toKaos.exe" –g:C:\Projects\MyProjectLib\MyProjectLib.cfg C:\Projects\MyProjectLib\src\

"C:\Program Files\KSOL\toKaos\toKaos.exe" C:\Projects\MyProjectLib\src\


 Configuration file specification

Is a .INI file standard format, it contains two section: [startup] and [user].

[startup] Section
It contains the encryption/obfuscation parameters.

ParameterDescriptionAdmitted values
a1Encrypt package identifier0: do not encrypt
1: encrypt
a2Encrypt class identifier0: do not encrypt
1: encrypt
a3Encrypt public variable identifier0: do not encrypt
1: encrypt
a4Encrypt public function identifier0: do not encrypt
1: encrypt
a5Compact sources0: do not compact
1: compact
a6Encrypt public function parameter identifier0: do not encrypt
1: encrypt
a7Encryption type 1: Maximum length identifiers
2: Medium length identifiers
3: Minimum length identifiers
6: Variable length identifiers
7: Lowercase identifiers

[user] Section
It contains three types of informations: reserved identifiers, libraries and elements to not encrypt:

ParameterDescriptionExample
wxxxRserved identifiersw001=getAge
w002=processGuid
lxxxLibraries
Sintax: name|path
l001= FlexLibs|D:\Kaos\FlexMdi11
pxxxPackage identifiers to not encrypt
Sintax: package
p001= com.yahoo.astra.animation
p002= com.yahoo.astra.mx.core
cxxxClass identifiers to not encrypt
Sintax: package|class
c001= com.yahoo.astra.animation|Animation
c002= com.yahoo.astra.utils|ColorUtil
fxxxFunction identifiers to not encrypt
Sintax: package|class|function
f001= com.yahoo.astra.animation|Animation|whiteOrBlack
vxxxVariable identifiers to not encrypt
Sintax: package|class|variable
v001= com.yahoo.astra.animation|AnimationEvent|parameters
rxxxFunction parameter to not encrypt
Sintax: package|class|function|parameter
r001= com.yahoo.astra.utils|ColorUtil|HSBColor|brightness|value
axxxFunction local variable to not encrypt
Sintax: package|class|function|variable
a001= com.yahoo.astra.utils|ColorUtil|HSBtoRGB|rgb

Example of a config-file

[startup]
a1=0
a2=1
a3=1
a4=1
a5=0
a6=1
a7=3

[user]
w001=Animation
w002=ThumbSkin
l001=FlexLibs|C:\Projects\MyProjectX\MyLib\src
c001=|Astra
c002=com.yahoo.astra.animation|Animation
p001=com.yahoo.astra.mx.skins.halo
f001=com.yahoo.astra.utils|ColorUtil|CMYKToCMY
f002=com.yahoo.astra.utils|ColorUtil|HSBToCMYK
v001=com.yahoo.astra.utils|HSBColor|_saturation
v002=com.yahoo.astra.utils|HSBColor|_hue
r001=com.yahoo.astra.utils|ColorUtil|CMYKToCMY|cmyk
a001=com.yahoo.astra.utils|ColorUtil|CMYKToCMY|cyan
a002=com.yahoo.astra.utils|ColorUtil|CMYKToCMY|key
a003=com.yahoo.astra.utils|ColorUtil|CMYKToCMY|magenta
a004=com.yahoo.astra.utils|ColorUtil|CMYKToCMY|yellow

free for commercial and personal use

Download Now