.. _envoy_api_file_api/sds.proto: Common TLS configuration ======================== .. _envoy_api_msg_DataSource: DataSource ---------- `[DataSource proto] `_ .. code-block:: json { "filename": "..." } .. _envoy_api_field_DataSource.filename: filename (`string `_, *REQUIRED*) Local filesystem data source. Precisely one of :ref:`filename ` must be set. .. _envoy_api_msg_TlsParameters: TlsParameters ------------- `[TlsParameters proto] `_ .. code-block:: json { "tls_minimum_protocol_version": "...", "tls_maximum_protocol_version": "...", "cipher_suites": [], "ecdh_curves": [] } .. _envoy_api_field_TlsParameters.tls_minimum_protocol_version: tls_minimum_protocol_version (:ref:`TlsParameters.TlsProtocol `) Minimum TLS protocol version. .. _envoy_api_field_TlsParameters.tls_maximum_protocol_version: tls_maximum_protocol_version (:ref:`TlsParameters.TlsProtocol `) Maximum TLS protocol version. .. _envoy_api_field_TlsParameters.cipher_suites: cipher_suites (`string `_) If specified, the TLS listener will only support the specified `cipher list `_. If not specified, the default list: .. code-block:: none [ECDHE-ECDSA-AES128-GCM-SHA256|ECDHE-ECDSA-CHACHA20-POLY1305] [ECDHE-RSA-AES128-GCM-SHA256|ECDHE-RSA-CHACHA20-POLY1305] ECDHE-ECDSA-AES128-SHA256 ECDHE-RSA-AES128-SHA256 ECDHE-ECDSA-AES128-SHA ECDHE-RSA-AES128-SHA AES128-GCM-SHA256 AES128-SHA256 AES128-SHA ECDHE-ECDSA-AES256-GCM-SHA384 ECDHE-RSA-AES256-GCM-SHA384 ECDHE-ECDSA-AES256-SHA384 ECDHE-RSA-AES256-SHA384 ECDHE-ECDSA-AES256-SHA ECDHE-RSA-AES256-SHA AES256-GCM-SHA384 AES256-SHA256 AES256-SHA will be used. .. _envoy_api_field_TlsParameters.ecdh_curves: ecdh_curves (`string `_) If specified, the TLS connection will only support the specified ECDH curves. If not specified, the default curves (X25519, P-256) will be used. .. _envoy_api_enum_TlsParameters.TlsProtocol: Enum TlsParameters.TlsProtocol ------------------------------ `[TlsParameters.TlsProtocol proto] `_ .. _envoy_api_enum_value_TlsParameters.TlsProtocol.TLS_AUTO: TLS_AUTO *(DEFAULT)* ⁣Envoy will choose the optimal TLS version. .. _envoy_api_enum_value_TlsParameters.TlsProtocol.TLSv1_0: TLSv1_0 ⁣TLS 1.0 .. _envoy_api_enum_value_TlsParameters.TlsProtocol.TLSv1_1: TLSv1_1 ⁣TLS 1.1 .. _envoy_api_enum_value_TlsParameters.TlsProtocol.TLSv1_2: TLSv1_2 ⁣TLS 1.2 .. _envoy_api_enum_value_TlsParameters.TlsProtocol.TLSv1_3: TLSv1_3 ⁣TLS 1.3 .. _envoy_api_msg_TlsCertificate: TlsCertificate -------------- `[TlsCertificate proto] `_ .. code-block:: json { "certificate_chain": "{...}", "private_key": "{...}" } .. _envoy_api_field_TlsCertificate.certificate_chain: certificate_chain (:ref:`DataSource `) The TLS certificate chain. .. _envoy_api_field_TlsCertificate.private_key: private_key (:ref:`DataSource `) The TLS private key. .. _envoy_api_msg_TlsSessionTicketKeys: TlsSessionTicketKeys -------------------- `[TlsSessionTicketKeys proto] `_ .. code-block:: json { "keys": [] } .. _envoy_api_field_TlsSessionTicketKeys.keys: keys (:ref:`DataSource `, *REQUIRED*) Keys for encrypting and decrypting TLS session tickets. The first key in the array contains the key to encrypt all new sessions created by this context. All keys are candidates for decrypting received tickets. This allows for easy rotation of keys by, for example, putting the new key first, and the previous key second. If :ref:`session_ticket_keys ` is not specified, the TLS library will still support resuming sessions via tickets, but it will use an internally-generated and managed key, so sessions cannot be resumed across hot restarts or on different hosts. Each key must contain exactly 80 bytes of cryptographically-secure random data. For example, the output of ``openssl rand 80``. .. attention:: Using this feature has serious security considerations and risks. Improper handling of keys may result in loss of secrecy in connections, even if ciphers supporting perfect forward secrecy are used. See https://www.imperialviolet.org/2013/06/27/botchingpfs.html for some discussion. To minimize the risk, you must: * Keep the session ticket keys at least as secure as your TLS certificate private keys * Rotate session ticket keys at least daily, and preferably hourly * Always generate keys using a cryptographically-secure random data source .. _envoy_api_msg_CertificateValidationContext: CertificateValidationContext ---------------------------- `[CertificateValidationContext proto] `_ .. code-block:: json { "trusted_ca": "{...}", "verify_certificate_hash": [], "verify_subject_alt_name": [] } .. _envoy_api_field_CertificateValidationContext.trusted_ca: trusted_ca (:ref:`DataSource `) TLS certificate data containing certificate authority certificates to use in verifying a presented client side certificate. If not specified and a client certificate is presented it will not be verified. By default, a client certificate is optional, unless one of the additional options (:ref:`require_client_certificate `, :ref:`verify_certificate_hash `, or :ref:`verify_subject_alt_name `) is also specified. .. _envoy_api_field_CertificateValidationContext.verify_certificate_hash: verify_certificate_hash (`string `_) If specified, Envoy will verify (pin) the hex-encoded SHA-256 hash of the presented certificate. .. _envoy_api_field_CertificateValidationContext.verify_subject_alt_name: verify_subject_alt_name (`string `_) An optional list of subject alternative names. If specified, Envoy will verify that the certificate’s subject alternative name matches one of the specified values. .. _envoy_api_msg_CommonTlsContext: CommonTlsContext ---------------- `[CommonTlsContext proto] `_ TLS context shared by both client and server TLS contexts. .. code-block:: json { "tls_params": "{...}", "tls_certificates": [], "validation_context": "{...}", "alpn_protocols": [] } .. _envoy_api_field_CommonTlsContext.tls_params: tls_params (:ref:`TlsParameters `) TLS protocol versions, cipher suites etc. .. _envoy_api_field_CommonTlsContext.tls_certificates: tls_certificates (:ref:`TlsCertificate `) Multiple TLS certificates can be associated with the same context. E.g. to allow both RSA and ECDSA certificates, two TLS certificates can be configured. .. attention:: Although this is a list, currently only a single certificate is supported. This will be relaxed in the future. .. _envoy_api_field_CommonTlsContext.validation_context: validation_context (:ref:`CertificateValidationContext `) How to validate peer certificates. .. _envoy_api_field_CommonTlsContext.alpn_protocols: alpn_protocols (`string `_) Supplies the list of ALPN protocols that the listener should expose. In practice this is likely to be set to one of two values (see the :ref:`codec_type ` parameter in the HTTP connection manager for more information): * "h2,http/1.1" If the listener is going to support both HTTP/2 and HTTP/1.1. * "http/1.1" If the listener is only going to support HTTP/1.1. There is no default for this parameter. If empty, Envoy will not expose ALPN. .. _envoy_api_msg_UpstreamTlsContext: UpstreamTlsContext ------------------ `[UpstreamTlsContext proto] `_ .. code-block:: json { "common_tls_context": "{...}", "sni": "..." } .. _envoy_api_field_UpstreamTlsContext.common_tls_context: common_tls_context (:ref:`CommonTlsContext `) Common TLS context settings. .. _envoy_api_field_UpstreamTlsContext.sni: sni (`string `_) SNI string to use when creating TLS backend connections. .. _envoy_api_msg_DownstreamTlsContext: DownstreamTlsContext -------------------- `[DownstreamTlsContext proto] `_ .. code-block:: json { "common_tls_context": "{...}", "require_client_certificate": "{...}", "session_ticket_keys": "{...}" } .. _envoy_api_field_DownstreamTlsContext.common_tls_context: common_tls_context (:ref:`CommonTlsContext `) Common TLS context settings. .. _envoy_api_field_DownstreamTlsContext.require_client_certificate: require_client_certificate (`BoolValue `_) If specified, Envoy will reject connections without a valid client certificate. .. _envoy_api_field_DownstreamTlsContext.session_ticket_keys: session_ticket_keys (:ref:`TlsSessionTicketKeys `) TLS session ticket key settings. Only one of :ref:`session_ticket_keys ` may be set.