Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

no-proxy

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

no-proxy

Determine if a url should bypass a proxy based on NO_PROXY environment variable.

  • 1.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

no-proxy

Test URL against NO_PROXY environment variable.

console.log(process.env.NO_PROXY); // ".foo.com,*.bar.com,10.*,192.168.1."

// requires protocol
var noProxy = require('no-proxy');
noProxy('http://foo.com/'); // true
noProxy('http://www.baz.com/'); // false

// check hostname part only
var noProxyHost = require('no-proxy/hostname');
noProxyHost('foo.com'); // true
noProxyHost('baz.com'); // false
noProxyHost('192.168.1.1'); // true

NOTE: You may want to use memoization around this module.

WARNING

If you are using a node version prior to Node 8, you need to install url-parse as a dependency.

FAQs

Package last updated on 17 Nov 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc