This is an automated email from the ASF dual-hosted git repository.

Gabriel39 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris-website.git


The following commit(s) were added to refs/heads/master by this push:
     new 690cf0f2bd5 [docs](security) Document internal RPC mutual TLS (#4666)
690cf0f2bd5 is described below

commit 690cf0f2bd52f1d8b8ac50aaea0e1e002881b247
Author: Gabriel <[email protected]>
AuthorDate: Tue Nov 24 14:35:29 2026 +0800

    [docs](security) Document internal RPC mutual TLS (#4666)
    
    ## Summary
    
    Add an English and Chinese operator guide for mutual TLS on supported
    internal FE/BE RPC channels. The guide covers node-specific
    certificate/CSR provisioning, complete FE/BE configurations, protocol
    and trust boundaries, coordinated activation and rollback, certificate
    probes, configuration defaults and constraints, certificate/CA renewal,
    remote Doris compatibility, and troubleshooting.
    
    Link the guide from the current security overview, TLS framework
    reference, and Encryption in Transit sidebar.
    
    ## Availability and version scope
    
    Internal RPC mutual TLS is supported starting from Apache Doris 5.0.
    Only Dev/current is updated because the feature is not available in 4.x
    or 3.x. English and Chinese version wording, examples and configuration
    blocks are aligned. The TLS framework itself remains documented as
    available since 4.1.4.
    
    ## Validation
    
    - Certificate/CSR and CA-signing commands executed with temporary test
    identities; server/client usages, DNS/IP SANs, PKCS#8 format and
    private-key permissions verified.
    - Real local TLS probe succeeds with a trusted client identity;
    missing/untrusted client certificates and an incorrect server hostname
    are rejected. The listener is an OpenSSL test server; no new Doris
    runtime acceptance is claimed here. Temporary credentials and the
    listener are removed after the checks.
    - New guides pass front matter, Markdown structure, feature-section,
    internal-link and SEO checks. The complete changed-file governance
    report has no errors; remaining notices are the Dev-only version scope,
    verified external PR links, and unchanged SEO/sidebar-parser warnings in
    existing pages.
    - The initial complete Dev/current site build passed in English and
    Chinese. The version-only follow-up passes Markdown compilation and
    structure checks for all six edited pages; code blocks and navigation
    targets are unchanged.
    - Rendered output verification passes for both guides: localized title
    and content, six example blocks per language, canonical URLs, heading
    anchors, sidebar entries, links from the security overview and TLS
    framework, and the return link to the framework.
    - Full staged-diff self-review and sensitive-content checks completed
    before commit. No runtime code, real credentials, private keys or
    environment-specific endpoints are added.
    
    ## Versions
    
    - [x] dev
    - [ ] 4.x
    - [ ] 3.x
    - [ ] 2.1 or older (not covered by version/language sync gate)
    
    ## Languages
    
    - [x] Chinese
    - [x] English
    
    ## Docs Checklist
    
    - [x] Checked by AI
    - [x] Test Cases Built (documentation examples and static-site
    validation)
    - [x] Updated required version and language counterparts, or explained
    why not
    - [x] If only one language changed, confirmed whether source/translation
    counterparts need sync
---
 docs/admin-manual/auth/private-rpc-tls.md          | 208 +++++++++++++++++++++
 docs/admin-manual/auth/security-overview.md        |   2 +
 docs/admin-manual/auth/tls-framework.md            |   4 +-
 .../current/admin-manual/auth/private-rpc-tls.md   | 208 +++++++++++++++++++++
 .../current/admin-manual/auth/security-overview.md |   2 +
 .../current/admin-manual/auth/tls-framework.md     |   4 +-
 sidebars.ts                                        |   1 +
 7 files changed, 427 insertions(+), 2 deletions(-)

diff --git a/docs/admin-manual/auth/private-rpc-tls.md 
b/docs/admin-manual/auth/private-rpc-tls.md
new file mode 100644
index 00000000000..d13d43767cf
--- /dev/null
+++ b/docs/admin-manual/auth/private-rpc-tls.md
@@ -0,0 +1,208 @@
+---
+{
+    "title": "Internal RPC Encryption with Mutual TLS",
+    "language": "en",
+    "description": "Configure mutual TLS for Doris internal RPC: prepare node 
certificates, enable FE/BE encryption, verify connections, and rotate 
certificates safely.",
+    "keywords": ["Doris internal RPC", "mutual TLS", "mTLS", "FE BE 
encryption", "TLS certificates"],
+    "doc_type": "feature"
+}
+---
+
+<!-- Knowledge type: Deployment guide / Configuration reference -->
+<!-- Applicable scenarios: Internal RPC encryption / Node certificate 
authentication -->
+
+## Overview
+
+Use mutual TLS (mTLS) to encrypt supported internal RPC connections and 
require both peers to present certificates signed by the cluster's trusted 
certificate authority (CA). The open-source private RPC provider covers 
gRPC/BRPC and blocking Thrift connections. It does not fall back to plaintext 
after a TLS connection fails.
+
+:::note Availability
+Internal RPC mutual TLS is supported starting from Apache Doris 5.0. This 
guide applies to 5.0 and later versions.
+:::
+
+### Protocol coverage
+
+| Connection | Behavior with the configuration in this guide |
+| --- | --- |
+| FE gRPC to BE BRPC, including fragment dispatch | mTLS. FE verifies the 
server certificate chain and target hostname/IP. |
+| Internal native BRPC, including BE-to-BE connections | mTLS. Native BRPC 
verifies the CA chain, without a per-node hostname or role allowlist. |
+| Blocking Thrift between Doris nodes, including backend/heartbeat RPC and 
BE-to-FE lazy split fetching | mTLS. Clients verify the server certificate 
chain and target hostname/IP. |
+| MySQL, HTTP/HTTPS, Arrow Flight, FE BDBJE replication | Excluded by this 
guide's configuration. Their security must be configured separately. |
+| Broker RPC, RPC functions, and remote Doris endpoints | Keep their existing 
external connection policy. Local private RPC TLS does not enable encryption 
for these endpoints. |
+| Cloud Meta Service/Recycler and other control-plane transports | Not 
comprehensively covered by this provider. |
+
+Server listeners admit peers belonging to the configured CA trust domain. Use 
a **dedicated cluster CA**: any certificate issued by that CA is a cluster RPC 
credential. TLS protects data in transit; it does not encrypt stored data or 
process memory. Encrypted Iceberg reads additionally require their own reader 
support and capability checks.
+
+## Quick Start
+
+### Prerequisites
+
+- Install Apache Doris 5.0 or later FE and BE packages on every participating 
node.
+- Reserve a maintenance window. Plaintext nodes cannot communicate with TLS 
listeners; this provider does not support a mixed plaintext/TLS rolling 
transition.
+- Obtain a PEM CA certificate and a separate PEM certificate/private key for 
each node. Certificates must support both `serverAuth` and `clientAuth`, and 
contain DNS/IP Subject Alternative Names (SANs) matching the addresses peers 
actually use. If Doris registers or connects to a node by IP, include that IP 
as an IP SAN.
+- Keep the CA private key on the signing system, outside Doris nodes. Give the 
Doris service account read access to its own identity files, and restrict 
private-key access to that account.
+- Use blocking FE Thrift, preferably the default `THREAD_POOL`. 
`THREADED_SELECTOR` is unsupported for this TLS implementation.
+
+### 1. Prepare node certificates
+
+Use your organization's certificate issuance process. The following example 
creates a private key and certificate signing request (CSR) for one example BE. 
Run it in a new, protected directory on that node, and replace the example DNS 
name and IP with the node's actual identity. Repeat with distinct keys and 
names for every FE and BE.
+
+```bash
+umask 077
+cat > node.cnf <<'EOF'
+[req]
+prompt = no
+distinguished_name = dn
+req_extensions = node_cert
+[dn]
+CN = be1.example.com
+[node_cert]
+basicConstraints = critical,CA:FALSE
+keyUsage = critical,digitalSignature,keyEncipherment
+extendedKeyUsage = serverAuth,clientAuth
+subjectAltName = @names
+[names]
+DNS.1 = be1.example.com
+IP.1 = 192.0.2.10
+EOF
+openssl genpkey -algorithm RSA -pkeyopt rsa_keygen_bits:3072 -out node-key.pem
+openssl req -new -key node-key.pem -out node.csr -config node.cnf
+```
+
+Expected result: an unencrypted PKCS#8 PEM private key `node-key.pem` and a 
CSR `node.csr`. Send only the CSR and requested certificate extensions to the 
CA operator. Do not send the node private key.
+
+If the CA operator uses OpenSSL, an example signing command on the **CA 
system** is:
+
+```bash
+openssl x509 -req -in node.csr -CA cluster-ca.pem -CAkey cluster-ca-key.pem \
+    -CAcreateserial -out node-cert.pem -days 365 -sha256 \
+    -extfile node.cnf -extensions node_cert
+```
+
+Use your PKI's validity and serial-number policies. Expected result: 
`node-cert.pem` signed by the dedicated cluster CA, with the requested SANs and 
both extended key usages. Return that certificate and the public CA certificate 
to the node. If intermediate CAs are used, supply the required certificate 
chain and trust bundle. The CA private key stays on the CA system.
+
+### 2. Configure FE
+
+On each FE, add the following to `conf/fe.conf`. Replace the placeholder paths 
with absolute paths readable by that FE's service account, pointing to that 
FE's own certificate and key.
+
+```properties
+enable_tls=true
+tls_verify_mode=verify_fail_if_no_peer_cert
+tls_certificate_path=/path/to/fe-cert.pem
+tls_private_key_path=/path/to/fe-key.pem
+tls_ca_certificate_path=/path/to/cluster-ca.pem
+tls_cert_refresh_interval_seconds=0
+tls_excluded_protocols=http,mysql,arrowflight,bdbje
+thrift_server_type=THREAD_POOL
+thrift_rpc_connect_timeout_ms=10000
+```
+
+Leave `tls_peer_cert_required_san_dns` empty. This example uses an unencrypted 
private key; FE also supports its existing `tls_private_key_password` setting 
for a supported encrypted PEM key.
+
+### 3. Configure BE
+
+On each BE, add the following to `conf/be.conf`, using that BE's own 
certificate and key:
+
+```properties
+enable_tls=true
+tls_verify_mode=verify_fail_if_no_peer_cert
+tls_certificate_path=/path/to/be-cert.pem
+tls_private_key_path=/path/to/be-key.pem
+tls_ca_certificate_path=/path/to/cluster-ca.pem
+tls_cert_refresh_interval_seconds=0
+tls_excluded_protocols=http,arrowflight
+thrift_server_type_of_fe=THREAD_POOL
+thrift_connect_timeout_seconds=3
+```
+
+BE requires an **unencrypted PEM private key**. Leave both 
`tls_private_key_password` and `tls_peer_cert_required_san_dns` empty. The BE's 
`thrift_server_type_of_fe` must match the FE Thrift server mode.
+
+The excluded-protocol lists are necessary for this private-RPC-only 
deployment: enabling the unified framework also selects protocols not 
explicitly excluded. Do not remove exclusions unless you have a working TLS 
implementation and deployment plan for those protocols.
+
+### 4. Activate and validate
+
+1. Stop new workload submissions and drain or stop active work for the 
maintenance window. Back up the original node configurations.
+2. Deploy the identity files and TLS settings to all participating FE and BE 
nodes. Stop the old processes and start the cluster with the new settings using 
your normal cluster lifecycle procedure. Do not leave plaintext peers running 
against TLS listeners.
+3. Connect through the existing SQL endpoint and run `SHOW FRONTENDS;` and 
`SHOW BACKENDS;`. Expected result: the intended nodes become alive and 
heartbeats recover.
+4. Run a representative query that dispatches to BEs, a query with a cross-BE 
exchange, and a load operation. Expected result: they complete successfully 
without TLS/authentication errors. A client-only `SELECT 1` does not exercise 
these internal paths.
+5. Perform the certificate and connection checks in [Examples](#examples). 
Certificate rejection tests should use separate probe clients, without 
replacing a running node's identity.
+
+## Parameters
+
+The [TLS framework reference](./tls-framework.md) describes the shared 
configuration contract. The following table gives the additional constraints of 
this open-source private RPC implementation. `Empty` means an empty string. TLS 
identity settings are startup settings; changing files or configuration 
requires a restart.
+
+| Configuration | Type / component | Default | Required value or effect for 
this deployment |
+| --- | --- | --- | --- |
+| `enable_tls` | Boolean / FE, BE | `false` | Set to `true` on all 
participating nodes. |
+| `tls_verify_mode` | String / FE, BE | `verify_peer` | Must be 
`verify_fail_if_no_peer_cert`; optional client certificates and verification 
bypasses are rejected. |
+| `tls_certificate_path` | String / FE, BE | Empty | Required PEM node 
certificate, with the necessary chain. |
+| `tls_private_key_path` | String / FE, BE | Empty | Required matching PEM 
private key. |
+| `tls_ca_certificate_path` | String / FE, BE | Empty | Required PEM cluster 
CA certificate or trust bundle; do not rely on system/JDK default trust stores. 
|
+| `tls_private_key_password` | String / FE, BE | Empty | BE requires empty. FE 
supports its existing password setting for supported encrypted PEM keys. |
+| `tls_cert_refresh_interval_seconds` | Integer / FE, BE | `3600` | Must 
explicitly be `0`. Automatic certificate reload is unsupported. |
+| `tls_excluded_protocols` | String / FE, BE | Empty | FE: 
`http,mysql,arrowflight,bdbje`. BE: `http,arrowflight`. Keep `brpc` and 
`thrift` included for the internal channels covered here. |
+| `tls_peer_cert_required_san_dns` | String / FE, BE | Empty | Must remain 
empty. This provider does not implement the framework's DNS SAN admission 
allowlist. |
+| `thrift_server_type` | String / FE | `THREAD_POOL` | Use blocking 
`THREAD_POOL` or `SIMPLE`; do not use `THREADED_SELECTOR`. |
+| `thrift_server_type_of_fe` | String / BE | `THREAD_POOL` | Match the FE 
Thrift mode. |
+| `thrift_rpc_connect_timeout_ms` | Integer / FE | `10000` | Must be positive. 
Bounds Thrift TLS authentication even when ordinary RPC reads have no timeout. |
+| `thrift_connect_timeout_seconds` | Integer / BE | `3` | Must be positive and 
representable in milliseconds. Bounds Thrift TLS authentication. |
+
+`tls_cert_based_auth_ignore_password` is unrelated to node RPC authentication. 
Keep its default `false`; enabling internal mTLS does not change SQL user 
authentication.
+
+## Examples
+
+### Validate an issued certificate
+
+Before deployment, validate the CA chain, both usages, and the address used to 
reach the node:
+
+```bash
+openssl verify -CAfile cluster-ca.pem -purpose sslserver node-cert.pem
+openssl verify -CAfile cluster-ca.pem -purpose sslclient node-cert.pem
+openssl x509 -in node-cert.pem -noout -checkhost be1.example.com
+openssl x509 -in node-cert.pem -noout -checkip 192.0.2.10
+```
+
+Expected result: both verification commands report `node-cert.pem: OK`, and 
the hostname/IP checks report a match. Adapt the checks to the SANs you 
requested. For intermediate CAs, provide the intermediate chain as required by 
your PKI.
+
+### Probe a Thrift TLS listener
+
+From an authorized node or diagnostic host holding its own cluster-issued 
identity, probe the FE Thrift endpoint. The example uses the default FE 
`rpc_port` of `9020`; substitute the configured hostname and port.
+
+```bash
+openssl s_client -connect fe1.example.com:9020 -servername fe1.example.com \
+    -CAfile cluster-ca.pem -cert node-cert.pem -key node-key.pem \
+    -verify_hostname fe1.example.com -verify_return_error -brief < /dev/null
+```
+
+Expected result: TLS negotiation succeeds and certificate verification reports 
`OK`. This checks TLS authentication, not a Thrift application request. Repeat 
against the BE backend and heartbeat Thrift listeners (default ports `9060` and 
`9050`) with their corresponding names.
+
+For a target addressed by IP, replace `-verify_hostname fe1.example.com` with 
`-verify_ip` followed by that IP. The certificate must have the matching IP SAN.
+
+A separate probe without a client certificate, or with a certificate signed by 
an unrelated CA, must fail authentication. A trusted certificate with the wrong 
target hostname/IP must be rejected by hostname-verifying clients. Native BRPC 
authenticates the CA trust domain and does not perform the latter hostname 
check.
+
+### Retain remote Doris reads
+
+When using a remote Doris Catalog, keep the catalog property 
`use_arrow_flight=true` (the default). Remote results then enter local workers, 
keeping query exchanges and execution-status reports within the local TLS 
cluster. With private BRPC or Thrift TLS enabled, `use_arrow_flight=false` 
execution graphs that assign workers to the remote cluster are rejected before 
dispatch, including remote-only graphs with reverse callbacks.
+
+Remote metadata access and tablet writes executed by local workers retain 
their external connection policy. File-key descriptors cannot be sent over 
those remote plaintext channels. Local private TLS does not establish trust 
with, or configure TLS on, an independent remote cluster.
+
+## Error Handling
+
+| Symptom | Check and action |
+| --- | --- |
+| Startup reports that a TLS module is required | Confirm that FE and BE both 
contain the private RPC implementation. Check the excluded-protocol lists: the 
built-in provider does not supply every public protocol. |
+| Configuration is rejected for mutual authentication | Set 
`tls_verify_mode=verify_fail_if_no_peer_cert` and provide readable certificate, 
matching key, and CA files. |
+| Configuration is rejected for static identities or CA-scoped trust | Set the 
refresh interval to `0`, clear `tls_peer_cert_required_san_dns`, and clear the 
BE private-key password. |
+| Thrift cannot start | Use a supported blocking server mode, match FE/BE 
Thrift mode settings, and keep connection timeouts positive. |
+| Heartbeats, dispatch, or queries fail after activation | Check for plaintext 
peers, inconsistent CA bundles, expired certificates, missing client/server 
usages, hostname/IP SAN mismatches, unreadable files, or certificate/key 
mismatches. |
+| A connection attempt times out | Check reachability and the peer's TLS 
configuration. Thrift authentication uses a bounded timeout; an open TCP port 
alone does not prove successful authentication. |
+| Replacing certificate files has no effect | Restart affected processes. The 
provider has no automatic reload. |
+| Remote Doris direct execution is rejected | Retain the default Arrow Flight 
catalog mode; local TLS identities cannot authenticate independently scheduled 
remote workers. |
+
+## Best Practices
+
+- Generate a distinct private key on each node and have its certificate signed 
by a dedicated cluster CA. Never share that CA with unrelated services. The CA 
trust domain defines the cluster membership boundary; it does not provide 
per-node role policies.
+- Restrict private-key files to the Doris service account. Distribute only 
public CA certificates to nodes; never copy the CA private key there.
+- Monitor certificate expiration. For certificate renewal under the same 
trusted CA, install the new node identity and restart the affected process 
through your established availability procedure. Revalidate internal RPC after 
the restart.
+- For CA replacement, first deploy a trust bundle containing both old and new 
CAs and restart the relevant nodes. Then replace node identities and restart 
them, validate connectivity, and finally remove the old CA and restart again. 
Keep every communication path mutually trusted throughout the change.
+- To return to plaintext, coordinate another maintenance window and disable 
TLS consistently across participating nodes. There is no automatic plaintext 
fallback.
+- Protect process memory and crash artifacts separately. Internal transport 
encryption does not remove plaintext secrets from the processes that use them.
diff --git a/docs/admin-manual/auth/security-overview.md 
b/docs/admin-manual/auth/security-overview.md
index 93ab45d5942..e33d439e12a 100644
--- a/docs/admin-manual/auth/security-overview.md
+++ b/docs/admin-manual/auth/security-overview.md
@@ -21,6 +21,7 @@ Apache Doris provides complete security capabilities for 
enterprise-grade data p
 | Unified authorization governance with the big data ecosystem | Apache Ranger 
integration | [Ranger-based authorization](./authorization/ranger) |
 | Sensitive data protection (row-level/column-level, masking) | Data access 
control | [Data access control](./authorization/data) |
 | Encrypting the client-to-FE link | MySQL protocol SSL, FE HTTPS | [MySQL 
protocol SSL](./certificate), [FE HTTPS configuration](./fe-certificate) |
+| Encrypting supported internal FE/BE RPC (Doris 5.0+) | Node certificate 
authentication, gRPC/BRPC and blocking Thrift mTLS | [Internal RPC encryption 
with mutual TLS](./private-rpc-tls.md) |
 | Audit and compliance traceability | Audit log | [Audit log](../audit-plugin) 
|
 | Data encryption and decryption | Encryption functions | [Data encryption 
functions](./encryption-function) |
 | Deployment on AWS, integration with IAM | AWS authentication and 
authorization | [AWS authentication and 
authorization](./integrations/aws-authentication-and-authorization) |
@@ -112,5 +113,6 @@ Refer to the following documents by topic for details on 
Doris security capabili
 | Audit log | [Audit log](../audit-plugin) |
 | MySQL protocol SSL transport encryption | [MySQL protocol 
SSL](./certificate) |
 | FE HTTP/HTTPS transport encryption | [FE HTTPS 
configuration](./fe-certificate) |
+| Internal FE/BE RPC mutual TLS (Doris 5.0+) | [Internal RPC encryption with 
mutual TLS](./private-rpc-tls.md) |
 | Encryption functions | [Data encryption functions](./encryption-function) |
 | Integration with cloud vendors (AWS) | [AWS authentication and 
authorization](./integrations/aws-authentication-and-authorization) |
diff --git a/docs/admin-manual/auth/tls-framework.md 
b/docs/admin-manual/auth/tls-framework.md
index 395b9f863ba..c312e55a4a9 100644
--- a/docs/admin-manual/auth/tls-framework.md
+++ b/docs/admin-manual/auth/tls-framework.md
@@ -24,6 +24,8 @@ This framework is available starting from Apache Doris 4.1.4. 
These unified TLS
 
 The open-source Doris package contains the framework, configuration items, 
parser support, and extension points for TLS and certificate-based 
authentication. It does not include a complete TLS runtime implementation for 
every protocol. In the stock open-source build, enabling TLS for a protocol 
that has no TLS module implementation will fail with an error indicating that 
the TLS module is required.
 
+Starting from Apache Doris 5.0, the open-source build provides built-in mutual 
TLS for internal gRPC/BRPC and blocking Thrift. See [Internal RPC encryption 
with mutual TLS](./private-rpc-tls.md) for certificate provisioning, required 
configuration overrides, coordinated activation, and protocol limits.
+
 The configuration names, default values, and meanings listed below are fixed 
by the framework. If you provide your own TLS module implementation, use this 
framework and these configuration items for compatibility. Implementation 
details such as certificate loading, TLS context creation, handshake behavior, 
certificate reload, and protocol-specific peer verification can be implemented 
by the TLS module.
 
 ## Configuration Reference
@@ -55,7 +57,7 @@ All options below are optional and use the listed defaults. 
Set them in FE `fe.c
 
 The open-source framework provides configuration definitions and extension 
points, and the default providers keep the existing plaintext behavior when 
`enable_tls` is `false`.
 
-When `enable_tls` is `true`, protocol startup or channel creation is routed 
through the TLS framework. If the corresponding TLS module is not provided, the 
open-source default implementation rejects TLS startup for that protocol and 
reports that the TLS module is required.
+When `enable_tls` is `true`, protocol startup or channel creation is routed 
through the TLS framework. A build containing the built-in private RPC provider 
can serve its supported internal protocols. If a selected protocol has no 
corresponding TLS implementation, the open-source default implementation 
rejects TLS startup for that protocol and reports that the TLS module is 
required.
 
 This means the table above is a compatibility contract, not a complete 
operational guide for enabling TLS in the stock open-source package.
 
diff --git 
a/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/private-rpc-tls.md
 
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/private-rpc-tls.md
new file mode 100644
index 00000000000..a9b15886844
--- /dev/null
+++ 
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/private-rpc-tls.md
@@ -0,0 +1,208 @@
+---
+{
+    "title": "使用双向 TLS 加密内部 RPC",
+    "language": "zh-CN",
+    "description": "介绍 Apache Doris 内部 RPC 双向 TLS 的完整部署流程,包括节点证书签发、FE/BE 
配置、维护窗口切换、连接验证、证书轮换,以及协议覆盖范围、远端 Doris 兼容性和常见故障排查。",
+    "keywords": ["Doris 内部 RPC", "双向 TLS", "mTLS", "FE BE 通信加密", "TLS 证书"],
+    "doc_type": "feature"
+}
+---
+
+<!-- Knowledge type: Deployment guide / Configuration reference -->
+<!-- Applicable scenarios: Internal RPC encryption / Node certificate 
authentication -->
+
+## 概述
+
+双向 TLS(mTLS)为支持的内部 RPC 连接提供传输加密,并要求通信双方出示由集群信任的证书颁发机构(CA)签发的证书。开源内部 RPC 
provider 覆盖 gRPC/BRPC 和阻塞式 Thrift 连接,TLS 连接失败后不会回退到明文。
+
+:::note 可用性
+内部 RPC 双向 TLS 自 Apache Doris 5.0 起支持,本文适用于 5.0 及后续版本。
+:::
+
+### 协议覆盖范围
+
+| 连接 | 使用本文配置后的行为 |
+| --- | --- |
+| FE gRPC 到 BE BRPC,包括 fragment 下发 | mTLS。FE 校验服务端证书链和目标主机名/IP。 |
+| 集群内部原生 BRPC,包括 BE 之间的连接 | mTLS。原生 BRPC 校验 CA 证书链,不提供逐节点主机名或角色准入列表。 |
+| Doris 节点间的阻塞式 Thrift,包括 backend/heartbeat RPC 和 BE 到 FE 的延迟 split 获取 | 
mTLS。客户端校验服务端证书链和目标主机名/IP。 |
+| MySQL、HTTP/HTTPS、Arrow Flight、FE BDBJE 复制 | 被本文配置排除,需要单独配置对应协议的安全能力。 |
+| Broker RPC、RPC 函数、远端 Doris 端点 | 保持原有外部连接策略。本地内部 RPC TLS 不会为这些端点开启加密。 |
+| Cloud Meta Service/Recycler 及其他控制面通道 | 此 provider 不提供全面覆盖。 |
+
+服务端允许属于所配置 CA 信任域的对端接入。应使用**集群专用 CA**:该 CA 签发的任何证书都是集群 RPC 凭据。TLS 
保护传输中的数据,不会加密已存储数据或进程内存。读取加密 Iceberg 表还需要相应的 reader 支持和能力检查。
+
+## 快速开始
+
+### 前置条件
+
+- 所有参与节点安装 Apache Doris 5.0 或后续版本的 FE、BE 安装包。
+- 安排维护窗口。明文节点无法与 TLS 监听端通信,此 provider 不支持明文/TLS 混合滚动切换。
+- 准备 PEM 格式的 CA 证书,以及每个节点独立的 PEM 证书和私钥。节点证书必须同时支持 
`serverAuth`、`clientAuth`,DNS/IP Subject Alternative 
Name(SAN)必须覆盖其他节点实际使用的访问地址。如果 Doris 注册或连接节点时使用 IP,必须包含对应的 IP SAN。
+- CA 私钥保留在 Doris 节点以外的签发系统。允许 Doris 服务账号读取自己的身份文件,并将私钥访问权限限制为该账号。
+- FE 使用阻塞式 Thrift,推荐默认的 `THREAD_POOL`。此 TLS 实现不支持 `THREADED_SELECTOR`。
+
+### 1. 准备节点证书
+
+使用组织现有的证书签发流程。以下示例为一个示例 BE 创建私钥和证书签名请求(CSR),应在该节点新建的受保护目录中运行,并将示例域名和 IP 
替换为节点的实际身份。对每个 FE、BE 重复此流程,使用不同的私钥和节点名称。
+
+```bash
+umask 077
+cat > node.cnf <<'EOF'
+[req]
+prompt = no
+distinguished_name = dn
+req_extensions = node_cert
+[dn]
+CN = be1.example.com
+[node_cert]
+basicConstraints = critical,CA:FALSE
+keyUsage = critical,digitalSignature,keyEncipherment
+extendedKeyUsage = serverAuth,clientAuth
+subjectAltName = @names
+[names]
+DNS.1 = be1.example.com
+IP.1 = 192.0.2.10
+EOF
+openssl genpkey -algorithm RSA -pkeyopt rsa_keygen_bits:3072 -out node-key.pem
+openssl req -new -key node-key.pem -out node.csr -config node.cnf
+```
+
+预期结果:生成未加密的 PKCS#8 PEM 私钥 `node-key.pem` 和 CSR `node.csr`。只将 CSR 和所需的证书扩展交给 CA 
管理员,不发送节点私钥。
+
+如果 CA 管理员使用 OpenSSL,可在 **CA 签发系统**上参考以下命令签发:
+
+```bash
+openssl x509 -req -in node.csr -CA cluster-ca.pem -CAkey cluster-ca-key.pem \
+    -CAcreateserial -out node-cert.pem -days 365 -sha256 \
+    -extfile node.cnf -extensions node_cert
+```
+
+证书有效期和序列号应遵循现有 PKI 策略。预期结果:生成由集群专用 CA 签发的 `node-cert.pem`,包含所需的 SAN 
和两种扩展密钥用途。将节点证书及 CA 公共证书返回节点;使用中间 CA 时,提供所需的证书链和信任证书包。CA 私钥始终保留在签发系统。
+
+### 2. 配置 FE
+
+在每个 FE 的 `conf/fe.conf` 中添加以下配置。将占位路径替换为 FE 服务账号可读取的绝对路径,并使用该 FE 自己的证书和私钥。
+
+```properties
+enable_tls=true
+tls_verify_mode=verify_fail_if_no_peer_cert
+tls_certificate_path=/path/to/fe-cert.pem
+tls_private_key_path=/path/to/fe-key.pem
+tls_ca_certificate_path=/path/to/cluster-ca.pem
+tls_cert_refresh_interval_seconds=0
+tls_excluded_protocols=http,mysql,arrowflight,bdbje
+thrift_server_type=THREAD_POOL
+thrift_rpc_connect_timeout_ms=10000
+```
+
+`tls_peer_cert_required_san_dns` 保持为空。本例使用未加密私钥;对于受支持的加密 PEM 私钥,FE 也支持现有的 
`tls_private_key_password` 配置。
+
+### 3. 配置 BE
+
+在每个 BE 的 `conf/be.conf` 中添加以下配置,使用该 BE 自己的证书和私钥:
+
+```properties
+enable_tls=true
+tls_verify_mode=verify_fail_if_no_peer_cert
+tls_certificate_path=/path/to/be-cert.pem
+tls_private_key_path=/path/to/be-key.pem
+tls_ca_certificate_path=/path/to/cluster-ca.pem
+tls_cert_refresh_interval_seconds=0
+tls_excluded_protocols=http,arrowflight
+thrift_server_type_of_fe=THREAD_POOL
+thrift_connect_timeout_seconds=3
+```
+
+BE 必须使用**未加密的 PEM 
私钥**,`tls_private_key_password`、`tls_peer_cert_required_san_dns` 均保持为空。BE 的 
`thrift_server_type_of_fe` 必须与 FE 的 Thrift 服务模式一致。
+
+对于仅开启内部 RPC TLS 的部署,以上协议排除列表是必要配置:统一框架会选择所有未被明确排除的协议。除非已有对应协议可用的 TLS 
实现和部署方案,否则不要移除这些排除项。
+
+### 4. 切换并验证
+
+1. 在维护窗口内停止提交新负载,等待或停止正在执行的任务,备份原有节点配置。
+2. 向所有参与的 FE、BE 节点部署身份文件和 TLS 配置。停止旧进程,再按现有集群管理流程启动使用新配置的集群。不要让明文对端继续连接 TLS 
监听端。
+3. 通过原有 SQL 端点连接,执行 `SHOW FRONTENDS;`、`SHOW BACKENDS;`。预期结果:相关节点恢复存活状态,心跳恢复正常。
+4. 执行会下发到 BE 的代表性查询、包含跨 BE exchange 的查询,以及导入操作。预期结果:操作成功,且没有 TLS/认证错误。仅执行 
`SELECT 1` 无法验证这些内部通道。
+5. 执行[示例](#示例)中的证书和连接检查。证书拒绝测试应使用独立探测客户端,不要替换运行中节点的身份。
+
+## 参数配置
+
+[TLS 框架参考](./tls-framework.md)介绍共享配置契约。下表说明此开源内部 RPC 实现的额外约束,“空”表示空字符串。TLS 
身份配置在进程启动时生效,修改文件或配置后需要重启。
+
+| 配置项 | 类型 / 组件 | 默认值 | 本部署要求或作用 |
+| --- | --- | --- | --- |
+| `enable_tls` | Boolean / FE、BE | `false` | 所有参与节点均设为 `true`。 |
+| `tls_verify_mode` | String / FE、BE | `verify_peer` | 必须为 
`verify_fail_if_no_peer_cert`,可选客户端证书或跳过校验的模式会被拒绝。 |
+| `tls_certificate_path` | String / FE、BE | 空 | 必填,PEM 节点证书及必要证书链。 |
+| `tls_private_key_path` | String / FE、BE | 空 | 必填,与证书匹配的 PEM 私钥。 |
+| `tls_ca_certificate_path` | String / FE、BE | 空 | 必填,PEM 集群 CA 
证书或信任证书包,不能依赖系统/JDK 默认信任库。 |
+| `tls_private_key_password` | String / FE、BE | 空 | BE 必须为空;FE 对受支持的加密 PEM 
私钥支持现有密码配置。 |
+| `tls_cert_refresh_interval_seconds` | Integer / FE、BE | `3600` | 必须显式设为 
`0`,不支持自动证书重载。 |
+| `tls_excluded_protocols` | String / FE、BE | 空 | 
FE:`http,mysql,arrowflight,bdbje`;BE:`http,arrowflight`。本文内部通道要求保留 
`brpc`、`thrift`,不能将其排除。 |
+| `tls_peer_cert_required_san_dns` | String / FE、BE | 空 | 必须为空,此 provider 
不实现框架的 DNS SAN 准入列表。 |
+| `thrift_server_type` | String / FE | `THREAD_POOL` | 使用阻塞式 `THREAD_POOL` 或 
`SIMPLE`,不能使用 `THREADED_SELECTOR`。 |
+| `thrift_server_type_of_fe` | String / BE | `THREAD_POOL` | 与 FE 的 Thrift 
模式一致。 |
+| `thrift_rpc_connect_timeout_ms` | Integer / FE | `10000` | 必须大于零,即使普通 RPC 
读取没有超时,也会限制 Thrift TLS 认证耗时。 |
+| `thrift_connect_timeout_seconds` | Integer / BE | `3` | 
必须大于零,且转换为毫秒后可表示,用于限制 Thrift TLS 认证耗时。 |
+
+`tls_cert_based_auth_ignore_password` 与节点 RPC 认证无关,应保留默认值 `false`。开启内部 mTLS 
不会改变 SQL 用户认证方式。
+
+## 示例
+
+### 检查已签发的证书
+
+部署前检查 CA 证书链、两种用途以及节点访问地址:
+
+```bash
+openssl verify -CAfile cluster-ca.pem -purpose sslserver node-cert.pem
+openssl verify -CAfile cluster-ca.pem -purpose sslclient node-cert.pem
+openssl x509 -in node-cert.pem -noout -checkhost be1.example.com
+openssl x509 -in node-cert.pem -noout -checkip 192.0.2.10
+```
+
+预期结果:两条证书校验命令均输出 `node-cert.pem: OK`,主机名/IP 检查均报告匹配。根据申请的 SAN 调整检查内容;使用中间 CA 
时,按 PKI 要求提供中间证书链。
+
+### 探测 Thrift TLS 监听端
+
+从持有自身集群证书的授权节点或诊断主机探测 FE Thrift 端点。示例使用默认 FE `rpc_port`:`9020`,请替换为实际配置的主机名和端口。
+
+```bash
+openssl s_client -connect fe1.example.com:9020 -servername fe1.example.com \
+    -CAfile cluster-ca.pem -cert node-cert.pem -key node-key.pem \
+    -verify_hostname fe1.example.com -verify_return_error -brief < /dev/null
+```
+
+预期结果:TLS 协商成功,证书校验报告 `OK`。该命令检查 TLS 认证,不发送 Thrift 业务请求。使用对应节点名称,继续检查 BE 
backend 和 heartbeat Thrift 监听端,默认端口分别为 `9060`、`9050`。
+
+如果通过 IP 访问目标,将 `-verify_hostname fe1.example.com` 替换为 `-verify_ip` 及对应 
IP,证书必须包含匹配的 IP SAN。
+
+使用独立客户端,不提供客户端证书,或提供由无关 CA 签发的证书时,认证必须失败。对执行主机名校验的客户端,即使证书受信任,目标主机名/IP 
不匹配时也必须拒绝连接。原生 BRPC 校验 CA 信任域,不执行后一种主机名检查。
+
+### 保留远端 Doris 读取能力
+
+使用远端 Doris Catalog 时,保留 Catalog 属性 `use_arrow_flight=true`(默认值)。远端结果进入本地 
worker,使查询 exchange 和执行状态上报留在本地 TLS 集群。开启内部 BRPC 或 Thrift TLS 
后,`use_arrow_flight=false` 中将 worker 分配到远端集群的执行图会在下发前被拒绝,包括带有反向回调的纯远端执行图。
+
+远端元数据访问和由本地 worker 执行的 tablet 写入保持外部连接策略。文件密钥描述符不能通过这些远端明文通道发送。本地内部 TLS 
不会为独立远端集群建立信任或配置 TLS。
+
+## 错误处理
+
+| 现象 | 检查与处理 |
+| --- | --- |
+| 启动提示需要 TLS module | 确认 FE、BE 均包含内部 RPC 实现,并检查协议排除列表;内置 provider 不实现所有公共协议。 |
+| 配置因双向认证要求而被拒绝 | 设置 
`tls_verify_mode=verify_fail_if_no_peer_cert`,并提供可读取的证书、匹配私钥及 CA 文件。 |
+| 配置因静态身份或 CA 信任域要求而被拒绝 | 将重载周期设为 `0`,清空 `tls_peer_cert_required_san_dns`,并清空 
BE 私钥密码。 |
+| Thrift 无法启动 | 使用受支持的阻塞式服务模式,保证 FE/BE Thrift 模式配置一致,连接超时大于零。 |
+| 切换后心跳、下发或查询失败 | 检查是否存在明文节点、CA 信任证书包不一致、证书过期、缺少客户端/服务端用途、主机名/IP SAN 
不匹配、文件不可读或证书私钥不匹配。 |
+| 建连超时 | 检查网络可达性及对端 TLS 配置。Thrift 认证有超时限制,TCP 端口开放不代表认证成功。 |
+| 替换证书文件后未生效 | 重启相关进程,此 provider 不支持自动重载。 |
+| 远端 Doris 直接执行被拒绝 | 保留默认 Arrow Flight Catalog 模式;本地 TLS 身份无法认证独立调度的远端 worker。 
|
+
+## 最佳实践
+
+- 每个节点独立生成私钥,并由集群专用 CA 签发对应证书,不与无关服务共享 CA。CA 信任域定义集群成员凭据的信任边界,不提供逐节点角色策略。
+- 将私钥文件访问权限限制为 Doris 服务账号。节点只接收 CA 公共证书,不接收 CA 私钥。
+- 监控证书有效期。同一受信任 CA 下续签时,安装新节点身份,并按现有高可用运维流程重启相关进程,重启后重新验证内部 RPC。
+- 更换 CA 时,先部署同时包含新旧 CA 的信任证书包并重启相关节点;再替换节点身份并重启,验证连接后移除旧 CA 
并再次重启。整个过程中,每条通信路径都必须保持双向信任。
+- 如需恢复明文,安排新的维护窗口,在所有参与节点上一致关闭 TLS,不存在自动明文回退。
+- 单独保护进程内存和崩溃产物。内部传输加密不会消除使用密钥的进程中的明文秘密。
diff --git 
a/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/security-overview.md
 
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/security-overview.md
index 9bacb8466ad..5629cc687ab 100644
--- 
a/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/security-overview.md
+++ 
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/security-overview.md
@@ -21,6 +21,7 @@ Apache Doris 面向企业级数据平台提供完整的安全能力,覆盖身
 | 与大数据生态统一权限治理 | Apache Ranger 集成 | [基于 Ranger 的鉴权方案](./authorization/ranger) |
 | 敏感数据保护(行级/列级、脱敏) | 数据访问控制 | [数据访问控制](./authorization/data) |
 | 客户端到 FE 链路加密 | MySQL 协议 SSL、FE HTTPS | [MySQL 协议 SSL](./certificate)、[FE 
HTTPS 配置](./fe-certificate) |
+| 受支持的 FE/BE 内部 RPC 加密(Doris 5.0 起) | 节点证书认证、gRPC/BRPC 和阻塞式 Thrift mTLS | 
[使用双向 TLS 加密内部 RPC](./private-rpc-tls.md) |
 | 审计与合规追溯 | 审计日志 | [审计日志](../audit-plugin) |
 | 数据加解密计算 | 加密函数 | [数据加密函数](./encryption-function) |
 | 部署在 AWS 上、对接 IAM | AWS 认证鉴权 | [AWS 
认证与鉴权](./integrations/aws-authentication-and-authorization) |
@@ -112,5 +113,6 @@ Doris 在认证侧支持**内置认证**与 **LDAP 认证**两种方案;在鉴
 | 审计日志 | [审计日志](../audit-plugin) |
 | MySQL 协议 SSL 传输加密 | [MySQL 协议 SSL](./certificate) |
 | FE HTTP/HTTPS 传输加密 | [FE HTTPS 配置](./fe-certificate) |
+| FE/BE 内部 RPC 双向 TLS(Doris 5.0 起) | [使用双向 TLS 加密内部 RPC](./private-rpc-tls.md) 
|
 | 加密函数 | [数据加密函数](./encryption-function) |
 | 与云厂商集成(AWS) | [AWS 
认证与鉴权](./integrations/aws-authentication-and-authorization) |
diff --git 
a/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/tls-framework.md
 
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/tls-framework.md
index 39ade6574fe..c8bf3181fb3 100644
--- 
a/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/tls-framework.md
+++ 
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/auth/tls-framework.md
@@ -24,6 +24,8 @@
 
 开源 Doris 包含 TLS 和证书鉴权相关的框架、配置项、解析支持和扩展点,但不包含覆盖所有协议的完整 TLS 
运行时实现。在开源默认构建中,如果为未提供 TLS 模块实现的协议开启 TLS,启动或连接创建会失败,并提示需要 TLS module。
 
+自 Apache Doris 5.0 起,开源构建为内部 gRPC/BRPC 和阻塞式 Thrift 提供内置双向 
TLS。证书准备、必要的配置覆盖、协调切换及协议限制见[使用双向 TLS 加密内部 RPC](./private-rpc-tls.md)。
+
 下表中的配置名称、默认值和语义由框架固定。如果你提供自己的 TLS module 实现,需要使用这套框架和这些配置项,以保证配置兼容。证书加载、TLS 
context 创建、握手行为、证书重载、协议级对端校验等细节可以由 TLS module 自行实现。
 
 ## 配置项参考
@@ -55,7 +57,7 @@
 
 开源框架提供配置定义和扩展点。当 `enable_tls` 为 `false` 时,默认 provider 保持已有明文行为。
 
-当 `enable_tls` 为 `true` 时,协议启动或 channel 创建会进入 TLS 框架。如果没有提供对应 TLS 
module,开源默认实现会拒绝该协议的 TLS 启动,并提示需要 TLS module。
+当 `enable_tls` 为 `true` 时,协议启动或 channel 创建会进入 TLS 框架。包含内置内部 RPC provider 
的构建可以提供其支持的内部协议。如果选中的协议没有对应 TLS 实现,开源默认实现会拒绝该协议的 TLS 启动,并提示需要 TLS module。
 
 因此,上面的配置表是兼容性契约,不是开源默认包中直接启用 TLS 的完整操作手册。
 
diff --git a/sidebars.ts b/sidebars.ts
index 0902680dc5a..d42ff9f7c78 100644
--- a/sidebars.ts
+++ b/sidebars.ts
@@ -987,6 +987,7 @@ const sidebars: SidebarsConfig = {
                                         'admin-manual/auth/certificate',
                                         'admin-manual/auth/fe-certificate',
                                         'admin-manual/auth/tls-framework',
+                                        'admin-manual/auth/private-rpc-tls',
                                     ],
                                 },
                                 'admin-manual/auth/encryption-function',


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to