Skip to content
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion benchmark.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ print("Iterations: " .. tostring(Iterations))
print("CLOSURE testing.")
local Start = os.clock()
local TStart = Start
for Idx = 1, Iterations do
for _ = 1, Iterations do
(function()
if not true then
print("Hey gamer.")
Expand Down
5 changes: 3 additions & 2 deletions cli.lua
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
-- This Script is Part of the Prometheus Obfuscator by Levno_710
--
-- test.lua
-- This script contains the Code for the Prometheus CLI
-- cli.lua
--
-- This Script contains the Code for the Prometheus CLI

-- Configure package.path for requiring Prometheus
local function script_path()
Expand Down
32 changes: 15 additions & 17 deletions doc/getting-started/the-config-object.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# The Config Object

Prometheus takes a configuration objetct. In this object there can be many properties applied. \
Prometheus takes a configuration object. In this object there can be many properties applied. \
The following table provides an overview:

| Property | type | possible values | default |
Expand All @@ -18,21 +18,19 @@ As an example, here is the code for the minify preset:

```lua
{
-- The default LuaVersion is Lua51
LuaVersion = "Lua51";
-- For minifying no VarNamePrefix is applied
VarNamePrefix = "";
-- Name Generator for Variables
NameGenerator = "MangledShuffled";
-- No pretty printing
PrettyPrint = false;
-- Seed is generated based on current time
Seed = 0;
-- No obfuscation steps
Steps = {

}
};
-- The default LuaVersion is Lua51
LuaVersion = "Lua51";
-- For minifying no VarNamePrefix is applied
VarNamePrefix = "";
-- Name Generator for Variables
NameGenerator = "MangledShuffled";
-- No pretty printing
PrettyPrint = false;
-- Seed is generated based on current time
Seed = 0;
-- No obfuscation steps
Steps = {}
};
```

### Steps
Expand All @@ -49,7 +47,7 @@ Steps = {
-- Apply to Strings only
StringsOnly = true;
-- Apply to all Constants, 0.5 would only affect 50% of strings
Treshold = 1;
Threshold = 1;
}
},
}
Expand Down
4 changes: 2 additions & 2 deletions doc/getting-started/writing-a-custom-config-file.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ return {
NameGenerator = "MangledShuffled";
-- No pretty printing
PrettyPrint = false;
-- Seed is generated based on current time
-- Seed is generated based on current time
-- When specifying a seed that is not 0, you will get the same output every time
Seed = 0;
-- Obfuscation steps
Expand All @@ -25,7 +25,7 @@ return {
-- Apply to Strings only
StringsOnly = true;
-- Apply to all Constants, 0.5 would only affect 50% of strings
Treshold = 1;
Threshold = 1;
}
},
}
Expand Down
14 changes: 7 additions & 7 deletions doc/steps/constantarray.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ description: >-

| Name | type | description |
| -------------------- | ------- | ------------------------------------------------------------------------------------------------------------ |
| Treshold | number | The relative amount of nodes that will be affected" |
| StringsOnly | boolean | Wether to only Extract Strings |
| Shuffle | boolean | Wether to shuffle the order of Elements in the Array |
| Rotate | boolean | Wether to rotate the String Array by a specific (random) amount. This will be undone on runtime. |
| LocalWrapperTreshold | number | The relative amount of nodes functions, that will get local wrappers |
| LocalWrapperCount | number | The number of Local wrapper Functions per scope. This only applies if LocalWrapperTreshold is greater than 0 |
| Threshold | number | The relative amount of nodes that will be affected" |
| StringsOnly | boolean | Whether to only Extract Strings |
| Shuffle | boolean | Whether to shuffle the order of Elements in the Array |
| Rotate | boolean | Whether to rotate the String Array by a specific (random) amount. This will be undone on runtime. |
| LocalWrapperThreshold | number | The relative amount of nodes functions, that will get local wrappers |
| LocalWrapperCount | number | The number of Local wrapper Functions per scope. This only applies if LocalWrapperThreshold is greater than 0 |
| LocalWrapperArgCount | number | The number of Arguments to the Local wrapper Functions |
| MaxWrapperOffset | number | The Max Offset for the Wrapper Functions |

Expand All @@ -32,7 +32,7 @@ print("4")

{% code title="out.lua" %}
```lua
-- LocalWrapperCount = 3
-- LocalWrapperCount = 3
-- LocalWrapperArgCount = 5
local F = {"4", "3", "2", "1"}
do
Expand Down
4 changes: 2 additions & 2 deletions doc/steps/splitstrings.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ description: This Step splits Strings to a specific or random length

| Name | type | description | Values |
| ------------------------- | ------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------- |
| Treshold | number | The relative amount of nodes that will be affected | 0 <= x <= 1 |
| Threshold | number | The relative amount of nodes that will be affected | 0 <= x <= 1 |
| MinLength | number | The minimal length for the chunks in that the Strings are splitted | x > 0 |
| MaxLength | number | The maximal length for the chunks in that the Strings are splitted | x >= MinLength |
| ConcatenationType | enum | The Functions used for Concatenation. Note that when using custom, the String Array will also be Shuffled | "strcat", "table", "custom" |
| CustomFunctionType | enum | <p>The Type of Function code injection This Option only applies when custom Concatenation is selected.<br>Note that when chosing inline, the code size may increase significantly!</p> | "global", "local", "inline" |
| CustomFunctionType | enum | <p>The Type of Function code injection This Option only applies when custom Concatenation is selected.<br>Note that when choosing inline, the code size may increase significantly!</p> | "global", "local", "inline" |
| CustomLocalFunctionsCount | number | The number of local functions per scope. This option only applies when CustomFunctionType = local | x > 0 |

### Example
Expand Down
2 changes: 1 addition & 1 deletion doc/steps/vmify.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
description: This Step will Compile your script and run it within a Vm
description: This Step will Compile your script and run it within a VM.
---

# Vmify
Expand Down
Loading
Loading