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

RenameIdentifier has bug for inner function declaration #1224

Open
hotdl opened this issue Dec 21, 2023 · 0 comments
Open

RenameIdentifier has bug for inner function declaration #1224

hotdl opened this issue Dec 21, 2023 · 0 comments

Comments

@hotdl
Copy link

hotdl commented Dec 21, 2023

Expected Behavior

Current Behavior

Steps to Reproduce

refer the example below,it should print 'inner true' after run the source code, but,
after obfuscating the code, it runs wrong for the inner function declaration's name has changed.

Your Environment

  • Obfuscator version used: 4.1.0
  • Node version used: v20.3.1

Stack trace

Minimal working example that will help to reproduce issue

function renameBugTest() {
    if (!![]) {
        function inner() {
            console.log('inner true');
        }
    } else {
        function inner() {
            console.log('inner false');
        }
    }
    inner();
}
renameBugTest();
function renameBugTest() {
    if (!![]) {
        function _0x38f3fd() {
            console['log']('inner\x20true');
        }
    } else {
        function _0x2d92f1() {
            console['log']('inner\x20false');
        }
    }
    inner();
}
renameBugTest();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant