(1) 找到并编辑您的 redis.conf 文件,通常位于 /etc/redis/redis.conf nano /etc/redis/redis.conf (2) 找到 redis.conf 文件并编辑它,添加 SSL 证书、私钥和 CA 证书的路径。port 0tls-port 6379tls-cert-file /path/to/redis.crttls-key-file /path/to/redis.keytls-ca-cert-file /path/to/ca....
在redis-cli 执行如下命令,验证 TLS 配置: ./src/redis-cli -h <Redis_IP> -p <TLS-Port> --tls --cert ./tests/tls/redis.crt --key ./tests/tls/redis.key --cacert ./tests/tls/ca.crt Info Server <Redis_IP>:表示 Redis Standalone 节点 IP 或者集群 VIP。 <TLS-Port>:表示 Redis Stand...
5186 process_supervised:no run_id:582101ac9ac0314b265439da67d00854d5d19a70 tcp_port:6379 server_time_usec:1635753556324954 uptime_in_seconds:5395 uptime_in_days:0 hz:10 configured_hz:10 lru_clock:8363604 executable:/opt/redis/current/redis-server config_file:/data/redis/redis.conf io_threads...
nano /etc/redis/redis.conf (2) 找到 redis.conf 文件并编辑它,添加 SSL 证书、私钥和 CA 证书的路径。 port 0 tls-port 6379 tls-cert-file /path/to/redis.crt tls-key-file /path/to/redis.key tls-ca-cert-file /path/to/ca.crt (3) 重新启动 Redis 服务器,应用更改 systemctl restart redis...
TLS -port配置指令允许在指定的端口上接受SSL/TLS连接。这是除监听TCP连接端口之外的端口,所以可以同时使用TLS和非TLS连接访问不同端口上的Redis。 您可以指定端口0来完全禁用非TLS端口。要在默认的Redis端口上仅启用TLS,请使用: port 0tls-port 6379 客户端证书认证 默认情况下,Redis使用双向TLS,并要求客户端使用...
tls-port6379tls-cert-file /path/to/redis.crt tls-key-file /path/to/redis.key 这里,我们设置 Redis 在 TLS 端口 6379 上监听,并指定了证书和私钥的路径。 最后,我们需要重启 Redis 以应用这些更改: 代码语言:bash AI代码解释 sudoserviceredis-server restart ...
tls-port6379port0tls-cert-file /path/to/redis.crt tls-key-file /path/to/redis.key tls-ca-cert-file /path/to/ca.crt tls-auth-clientsyes 1. 2. 3. 4. 5. 6. 上述配置中,tls-port指定使用TLS的端口,port 0禁用了非TLS连接。tls-cert-file和tls-key-file指向SSL证书和私钥。
run_id:582101ac9ac0314b265439da67d00854d5d19a70 tcp_port:6379 server_time_usec:1635753556324954 uptime_in_seconds:5395 uptime_in_days:0 hz:10 configured_hz:10 lru_clock:8363604 executable:/opt/redis/current/redis-server config_file:/data/redis/redis.conf io_threads_active:0...
(2) 找到 redis.conf 文件并编辑它,添加 SSL 证书、私钥和 CA 证书的路径。 port 0 tls-port 6379 tls-cert-file /path/to/redis.crt tls-key-file /path/to/redis.key tls-ca-cert-file /path/to/ca.crt (3) 重新启动 Redis 服务器,应用更改 ...
# 禁用默认端口 port 0 # 启用 TLS 的端口 tls-port 6379 # 证书文件路径 tls-cert-file /path/to/redis_cert.crt # 私钥文件路径 tls-key-file /path/to/redis_private.key # 可选的 CA 证书文件路径(如果使用受信任的 CA 签发的证书) # tls-ca-cert-file /path/to/ca.crt 请将上述路径替换为...