Please enable Javascript to view the contents

 ·  ☕ 2 分钟

config.core.v3.Http1ProtocolOptions

https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/protocol.proto#config-core-v3-http1protocoloptions

[config.core.v3.Http1ProtocolOptions proto]

1
2
3
4
5
6
7
8
9
{
  "allow_absolute_url": "{...}",
  "accept_http_10": "...",
  "default_host_for_http_10": "...",
  "header_key_format": "{...}",
  "enable_trailers": "...",
  "allow_chunked_length": "...",
  "override_stream_error_on_invalid_http_message": "{...}"
}
  • allow_absolute_url

    (BoolValue) Handle HTTP requests with absolute URLs in the requests. These requests are generally sent by clients to forward/explicit proxies. This allows clients to configure envoy as their HTTP proxy. In Unix, for example, this is typically done by setting the http_proxy environment variable.

  • accept_http_10

    (bool) Handle incoming HTTP/1.0 and HTTP 0.9 requests. This is off by default, and not fully standards compliant. There is support for pre-HTTP/1.1 style connect logic, dechunking, and handling lack of client host iff default_host_for_http_10 is configured.

  • default_host_for_http_10

    (string) A default host for HTTP/1.0 requests. This is highly suggested if accept_http_10 is true as Envoy does not otherwise support HTTP/1.0 without a Host header. This is a no-op if accept_http_10 is not true.

  • header_key_format

    (config.core.v3.Http1ProtocolOptions.HeaderKeyFormat) Describes how the keys for response headers should be formatted. By default, all header keys are lower cased.

config.core.v3.Http1ProtocolOptions.HeaderKeyFormat

1
2
3
4
{
  "proper_case_words": "{...}",
  "stateful_formatter": "{...}"
}
  • proper_case_words

    (config.core.v3.Http1ProtocolOptions.HeaderKeyFormat.ProperCaseWords) Formats the header by proper casing words: the first character and any character following a special character will be capitalized if it’s an alpha character. For example, “content-type” becomes “Content-Type”, and “foo$b#$are” becomes “Foo$B#$Are”. Note that while this results in most headers following conventional casing, certain headers are not covered. For example, the “TE” header will be formatted as “Te”.

    Precisely one of proper_case_words, stateful_formatter must be set.

  • stateful_formatter

    (config.core.v3.TypedExtensionConfig) Configuration for stateful formatter extensions that allow using received headers to affect the output of encoding headers. E.g., preserving case during proxying.

    Tip:
    This extension category has the following known extensions:
    envoy.http.stateful_header_formatters.preserve_case
    Precisely one of proper_case_words, stateful_formatter must be set.

分享

Mark Zhu
作者
Mark Zhu
An old developer