出于安全原因,Envoy将根据请求是内部请求还是外部请求来“清理”各种传入的HTTP Header,这些 Header 另作他用。清理操作取决于 Header,可能会添加,删除或修改。
最终,是将请求视为内部请求还是外部请求,由x-forwarded-for标头控制(请仔细阅读链接的部分,因为Envoy填充标头的方式很复杂,并取决于use_remote_address设置)
另外,internal_address_config设置可用于配置内部/外部确定。
Envoy可能会清理以下 Header:
- x-envoy-decorator-operation
- x-envoy-downstream-service-cluster
- x-envoy-downstream-service-node
- x-envoy-expected-rq-timeout-ms
- x-envoy-external-address
- x-envoy-force-trace
- x-envoy-internal
- x-envoy-ip-tags
- x-envoy-max-retries
- x-envoy-retry-grpc-on
- x-envoy-retry-on
- x-envoy-upstream-alt-stat-name
- x-envoy-upstream-rq-per-try-timeout-ms
- x-envoy-upstream-rq-timeout-alt-response
- x-envoy-upstream-rq-timeout-ms
- x-forwarded-client-cert
- x-forwarded-for
- x-forwarded-proto
- x-request-id