bryancall commented on issue #12082: URL: https://github.com/apache/trafficserver/issues/12082#issuecomment-4828271010
Thanks for the detailed report. After looking into this, the behavior is intentional and not something we can change. Apache Traffic Server uses header field-names that begin with `@` (for example `@Ats-Internal`) as a marker for internal headers, so the HTTP/1 field-name parser deliberately accepts `@`. This is documented right in the code: the parser unit test keeps `delimiter_@: 0` as a valid case with the note "Not allowed by the spec, but we use it as internal header indicator" (src/proxy/hdrs/unit_tests/test_Hdrs.cc), and the `@Ats-Internal` token is defined in src/proxy/hdrs/HdrToken.cc and wired up in src/proxy/hdrs/MIME.cc. Two pull requests that attempted exactly this change, [PR #12838](https://github.com/apache/trafficserver/pull/12838) and your [PR #12881](https://github.com/apache/trafficserver/pull/12881), were both closed for this reason: making the parser reject `@` would leave it unable to parse our own internal headers. Since this is by design and not a defect we plan to change, I am closing this issue. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
