centos8之openssl配置

centos8当中的openssl默认配置需要做调整,否则一些用了ssl的工具在访问旧服务器时会出现一些问题。我遇到的情况是svn检出旧服务器上的项目时出现了异常(访问新服务器正常):[root@localhost projects]# svn co https://serverip/svn/Linux/hmihmisvn: E170013: Unable to connect to...
摘要由CSDN通过智能技术生成

centos8当中的openssl默认配置需要做调整,否则一些用了ssl的工具在访问旧服务器时会出现一些问题。

我遇到的情况是svn检出旧服务器上的项目时出现了异常(访问新服务器正常):

[root@localhost projects]# svn co https://serverip/svn/Linux/hmi hmi
svn: E170013: Unable to connect to a repository at URL 'https://serverip/svn/Linux/hmi'
svn: E120171: Error running context: An error occurred during SSL communication

出现这种情况是由于新版本的openssl与服务器上的ssl所用的协议不兼容导致的。

我们可以用以下命令来测试(svn服务器默认用的443的端口号):

[root@localhost projects]# openssl s_client -connect serverip:443
CONNECTED(00000004)
139911078549312:error:1425F102:SSL routines:ssl_choose_client_version:unsupported protocol:ssl/statem/statem_lib.c:1907:
---
no peer certificate available
---
No client certificate CA names sent
---
SSL handshake has read 58 bytes and written 326 bytes
Verification: OK
---
New, (NONE), Cipher is (NONE)
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
Early data was not sent
Verify return code: 0 (ok)
---

这里发现openssl默认选择的tls版本,服务器是不支持的,我们还可以加tls版本参数再来测试(我用的openssl可以支持-tls1_3 -tls1_2 -tls1_1 -tls1的版本,这些是通过命令openssl s_client -help得知的,可以都尝试下),以下是测试-tls1_2的情况:

[root@localhost projects]# openssl s_client -connect serverip:443 -tls1_2
CONNECTED(00000004)
140651559294784:error:1425F102:SSL routines:ssl_choose_cli
  • 1
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 3
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 3
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值