Git Product home page Git Product logo

Comments (18)

sanex3339 avatar sanex3339 commented on May 24, 2024

Hi, very specific error with no message. I need demo which i can test and reproduce error. It can be only one component with this error. But this demo should be easy to install from my side.

But before that disable selfDefending and debugProtection options if they are were enabled.

from webpack-obfuscator.

LanderBeeuwsaert avatar LanderBeeuwsaert commented on May 24, 2024

Ok, will do that when I have the time (can take a while, sorry, if you want I can close the issue for now).

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

No, i won't close the issue, because the error is very interesting.

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

But now please try to disable selfDefending and debugProtection and domainLock options if they are were enabled.

from webpack-obfuscator.

LanderBeeuwsaert avatar LanderBeeuwsaert commented on May 24, 2024

ok, give me a week or something, I hope to have met my deadline by then and be able to setup a small demo.

from webpack-obfuscator.

LanderBeeuwsaert avatar LanderBeeuwsaert commented on May 24, 2024

Nope, not enabled, config is:

  new JavaScriptObfuscator ({
    rotateUnicodeArray: true
  }, [
    //Also about obfuscation of `vendors` and `polyfills`. I very very very recommend to always disable obfuscation of this files because obfuscated code
    // runs about 25-30% slower and size of obfuscated files larger. So, if you will obfuscate only your (not vendor) code
    // - performance drop will haven't so noticeable affects on code performance.
    //ALL FILES PRESENT BELOW WILL NOT BE OBFUSCATED
    '**/vendor.*.js',
    '**/polyfills.*.js',
    '**/assets/**',
    '**/main.*.js'// -> lijkt issues te geven momenteel, bij versie 0.8.0? Alleen met de staticBalanceSelector? Misschien iets met svg inline?...
  ]),

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

selfDefending is enabled by default. set it to false

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

default options is

{
    compact: true,
    debugProtection: false,
    debugProtectionInterval: false,
    disableConsoleOutput: true,
    reservedNames: [],
    rotateStringArray: true,
    selfDefending: true,
    sourceMap: false,
    sourceMapBaseUrl: '',
    sourceMapFileName: '',
    sourceMapMode: 'separate',
    stringArray: true,
    stringArrayEncoding: false,
    stringArrayThreshold: 0.8,
    unicdeEscapeSequence: true
}

from webpack-obfuscator.

LanderBeeuwsaert avatar LanderBeeuwsaert commented on May 24, 2024

Ahhhh, in the end it was the:
disableConsoleOutput: false which did it.

Is it the intention that the browser tab crashes (tried in chrome, ff, edge) when something (I was outputting some objects) is logged to the console?

Seems kinda harsh.

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

So, after you disable log of some objects crash is gone?

from webpack-obfuscator.

LanderBeeuwsaert avatar LanderBeeuwsaert commented on May 24, 2024

Ah that I didn’t test,

Just when setting the option: disableConsoleOutput: false the crash is gone.

Van: Timofey Kachalov [mailto:[email protected]]
Verzonden: zaterdag 19 november 2016 17:12
Aan: javascript-obfuscator/webpack-obfuscator [email protected]
CC: LanderBeeuwsaert [email protected]; Author [email protected]
Onderwerp: Re: [javascript-obfuscator/webpack-obfuscator] Possible inline svg issue (#9)

So, after you disable log of some objects crash is gone?


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub #9 (comment) , or mute the thread https://github.com/notifications/unsubscribe-auth/ABDCA2iYmCjm2QowOaWmu0KH_cbAVtuUks5q_x_GgaJpZM4K3R2_ . https://github.com/notifications/beacon/ABDCA98AzM9gZqF2q1obviXUIURSuU6Lks5q_x_GgaJpZM4K3R2_.gif

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

Interesting.

disableConsoleOutput option add additional node to obfuscated code:

var {consoleLogDisableFunctionName} = {singleNodeCallControllerFunctionName}(this, function () {
            var getGlobal = Function('return (function() ' + '{}.constructor("return this")( )' + ');');

            var func = Function('for ' + '(;;)' + ' {}');
            var that = getGlobal();

            that.console.log = func; 
            that.console.error = func;
            that.console.warn = func;
            that.console.info = func;
        });

        {consoleLogDisableFunctionName}();

As you can see, console.log and other functions is replaced by infinity loop function, so i think this is cause of the crash.

from webpack-obfuscator.

LanderBeeuwsaert avatar LanderBeeuwsaert commented on May 24, 2024

Haha, jep, that explains a lot.
I think it is firefox which after 20 seconds or so gives you the option to disable a script, because it is continually running, well, jep, a loop would do that ;-).

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

So, i think in 30 mins i make patch which will replace infinity loop by empty function, because many scripts has console.log

from webpack-obfuscator.

LanderBeeuwsaert avatar LanderBeeuwsaert commented on May 24, 2024

ok,cool, thanks, take your time, I've disabled the option so I'm ok for now...

from webpack-obfuscator.

LanderBeeuwsaert avatar LanderBeeuwsaert commented on May 24, 2024

Do I close? Or do you close later?

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

I will close later after patch release

from webpack-obfuscator.

sanex3339 avatar sanex3339 commented on May 24, 2024

Check [email protected], now when disableConsoleOutput option is enable, console.log will return nothing as expected from option name.

from webpack-obfuscator.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.