trafficserver
trafficserver copied to clipboard
Fix handling of OPTIONS request
When I worked on #9094, I found that OPTIONS request (asterisk-form) is not handled correctly either.
HTTPHdr treats anything between request method and "HTTP/1.x" as URL, and it tries to parse the surrounded part by url_parse. When a request is asterisk-form (i.e. OPTIONS * HTTP/1.1) The parsing fails because "*" is not a valid URL.
This PR adds a special handling of asterisk-form. The change is small but it's a bit hacky, so I'm not going to strongly push this change and any feedback is welcome, but this allows users to proxy OPTIONS requests.