Facebook 分享偵錯工具出現 Can’t validate SSL Certificate. Either it is self-signed 怎麼辦

我最近遇到有人的網站需要用自己買的憑證不要用 AWS 提供的憑證,我把憑證上完之後瀏覽器使用都是正常的,不過他後來在使用 Facebook 分享偵錯工具的時候卻出現 Can’t validate SSL Certificate. Either it is self-signed。

出現 Can’t validate SSL Certificate. Either it is self-signed 的原因

會出現這個問題其實是因為它的鏈有問題造成 Facebook 在找上層的時候發生了錯誤所引發的原因,那要怎麼解決呢?可以到 What’s My Chain Cert? 這個網站打入你的網址,會看到以下出現 is misconfigured. This is the chain it should be using.,點它的 This 下載 chain 檔案然後把它更新到 Certificate chain 上就可以了。

驗證 chain 是否設定成功

如果確實都有設定成功再按一次 Test 就會出現 has the correct chain. 了!