Function Reordering

Potency Low
Resilience High
Cost None
Tags: functions, reorder, scramble, obfuscation

Description

Function Reordering randomly reorders function declarations.

Code Annotation Example

// @jscrambler enable functionReordering

Example

The following example contains five function declarations and two function expressions:

function a () { /* body */ }
function b () { /* body */ }
function c () { /* body */ }
function d () { /* body */ }
function e () { /* body */ }
var f = function () { /* body */ }
var g = function () { /* body */ }

All function declarations have been reordered but the function expressions haven't:

function c () { /* body */ }
function e () { /* body */ }
var f = function () { /* body */ }
function b () { /* body */ }
function d () { /* body */ }
var g = function () { /* body */ }
function a () { /* body */ }

API Parameters

Example:

{
  "keys": {
    "accessKey": "XXXXXX",
    "secretKey": "YYYYYY"
  },
  "applicationId": "ZZZZZZ",
  "params": [
    {
      "name": "functionReordering"
    }
  ]
}