How to disable XHR messages finished loading in production

Asked

Viewed 334 times

4

I have a system developed in the Angular language in version 4. The system that generates build of the application in production is the webpack. This being used as the basis the following tarter: angular 4 webpack Starter The system is finished, but it has the following problem: XHR messages are showing up during calls and I want them disabled in production to hide the calls the application makes. inserir a descrição da imagem aqui

1 answer

1


Actually, this function is from the Chrome console, not Angular 4.

To disable it, open Developer tools in the console tab, click the options (gear) and uncheck the option LogXMLHttpRequests.

Remembering that, it is not possible to deny the browser the possibility of recording these requests logs.

inserir a descrição da imagem aqui

  • 1

    Yes, I understand that, but I want to get default disabled in production without the possibility of being enabled. It has like?

  • 1

    Unable, the browser needs to display the requests made.

  • There would be a way to encrypt what appears on the console about these requisitions. I wanted it to be hidden from the user to avoid hacking by the url, or something like that. It would be another way of security.

  • 1

    You can obfuscate your request scripts and do the URL access treatments from the backend, checking if the access is legitimate/authorized. Unfortunately I can’t help you much on this topic.

  • Blz. This gives me some ideas on how to solve. Vlww for tips.

  • Not at all! I recommend reading: https://stackoverflow.com/questions/5067439/obfuscating-ajax-post

Show 1 more comment

Browser other questions tagged

You are not signed in. Login or sign up in order to post.