在 Linux 上移除 CNNIC 憑證

139 views
Skip to first unread message

Cheng

unread,
Feb 2, 2010, 8:24:55 AM2/2/10
to shlug


 
 

Sent to you by pnt via Google Reader:

 
 

via Rex's blah blah blah by Rex Tsai on 2/2/10

一月底開始,一些朋友開始討論 Firefox 3.6 中,將置入 CNNIC 的 CA 憑證。這件事情是去年年底,CNNIC 對 Firefox 申報納入 CNNIC 的憑證 (#476766),目前已於 3.6 版中內建 CNNIC 憑證。

目前此事已經在 Mozilla Security Policy mailing list 公開討論,在華人網路社群也引起一陣騷動。像是 AutoProxy 等社群都提出 CNNIC CA:最最最嚴重安全警告!。在原提案 #476766 中亦有人整理了一些客觀事實。

不過根據我主觀的看法,奉勸所有人盡快移除 CNNIC 相關的 CA 憑證!CNNIC 就是中國網際網路絡信息中心,是一個中國的非營利組織,提供中國網際網路的網域名稱、網段管理。

CA 憑證對於瀏覽器使用者而言,可以用來辨識特定網域是否為合法組織,部份瀏覽器功能甚至依據有否憑證,對網頁開啟進階存取權限。前提是 CA 維持善良管理人義務,嚴格管理所核發的憑證、簽章。

CNNIC 過去最大的爭議即是曾經發布過中文上網官方版軟體,名為提供中文網址導引服務,實質則包含流氓軟體的功能。雖說這只是一項前科,但是中國政府持續拿著民族主義、國家安全為藉口,實施數種網路管制,甚至滲透國外企業、政府網路。

而 CNNIC 背後支持的政府組織是中華人民共和國工業和信息化部中国科学院中國科學院計算機網絡信息中心 等中國政府組織。很難說,哪一天 CNNIC 不會被控制作為跳板之一。

除了 CNNIC 自行發布的 CA Cert Root 外,其實 CNNIC 也已經取得 Entrust.net 所發布的次級憑證。建議所有台灣政府單位,一律移除 CNNIC 相關憑證。

若你覺得此事關係重大,可以以投票方式附議 Bug 542689 – Please Remove “CNNIC ROOT” root certificate from NSS,提高該問題的被重視程度。

跳板風險

其實 Mozilla 先前也曾經遭遇過亂搞的安全憑證公司。原則上,任何人要申請特定網域的簽章,必須提供書面資料,證明你是該網域的擁有者。因為 SSL 憑證一個主要功能是防止釣魚網站欺騙一般消費者,若使用假冒的憑證,使用者很容易就發現網址異常。

若安全憑證公司絲毫不做基本的驗證,任何人都可以申請想仿冒的網域,然後以中間人攻擊 (MITM) 詐騙你交出個人資料。想像,你收到一封 PCHOME 的廣告,連到一個假的網站,這個網站提供了完美的 SSL 憑證,你很自然就會上當。

Mozilla 的事件起因,是有人回報一安全憑證公司推銷新的服務,但這個憑證公司讓你隨意購買任一網址。於是你可以假冒任何人,Eddy Nigg 寫了一份詳盡的說明。Mozilla 也撤除這組組憑證了。

移除 CA 憑證

驗證方法是開啟 CNNIC 的網址衛士 (使用 Entrust.net) 或 CNNIC 的 ENUM 試驗平台 (使用 CNNIC Root Cert)。若你的瀏覽器絲毫不給警告的就讓你存取,你的系統即已安裝 CNNIC 憑證。

在 GNU/Linux Debian, Ubuntu 上,系統保持一份共用的 CA 憑證,許多網頁工具如 Firefox, curl, wget, Chrome 均共用同一組設定。因此最簡便的方法便是關閉系統上有問題的憑證。

作法是以 root 在終端機內重新設定以下指令

# dpkg-reconfigure ca-certificates

找到 mozilla/Entrust.net_Secure_Server_CA.crt 一列,反選取之,選擇確認即可。或者直接編輯 /etc/ca-certificates.conf,一樣找到此行後,於該行開頭加入驚嘆號 (!),然後重新以 root 執行一次 update-ca-certificates.

另外,你也得到瀏覽器手動刪除原已匯入之憑證。注意,若該筆憑證下方有多筆簽章,你必須刪除全部簽章。見圖

按下 Delete, 重新啟動 Firefox,如此即可移除相關的 CA 憑證,其他瀏覽器需比照辦理。你若使用其他作業系統,請參考 Felix Yan 所整理之 從「受信任的根證書」裡趕走CNNIC


 
 

Things you can do from here:

 
 

dword

unread,
Feb 2, 2010, 8:34:05 AM2/2/10
to sh...@googlegroups.com
在 2010年2月2日 星期二 21:24:55,Cheng 写道:
> Sent to you by pnt via Google Reader:
>
>
> 在 Linux 上移除 CNNIC
对chrome好想不起效果...
另外certutil我都掰来掰去掰了一下午了,好像也不行。
www.enum.cn的流量算是赚翻了
signature.asc

Jiahua Huang

unread,
Feb 2, 2010, 8:43:34 AM2/2/10
to sh...@googlegroups.com
Chrome/Chromium Linux 请阅 
http://code.google.com/p/chromium/wiki/LinuxCertManagement

2010/2/2 dword <zhang...@gmail.com>
对chrome好想不起效果...
另外certutil我都掰来掰去掰了一下午了,好像也不行。
www.enum.cn的流量算是赚翻了

guru

unread,
Feb 2, 2010, 9:13:34 AM2/2/10
to sh...@googlegroups.com

Entrust都禁了
2010/2/2 Jiahua Huang <jhuang...@gmail.com>

guru

unread,
Feb 2, 2010, 10:11:12 AM2/2/10
to sh...@googlegroups.com
chrome下
$ certutil -d sql:$HOME/.pki/nssdb -L

Certificate Nickname                                         Trust Attributes
                                                             SSL,S/MIME,JAR/XPI
没保存证书,

https://www.enum.cn/cn/ 还是能正常访问,没有提示警告信息


2010/2/2 guru <perc...@gmail.com>

guru

unread,
Feb 2, 2010, 8:09:50 PM2/2/10
to sh...@googlegroups.com

certutil -d /etc/pki/nssdb/ -L也是空

guru

unread,
Feb 2, 2010, 8:38:10 PM2/2/10
to sh...@googlegroups.com
ok拉,ms chrome会用 .mozllia下的 cert

$ certutil -d sql:$HOME/.mozilla/firefox/99do9ofz.default -L

 VeriSign Class 3 Extended Validation SSL CA                  ,,   
Entrust.net Global Secure Server CA                          ,,   
Entrust.net Secure Server CA                                 ,,   
Entrust.net Global Secure Personal CA                        ,,   
Entrust.net Premium 2048 Secure Server CA                    ,,                                        ,,   
Entrust Root Certification Authority                         ,,   
Entrust.net Secure Personal CA                               ,, 

都删掉了  


2010/2/3 guru <perc...@gmail.com>

dword

unread,
Feb 2, 2010, 9:02:48 PM2/2/10
to sh...@googlegroups.com
在 2010年2月3日 星期三 09:38:10,guru 写道:
> ok拉,ms chrome会用 .mozllia下的 cert
>
> $ certutil -d sql:$HOME/.mozilla/firefox/99do9ofz.default -L
>
> VeriSign Class 3 Extended Validation SSL CA ,,
> Entrust.net Global Secure Server CA ,,
> Entrust.net Secure Server CA ,,
> Entrust.net Global Secure Personal CA ,,
> Entrust.net Premium 2048 Secure Server CA ,,
> ,,
> Entrust Root Certification Authority ,,
> Entrust.net Secure Personal CA ,,
>
> 都删掉了
>
>
确实有效。不知道为什么chrome要用firefox的配置文件。难道libnss3是mozilla开发的?
我把Entrust和CNNIC删干净了。

dword@dword-pc:~$ certutil -d sql:/home/dword/.mozilla/firefox/38gxqgyi.default/ -D -n Entrust.net\ Secure\ Personal\ CA
dword@dword-pc:~$ certutil -d sql:/home/dword/.mozilla/firefox/38gxqgyi.default/ -D -n Entrust\ Root\ Certification\ Authority
dword@dword-pc:~$ certutil -d sql:/home/dword/.mozilla/firefox/38gxqgyi.default/ -D -n Entrust.net\ Global\ Secure\ Personal\ CA
dword@dword-pc:~$ certutil -d sql:/home/dword/.mozilla/firefox/38gxqgyi.default/ -D -n Entrust.net\ Premium\ 2048\ Secure\ Server\ CA
dword@dword-pc:~$ certutil -d sql:/home/dword/.mozilla/firefox/38gxqgyi.default/ -D -n Entrust.net\ Secure\ Server\ CA
dword@dword-pc:~$ certutil -d sql:/home/dword/.mozilla/firefox/38gxqgyi.default/ -D -n Entrust.net\ Global\ Secure\ Server\ CA
dword@dword-pc:~$ certutil -d sql:/home/dword/.mozilla/firefox/38gxqgyi.default/ -D -n CNNIC\ ROOT
dword@dword-pc:~$ certutil -d sql:/home/dword/.mozilla/firefox/38gxqgyi.default/ -L

Certificate Nickname Trust Attributes
SSL,S/MIME,JAR/XPI

VeriSign Class 3 Extended Validation SSL CA ,,
StartCom Class 2 Primary Intermediate Server CA ,,
Thawte SGC CA ,,
www.hb.chinamobile.com ,,
Google Internet Authority ,,
VeriSign Class 3 Secure Server CA - G2 ,,
StartCom Class 1 Primary Intermediate Server CA ,,
COMODO EV SGC CA ,,
PositiveSSL CA ,,
Go Daddy Secure Certification Authority ,,
dword@dword-pc:~$

signature.asc

dword

unread,
Feb 2, 2010, 9:26:00 PM2/2/10
to sh...@googlegroups.com
在 2010年2月3日 星期三 09:38:10,guru 写道:
> ok拉,ms chrome会用 .mozllia下的 cert
>
> $ certutil -d sql:$HOME/.mozilla/firefox/99do9ofz.default -L
>
> VeriSign Class 3 Extended Validation SSL CA ,,
> Entrust.net Global Secure Server CA ,,
> Entrust.net Secure Server CA ,,
> Entrust.net Global Secure Personal CA ,,
> Entrust.net Premium 2048 Secure Server CA ,,
> ,,
> Entrust Root Certification Authority ,,
> Entrust.net Secure Personal CA ,,
>
> 都删掉了
后来发现只对CNNIC ROOT有效,CNNIC SSL在chrome下照样被信任....Entrust删了也不行

怎么办?

signature.asc

guru

unread,
Feb 2, 2010, 9:37:34 PM2/2/10
to sh...@googlegroups.com
firefox 把 entrust cert builtin了,
初步怀疑g chrome 信任 firefox builtin的cert
 

2010/2/3 dword <zhang...@gmail.com>

guru

unread,
Feb 2, 2010, 9:39:36 PM2/2/10
to sh...@googlegroups.com
chrome 第一次进入 https://www.enum.cn/cn/ 还出警告

以后再进入就没警告直接进入首页了,...


2010/2/3 guru <perc...@gmail.com>
341.gif

Devil Wang

unread,
Feb 2, 2010, 9:42:18 PM2/2/10
to sh...@googlegroups.com
那是因为你的选择已经存到cache里面去了。

当然以后都不提示, 你清理一下cookie应该又会有了。
-- 
Thanks & Regards

Linux Developer: Devil Wang 
<wxje...@gmail.com>


341.gif
Reply all
Reply to author
Forward
0 new messages