joystickControl Flow Flattening (Advanced Flow Obfuscation)

Control Flow Flattening is a passive obfuscation technique used to make reverse engineering and static analysis of an application's source code or bytecode more difficult. By directly interfering with the organization of the execution flow, this technique reduces the readability of the internal logic, protecting proprietary algorithms and sensitive business rules from understanding and unauthorized copying.

Technical Mechanism: MAD applies Control Flow Flattening by restructuring the application's execution flow in a non-linear and intentionally complex way. This transformation breaks the direct logical relationship between code sections, fragmenting execution into multiple artificial paths. As a result, decompilation and static analysis tools begin to present a distorted and unrepresentative view of the original logic, making manual and automated analysis more difficult.

<bundleObfuscation>
    <!--
    Enables obfuscation of the Android Dex files in the application. The minSdkVersion of the application
    must be at least 23.
    -->
    <obfuscateDex>true</obfuscateDex>


    <!--
    Enables obfuscation of the application assets. Each <asset> element defines a path to be obfuscated. The path can
    include wildcards and is relative to the `assets/` directory (e.g. `<asset>secrets/*.txt</asset>` will match every
    ".txt" files at `assets/secrets`).
    -->
    <obfuscateAssets>
        <asset>certificates/*.der</asset>
    </obfuscateAssets>
    
    <!--
    Enables obfuscation of some asset files in the application. The <stack> option in <general> must be
    configured according to your application stack so that the obfuscation is applied to the correct files.
    -->
   	<obfuscateJs>true</obfuscateJs>
</bundleObfuscation>

Last updated