Skip to content

Do not include the port number in the Host #22

Description

@gajus

https://github.com/TooTallNate/node-https-proxy-agent/blob/6bbbef774527c8bdb5bf013d9ecc545ceaa7c974/https-proxy-agent.js#L192

This is making requests against multiple websites fail, e.g.

MacBook-Pro~ % curl 'http://www.watershed.co.uk/whatson/calendar/' -H 'Host: www.watershed.co.uk' -I
HTTP/1.1 200 OK
Date: Tue, 24 Jan 2017 21:44:16 GMT
Server: Apache/2.4.16 (FreeBSD) OpenSSL/1.0.1j-freebsd PHP/5.6.12
X-Powered-By: PHP/5.6.12
X-Drupal-Cache: MISS
Expires: Sun, 19 Nov 1978 05:00:00 GMT
Cache-Control: no-cache, must-revalidate, no-transform
X-Content-Type-Options: nosniff
Content-Language: en
X-Frame-Options: SAMEORIGIN
X-UA-Compatible: IE=edge
X-Generator: Drupal 7 (http://drupal.org)
Link: <http://www.watershed.co.uk/whatson/calendar>; rel="canonical",<http://www.watershed.co.uk/whatson/calendar>; rel="shortlink"
Vary: User-Agent
Content-Type: text/html; charset=utf-8

MacBook-Pro~ % curl 'http://www.watershed.co.uk/whatson/calendar/' -H 'Host: www.watershed.co.uk:80' -I
HTTP/1.1 404 Not Found
Date: Tue, 24 Jan 2017 21:44:26 GMT
Server: Apache/2.4.25 (FreeBSD) OpenSSL/1.0.1s-freebsd
Content-Type: text/html; charset=iso-8859-1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions