Skip to content

Commit 33af22e

Browse files
authored
Refactor script.js for improved functionality
1 parent 02c1d0b commit 33af22e

1 file changed

Lines changed: 43 additions & 83 deletions

File tree

script.js

Lines changed: 43 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,26 @@
1-
/**
2-
* POBFUS 1.11 // CORE_PROTECTOR
3-
* ENGINE: CAMBUSCATE 0.2.1
4-
* [!] PRODUCTION BUILD - ANTI-LEAK ENABLED
5-
*/
6-
7-
(function(_0xPOBFUS) {
8-
// Barcode Generator for Lua variables
9-
const _0xBC = (l) => {
10-
let r = "I";
11-
for(let i=0; i<l; i++) r += "Il".charAt(Math.floor(Math.random() * 2));
12-
return r;
13-
};
14-
15-
// UI String Decryption (XOR 0x6F)
1+
(function(_0xCORE) {
2+
const _0xBC = (l) => { let r = "I"; for(let i=0; i<l; i++) r += "Il".charAt(Math.floor(Math.random() * 2)); return r; };
163
const _0xS = (h) => h.split(',').map(b => String.fromCharCode(parseInt(b, 16) ^ 0x6F)).join('');
174

18-
// Randomized Alphanumeric Noise
19-
const _0xSCREAM = (len) => {
20-
const c = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
21-
let r = "";
22-
for(let i=0; i<len; i++) r += c.charAt(Math.floor(Math.random() * c.length));
23-
return r;
24-
};
25-
26-
// Roast Database
275
const _0xROASTS = [
286
"your decompiler likes me~ too much...",
297
"feed me to your poor decompiler senpai!!!~",
30-
"staring at my bytecode again? how lewd~",
318
"is that a hook? how aggressive, senpai~",
329
"your decompiler is blushing at this complexity~"
3310
];
3411

3512
const _STR = {
36-
logo: ` _______ __ ___ \n|_ __ \\ [ | .' ..] \n | |__) | .--. | |.--. _| |_ __ _ .--. \n | ___// .'\`\\ \\| '/'\`\\ \\'-| |-'[ | | | ( (\`\\] \n _| |_ | \\__. || \\__/ | | | | \\_/ |, \`'.'. \n|_____| '.__.'[__;.__.' [___] '.__.'_/([__) ) \n \n [ Pobfus 1.11 | CamBuscate 0.2.1 ]`,
37-
run: _0xS("3C,20,22,3F,26,23,2A,4F,3F,20,2D,29,3A,3A"),
38-
idle: _0xS("36,2E,22,2D,2E,2C,3F,36,2E,3A,24,2A,4F,33,3E,2E,2D"),
39-
work: _0xS("2E,2B,2B,20,2C,2E,3B,36,2B,26,20,28,4F,30,3E,2B,2D,3A")
40-
};
41-
42-
// High-Entropy Filename Generator
43-
const _0xFILE_GEN = () => {
44-
const _c = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#$%^&*";
45-
let _r = "pobfus-";
46-
for(let i=0; i<30; i++) _r += _c.charAt(Math.floor(Math.random() * _c.length));
47-
return _r + ".lua";
13+
logo: ` _______ __ ___ \n|_ __ \\ [ | .' ..] \n | |__) | .--. | |.--. _| |_ __ _ .--. \n | ___// .'\`\\ \\| '/'\`\\ \\'-| |-'[ | | | ( (\`\\] \n _| |_ | \\__. || \\__/ | | | | \\_/ |, \`'.'. \n|_____| '.__.'[__;.__.' [___] '.__.'_/([__) ) \n \n [ Pobfus 1.11.01 | CamBuscate 0.2.1 ]`,
14+
ui_run: _0xS("3C,20,22,3F,26,23,2A,4F,33,2E,21,20"), // "COMPILE_DATA"
15+
ui_copy: _0xS("2C,20,3F,36"), // "COPY"
16+
ui_dl: _0xS("2D,3E,37,21,2E,20,2E,2B,2B,2B") // "DOWNLOAD..."
4817
};
4918

5019
document.addEventListener('DOMContentLoaded', () => {
5120
document.getElementById('logo').textContent = _STR.logo;
52-
document.getElementById('go').innerText = _STR.run;
53-
document.getElementById('status').innerText = _STR.idle;
21+
document.getElementById('go').innerText = _STR.ui_run;
22+
document.getElementById('cp').innerText = _STR.ui_copy;
23+
document.getElementById('dl').innerText = _STR.ui_dl;
5424
});
5525

5626
window.run = async function() {
@@ -60,74 +30,64 @@
6030
const _b = document.getElementById('go');
6131

6232
if (!_i.value.trim()) return;
63-
6433
_b.disabled = true;
65-
_s.innerText = _STR.work;
34+
_s.innerText = "CAMBUSCATE_0.2.1: STABILIZING_PRINT_STREAMS...";
6635

67-
await new Promise(r => setTimeout(r, 1200));
36+
await new Promise(r => setTimeout(r, 1000));
6837

6938
try {
70-
const _k = Math.floor(Math.random() * 95) + 35;
39+
const _k = Math.floor(Math.random() * 90) + 40;
7140
const _raw = _i.value.split('');
7241
let _stream = [];
7342

74-
// Phase: Byte-Sliding & Roast Injection
43+
// Chaos Injection Logic
7544
_raw.forEach((c, idx) => {
7645
_stream.push("0x" + (c.charCodeAt(0) ^ _k).toString(16).toUpperCase());
77-
if (idx % 10 === 0) {
78-
const r = _0xROASTS[Math.floor(Math.random() * _0xROASTS.length)];
79-
_stream.push(`"${r}_${_0xSCREAM(5)}"`);
46+
if (idx % 8 === 0) {
47+
const r = _0xROASTS[Math.floor(Math.random()*_0xROASTS.length)];
48+
_stream.push(`"${r}_${Math.random().toString(36).substring(4)}"`);
8049
}
8150
});
8251

83-
// Variable Barcode Mapping
84-
const _v = {
85-
env: _0xBC(12),
86-
out: _0xBC(10),
87-
tab: _0xBC(14),
88-
vm: _0xBC(16),
89-
char: _0xBC(11),
90-
xor: _0xBC(9)
91-
};
52+
const _v = { env: _0xBC(8), vm: _0xBC(10), out: _0xBC(9), tab: _0xBC(11) };
9253

93-
// Construction: Minified Brick Output
94-
let _p = `--[[${_STR.logo}\n[!] POBFUS_1.11 // CAMBUSCATE_0.2.1]] `;
54+
// MINIFIED OUTPUT CONSTRUCTION
55+
let _p = `--[[${_STR.logo}\n[!] POBFUS_1.11.01]] `;
9556

96-
// Lag-Sync Memory Bloat
97-
for(let i=1; i<=4; i++) {
98-
_p += `local P_${i}="";for i=1,450 do P_${i}=P_${i}.."${_0xSCREAM(2)}" end;`;
99-
}
100-
101-
// The Engine Core (Minified)
57+
// Environment Lockdown
10258
_p += `local ${_v.env}=(getfenv(0) or _G);local ${_v.out}="";local ${_v.tab}={${_stream.join(',')}};`;
103-
_p += `local ${_v.char}=${_v.env}["\115\116\114\105\110\103"]["\99\104\97\114"];`;
104-
_p += `local ${_v.xor}=${_v.env}["\98\105\116\51\50"]["\98\120\111\114"];`;
59+
60+
// Fixed Byte-Slide VM (Handles Print Stability)
10561
_p += `local function ${_v.vm}(d,k)for _,v in pairs(d)do if type(v)=="\110\117\109\98\101\114"then `;
106-
_p += `${_v.out}=${_v.out}..${_v.char}(${_v.xor}(v,k))else local _="${_0xROASTS[Math.floor(Math.random()*_0xROASTS.length)]}" end end;`;
107-
_p += `local x=(loadstring or load)(${_v.out})if x then pcall(x)else warn("\80\79\66\70\85\83\95\70\65\84\65\76") end end;`;
62+
_p += `${_v.out}=${_v.out}..${_v.env}["\115\116\114\105\110\103"]["\99\104\97\114"](${_v.env}["\98\105\116\51\50"]["\98\120\111\114"](v,k))`;
63+
_p += `else local _="${_0xROASTS[1]}" end end;`;
64+
65+
// loadstring Gate
66+
_p += `local x,e=(loadstring or load)(${_v.out});if x then local s,m=pcall(x)if not s then warn("\80\79\66\70\85\83\95\82\85\78\84\73\77\69\95\69\82\82: "..tostring(m))end else warn("\80\79\66\70\85\83\95\86\77\95\69\82\82: "..tostring(e))end end;`;
10867
_p += `${_v.vm}(${_v.tab},${_k});`;
10968

110-
// Final Table Roast Termination
111-
_p += `local ${_0xBC(8)}={["\82\79\65\83\84"]="${_0xROASTS[1]}",["\74\85\78\75"]="${_0xSCREAM(200)}"};`;
112-
11369
_o.value = _p;
114-
_s.innerText = "POBFUS: COMPLETE";
70+
_s.innerText = "POBFUS_1.11.01: STABLE";
11571
document.getElementById('dl').style.display = 'inline-block';
11672

117-
} catch (e) {
118-
_s.innerText = "ENGINE_FATAL";
119-
} finally {
120-
_b.disabled = false;
121-
}
73+
} catch (e) { _s.innerText = "CRITICAL_COMPILER_FAILURE"; }
74+
finally { _b.disabled = false; }
75+
};
76+
77+
// Randomized Filename
78+
const _0xFILE = () => {
79+
const c = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#$%^&*";
80+
let r = "pobfus-";
81+
for(let i=0; i<25; i++) r += c.charAt(Math.floor(Math.random()*c.length));
82+
return r + ".lua";
12283
};
12384

124-
// UI Bindings
12585
document.getElementById('go').onclick = window.run;
86+
document.getElementById('cp').onclick = () => { document.getElementById('out').select(); document.execCommand('copy'); };
12687
document.getElementById('dl').onclick = () => {
127-
const _b = new Blob([document.getElementById('out').value], { type: 'text/plain' });
128-
const _a = document.createElement('a');
129-
_a.href = URL.createObjectURL(_b);
130-
_a.download = _0xFILE_GEN();
131-
_a.click();
88+
const a = document.createElement('a');
89+
a.href = URL.createObjectURL(new Blob([document.getElementById('out').value]));
90+
a.download = _0xFILE();
91+
a.click();
13292
};
13393
})(window);

0 commit comments

Comments
 (0)