envoyproxy / envoy

Cloud-native high-performance edge/middle/service proxy
https://www.envoyproxy.io
Apache License 2.0
25.02k stars 4.82k forks source link

Host and Authority Headers RFC Compliance: Decode Percent-encoded UTF8 Characters #21306

Open ameily opened 2 years ago

ameily commented 2 years ago

Title: Host and Authority Headers RFC Compliance: Decode Percent-encoded UTF8 Characters

Description: While working on the unified header validation component (#20261), we found that the Host and Authority headers do not decode percent-encoded UTF8 characters, per the RFC spec.

Although the fix could be targeted for UHV, I wanted to register this issue with the community to get consensus on how percent-encoded characters should be handled within the H1 Host and H2 :authority headers. For now, we are only looking at the Host and :authority headers and not talking about URI or path normalization.

Some initial options after reading the RFCs, which could be implemented as new configuration settings:

Relevant Links:

ameily commented 2 years ago

CC @yanavlasov

MdSahil-oss commented 2 years ago

@snowp I would like to work on this issue