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

[Just for Discussion] If re-define the console object, currently the tool cannot be practiced as the expected #69

Open
JerryWenlong opened this issue Aug 31, 2023 · 1 comment

Comments

@JerryWenlong
Copy link

Well, this is just for discussion.
The tool is amazing!

I research out that it relaies on the Console object, so here 's an unexpected scenarrio:

(I use Chrome)

The Steps:

  1. Open the browser (Chrome).
  2. Open the dev-tool firstly before we open the website.
  3. Click 'Sources' Tab, find the 'Event Listener Breakpoints' selectors on the right panel.
  4. Checked 'Script' - 'Script First Statement'
  5. Then we inject a scripts in the console drawer like:
Object.defineProperty(window, 'console', {
  value: {
      table: () => {},
      log: () => {},
      clear: () => {},
      debug: () => {},
      warn:() => {}
    }
});
  1. Then unchecked the 'Script' and resume the script running.

Hope we may find a way~

@theajack
Copy link
Owner

Thank you for your issue, but if the function of disable-devtool takes effect as expected, then others will not have the opportunity to redefine the console in the console.

However, there are still many solutions to bypass the restrictions of disable-devtool, such as disabling js, network packet capture, and using browser plug-ins to inject scripts. This is a limitation of web applications. We can only prevent it as much as possible.

@JerryWenlong

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

2 participants