Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename Variables breaks with statement #137

Open
MichaelXF opened this issue Aug 11, 2024 · 2 comments
Open

Rename Variables breaks with statement #137

MichaelXF opened this issue Aug 11, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@MichaelXF
Copy link
Owner

Config and Small code sample

Config:

{
  target: "node",
  renameVariables: true
}

Code:

var a = "Incorrect value";
with ({ a: "Correct Value" }) {
  console.log(a);
}

// "Correct Value"

Obfuscated Code:

var Tru_whk = "Incorrect value";
with ({ ["a"]: "Correct Value" }) {
  console["log"](Tru_whk);
}

// "Incorrect value"

Additional context

Might be easiest to disable renaming fully in with statements or not support it entirely. Since any object can be passed in, theres no way for the obfuscator to know if the name will be shadowed or not.

@MichaelXF MichaelXF added the bug Something isn't working label Aug 11, 2024
@Mrgaton
Copy link

Mrgaton commented Oct 11, 2024

But then sadly you have a bunch of __p_7812057763_flat___p_1597929504_dLR_4__JS_PREDICT____JS_PREDICT__

@Mrgaton
Copy link

Mrgaton commented Oct 19, 2024

@MichaelXF At leat can you make only rename confuser generated variables and only pre mangle my code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants