HomePhorge

Strip port numbers from HTTP host headers before comparing them for cookie

Description

Strip port numbers from HTTP host headers before comparing them for cookie
purposes

Summary:
Browsers send port numbers (like ":443" or proxy ports) in the Host header and
we'll currently reject them with a message like:

Blah is configured on "x.y.com" but you are accessing it on "x.y.com:443".

Instead, examine only the host part.

Test Plan: Had my local listen on port 81 and accessed Phabricator before/after
the change; it now works without throwing.

Reviewers: jungejason, tuomaspelkonen, aran

Reviewed By: jungejason

CC: aran, epriestley, abdul, jungejason

Differential Revision: 841

Details

Provenance
epriestleyAuthored on Aug 20 2011, 1:55 PM
themackabuPushed on Mar 25 2025, 8:07 PM
Parents
rPc04805cde4a1: Open AphrontWriteGuard for user login
Branches
Unknown
Tags
Unknown

Event Timeline