mikeal/request — Issue #153: Not issuing CONNECT to a HTTPS proxy
Author: david111
Created: 2012-01-12 18:53:39+00:00
State: open

Hi, this may be related to issue 152.

Also I have been sent here from npm as I originally filed an issue (https://github.com/isaacs/npm/issues/2026) there (as npm uses this module as http client). Now for the details :)

We have a working HTTP/HTTPS Squid 2.6 proxy. It appears (through a tcpdump) that when npm is attempting to contact the registry over https, it doesn't connect to the proxy using the CONNECT method, sending instead directly encrypted content, thus failing to open the connection, while our proxy only works this way (as described in http://wiki.squid-cache.org/Features/HTTPS, using eg. curl as https client)

Currently we use the http registry as a workaround, but how to get npm to use CONNECT?

OS is CentOS 5.7 i386.

$ npm -v
1.1.0-alpha-6
$ npm list -g
/usr/lib
└─┬ npm@1.1.0-alpha-6
├── abbrev@1.0.3
├── block-stream@0.0.4
├── fast-list@1.0.1
├── fstream@0.1.5
├── graceful-fs@1.1.1
├── inherits@1.0.0
├── ini@1.0.1
├─┬ minimatch@0.0.4
│ └── lru-cache@1.0.4
├── mkdirp@0.1.0
├── node-uuid@1.3.0
├── nopt@1.0.10
├── proto-list@1.0.0
├── request@2.2.0
├── rimraf@1.0.8
├── semver@1.0.12
├── slide@1.1.3
├── tar@0.1.7
└── which@1.0.2
$ node -v
v0.6.5