|
1 | 1 | # Programmable HTTP proxy server for Node.js
|
2 | 2 |
|
3 | 3 | [](http://badge.fury.io/js/proxy-chain)
|
4 |
| -[](https://travis-ci.com/apify/proxy-chain) |
5 | 4 |
|
6 |
| -Node.js implementation of a proxy server (think Squid) with support for SSL, authentication, upstream proxy chaining, |
7 |
| -custom HTTP responses and measuring traffic statistics. |
8 |
| -The authentication and proxy chaining configuration is defined in code and can be dynamic. |
9 |
| -Note that the proxy server only supports Basic authentication |
10 |
| -(see [Proxy-Authorization](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Proxy-Authorization) for details). |
| 5 | +A programmable proxy server (think Squid) with support for SSL/TLS, authentication, upstream proxy chaining, |
| 6 | +custom HTTP responses, and traffic statistics. |
| 7 | +The authentication and proxy chaining configuration is defined in code and can be fully dynamic, giving you a high level of customization for your use case. |
11 | 8 |
|
12 |
| -For example, this package is useful if you need to use proxies with authentication |
13 |
| -in the headless Chrome web browser, because it doesn't accept proxy URLs such as `http://username:[email protected]:8080`. |
14 |
| -With this library, you can set up a local proxy server without any password |
| 9 | +For example, the proxy-chain package is useful if you need to use headless Chrome web browser and proxies with authentication, |
| 10 | +because Chrome doesn't support proxy URLs with password, such as `http://username:[email protected]:8080`. |
| 11 | +With this package, you can set up a local proxy server without any password |
15 | 12 | that will forward requests to the upstream proxy with password.
|
16 |
| -The package is used for this exact purpose by the [Apify web scraping platform](https://www.apify.com). |
| 13 | +For details, read [How to make headless Chrome and Puppeteer use a proxy server with authentication](https://blog.apify.com/how-to-make-headless-chrome-and-puppeteer-use-a-proxy-server-with-authentication-249a21a79212/). |
17 | 14 |
|
18 |
| -To learn more about the rationale behind this package, |
19 |
| -read [How to make headless Chrome and Puppeteer use a proxy server with authentication](https://medium.com/@jancurn/how-to-make-headless-chrome-and-puppeteer-use-a-proxy-server-with-authentication-249a21a79212). |
| 15 | +The proxy-chain package was developed by [Apify](https://apify.com/), the full-stack web scraping and data extraction platform, to support their [Apify Proxy](https://apify.com/proxy) product, |
| 16 | +which provides an easy access to a large pool of datacenter and residential proxies around the world. The proxy-chain package is also used by [Crawlee](https://crawlee.dev/), |
| 17 | +the world's most popular web craling library for Node.js. |
| 18 | + |
| 19 | +Note that the proxy-chain package currently only supports HTTP proxying and HTTP CONNECT tunneling to proxy arbitrary protocols such as HTTP/TLS or FTP ([learn more](https://blog.apify.com/tunneling-arbitrary-protocols-over-http-proxy-with-static-ip-address-b3a2222191ff)). The SOCKS protocol is not supported yet. |
| 20 | +Also, proxy-chain only supports the Basic [Proxy-Authorization](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Proxy-Authorization). |
20 | 21 |
|
21 | 22 | ## Run a simple HTTP/HTTPS proxy server
|
22 | 23 |
|
|
0 commit comments