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

Whitelist #2

Open
davedash opened this issue Aug 5, 2020 · 1 comment
Open

Whitelist #2

davedash opened this issue Aug 5, 2020 · 1 comment

Comments

@davedash
Copy link

davedash commented Aug 5, 2020

Would be nice if this could whitelist things. For example localhost.

@davedash
Copy link
Author

davedash commented Aug 6, 2020

I ended up adding the following to my setupTests.js which allowed local connections to proceed. It serves my purposes so I can use local servers without fear of network connections.

// Allow localhost connections.
mitm.on("connect", function(socket, opts) {
  if (opts.host == "127.0.0.1") socket.bypass()
})

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