Getting started Community Training Tutorials Documentation APIs, AI & Tools
Transport Layer Security (TLS) - Outbound
Policy Name |
Transport Layer Security (TLS) - Outbound |
Summary |
Enables two-way authentication between the API proxy and an upstream service |
Category |
Security |
First Omni version available |
v1.4.0 |
Release Notes |
|
Returned Status Codes |
No return codes exist for this policy. |
|
The following document applies only to Omni Gateway running in Local Mode. To configure TLS in Connected Mode, see Configuring TLS Context for Omni Gateway in Connected Mode. |
The TLS outbound policy applies an outbound TLS or mTLS context to an upstream service in Local Mode. For how to apply the policy, and how to configure a default outbound TLS context for every HTTPS upstream service and outgoing policy request without its own TLS context, see Configuring TLS Context for Omni Gateway in Local Mode.
Apply outbound TLS contexts to each upstream service individually, because upstream services might require different certificates and CAs. If you don’t apply an outbound TLS context, the default outbound TLS context or the built-in outbound TLS applies. For upstream certificate requirements, see Certificate Requirements.
TLS policies don’t support policy ordering.
Refer to the following policy definition and table of parameters:
- policyRef:
name: tls-outbound
config:
skipValidation: <boolean> // REQUIRED
certificate: // OPTIONAL
key: <string> // REQUIRED
crt: <string> // REQUIRED
keyPassphrase: <string> // OPTIONAL
alpn: <array> // OPTIONAL
minversion: <string> // OPTIONAL
maxversion: <string> // OPTIONAL
ciphers: <array> // OPTIONAL
Not including optional parameters in your configuration file applies the parameters default values to your TLS context.
When configuring the ciphers parameter, ensure that your API upstream supports the listed ciphers. For the supported ciphers, see Supported TLS Versions and Ciphers.
| Parameter | Required or Optional | Default Value | Description |
|---|---|---|---|
|
Required |
false |
If true, the upstream certificate is not validated. |
|
Optional, unless |
N/A |
The CA used to validate the upstream server certificate. If no trusted CA is provided, the policy uses the default OS CA. If you provide a trusted CA, it replaces the default OS CA. Include the complete CA chain for the upstream. |
|
Optional |
N/A |
The client certificate to present for mTLS. To comply with security standards, all certificates must be 2048 bits or longer. |
|
Required if |
N/A |
The private key part of the certificate. |
|
Required if |
N/A |
The public key part of the certificate. |
|
Optional, unless the private key is encrypted |
N/A |
The passphrase that decrypts the private key. |
|
Optional |
|
A prioritized list of supported application level protocols; for example, h2, http/1.1, and so forth. |
|
Optional |
|
The minimum TLS version allowed. Supported values are |
|
Optional |
|
The maximum TLS version allowed. Supported values are |
|
Optional |
For the default and other supported ciphers, see Supported TLS Versions and Ciphers. |
A list of supported TLS ciphers (IANA format). |
You can format the YAML file to configure TLS or mTLS for a upstream service.
Sample configuration for adding outbound TLS context for a specific upstream service:
apiVersion: gateway.mulesoft.com/v1alpha1
kind: PolicyBinding
metadata:
name: tls-outbound
spec:
targetRef:
kind: Service
name: ingress-test-outbound-upstream
policyRef:
name: tls-outbound
config:
skipValidation: false
trustedCA: |
-----BEGIN CERTIFICATE-----
# insert the CA that signs the upstream server certificate
-----END CERTIFICATE-----
This example uses the default values for alpn, minversion, maxversion, and ciphers.
Sample configuration for adding outbound mTLS context for a specific upstream service:
apiVersion: gateway.mulesoft.com/v1alpha1
kind: PolicyBinding
metadata:
name: mtls-outbound
spec:
targetRef:
kind: Service
name: ingress-test-outbound-upstream
policyRef:
name: tls-outbound
config:
skipValidation: false
trustedCA: |
-----BEGIN CERTIFICATE-----
# insert the CA that signs the upstream server certificate
-----END CERTIFICATE-----
certificate:
key: |
-----BEGIN PRIVATE KEY-----
# insert private key
-----END PRIVATE KEY-----
crt: |
-----BEGIN CERTIFICATE-----
# insert certificate
-----END CERTIFICATE-----
alpn:
- http/1.1
- h2
minversion: "1.2"
maxversion: "1.3"
ciphers:
- TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
- TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256
- TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
- TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256
- TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384
- TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
Omni Gateway supports TLS 1.2 and TLS 1.3:
TLS 1.3: Omni Gateway always supports all TLS 1.3 ciphers. You can’t customize them.
TLS 1.2: Omni Gateway supports the default ciphers unless you customize them. In Secrets Manager, you add ciphers to the defaults. In a configuration file, the ciphers list replaces the defaults, so include every cipher that you want to support.
For outbound TLS, ensure that your upstream services support the TLS versions and ciphers that you configure.
| Cipher | TLS Version | Default | Advice |
|---|---|---|---|
|
1.3 |
Yes |
Secure |
|
1.3 |
Yes |
Secure |
|
1.3 |
Yes |
Secure |
|
1.2 |
Yes |
Recommended |
|
1.2 |
Yes |
Recommended |
|
1.2 |
Yes |
Recommended |
|
1.2 |
No |
Recommended |
|
1.2 |
Yes |
Secure |
|
1.2 |
Yes |
Secure |
|
1.2 |
Yes |
Secure |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |
|
1.2 |
No |
Weak |