ThunerBird 78.8.1 连接 TLS 1.0 失败问题和 Linux 乱谈

Last updated on December 6, 2023 am

我在公司使用 Linux 作用主力机已经 10 多年了,自从抛弃 Ubuntu 转入 Fedora 怀抱,生活幸福了不少。
早年最大的问题是 OFFICE 软件,工作中少不了要和 doc、ppt,xls 打交道,又没有太好的软件可以使用。
刚开始基本就两个解决方案,wine office 和永中 OFFICE,这两个方案都不是太理想,wine 的速度很慢,
永中则兼容性比较差,还会出现文档格式看起来就有明显差异的情况。。

随着金山 wps 的发展,现在 OFFICE 的问题基本解决,作为轻度 EXCEL 使用者基本已经满足需求了。Linux
现在主要问题是字体渲染比较差,中文经常看起来发虚,如果能把这个问题彻底解决就非常不错了。作为Linux
老用户,各种魔改后,也能较好使用了,但后面发现还是换个显示器更管用。要解决中文显示问题,有两个
字体很管用,文泉驿微米黒和微软雅黑,实践证明把系统字体用上面两个字体替换,显示效果也就好了不少了。

Ubuntu Linux 最大的问题就是不太稳定,基本每次大版本升级显示都要挂,弄得我都有点心理阴影了,原来
周围还挺多同学使用 Linux,最终放弃了,一个直接用 Windows 了,还有一个 Windows 上跑一个 Linux 虚拟机。
Ubuntu 还有个坏习惯喜欢乱改,upstart,Unity等,后面都没有成为主流,bug 就更不用说了,经常挺闹心的。

Fedora 从近些年的使用情况来看,还是很不错的,网络中流传是 Redhat Linux Enterprise 的小白版本,
但是其实只要 bug 修得快,你大概率是感觉不到的。遇上问题,放狗一搜就会发现 redhat 已经有 bug 在
处理中了,于是乎就有了今天这篇。

在升级到 Fedara 33 和 ThunderBird 78 后,使用 TLS 连接公司的 ExChange 邮件服务器就连不上了。
我们公司的内网安全审核非常严格,邮件不使用加密连接要限时整改。放狗一搜发现,大批人员都遇上了
相同的问题,也有人给出了解决方案。

https://support.mozilla.org/en-US/questions/1295861

1
2
3
4
I think this could be due to the minimum version of TLS supported by TB 78. The release notes state 
that versions lower than 1.2 are disabled, so if your server only supports v. 1.1,
you might be able to fix sending by changing the preference security.tls.version.min to 2 from the default 3, in Config. editor.

https://www.thunderbird.net/en-US/thunderbird/78.0/releasenotes/

1
TLS 1.0 and 1.1 disabled

如何开启 TLS 1.0, mozilla 也给出了相应的方案

https://support.mozilla.org/en-US/kb/thunderbird-78-faq#w_how-to-enable-outdated-security-protocols-tls-1-0-and-1-1

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
How to enable outdated security protocols TLS 1.0 and 1.1

Open Config Editor (about:config)
≡ > Preferences > Find in Preferences
In the searchbox, type: about:config, then press Enter.
Click on the button Config Editor… in the search result.
In the about:config dialog, search for: security.tls.version.min
Double-click on the found preference security.tls.version.min and change its value to 1, then press Enter.
Restart Thunderbird and try to download your messages.
If you can receive and/or send your messages after changing this preference:

Please inform your email provider to upgrade the security protocols on the server to support TLS 1.2.
Revert the preference security.tls.version.min to its original value as soon as possible by repeating
the above procedure, then right-click on the preference and choose Reset from the context menu.

看上去解决方案很简单,在 Preferences 中的搜索框里输入 about:config 点击进入,将其中的
security.tls.version.min 设置为 1 就好了,但是在 Fedora 34 中不起作用。我用 wireshark 抓了包看,
ThunderBird 自己报告不支持的协议版本。我仔细研究了一下 ThunderBird 相关的 config 项有下面几个:

1
2
3
security.tls.version.min
security.tls.version.enable-deprecated
security.tls.version.fallback-limit

我把这几个选项都设置了一下,分别设置为 1 true 1,还是不管用。

在 Fedora 33 上这个问题就没解决,这都 Fedora 34 了,所以又花了时间研究了一下。没好办法,放狗,运气
不错,看到了这篇

https://bugzilla.mozilla.org/show_bug.cgi?id=1674092#c11

原来 Fedora 还有个 StrongCryptoSettings ,看文档可以修改

1
2
3
update-crypto-policies --set DEFAULT:FEDORA32
update-crypto-policies --set LEGACY
reboot

关键的内容就是下面这几行

cat /etc/crypto-policies/state/CURRENT.pol

1
2
min_tls_version = TLS1.2
protocol = TLS1.3 TLS1.2 DTLS1.2

执行后变为

1
2
min_tls_version = TLS1.0
protocol = TLS1.3 TLS1.2 TLS1.1 TLS1.0 DTLS1.2 DTLS1.0

重启系统后,又可以开心地使用 ThunderBird 了 ^_^


ThunerBird 78.8.1 连接 TLS 1.0 失败问题和 Linux 乱谈
http://usmacd.com/cn/thunderbird.tls.1.0/
Author
henices
Posted on
June 6, 2021
Licensed under