2024年9月15日 星期日

SSL certificate problem: unable to get local issuer certificate

使用git的時候會出現的狀況。不過狀況還是可以區分出兩種情境:

  1. 該網站雖然使用https協定,但是憑證不合法(可能過期或是只有使用IP沒過DNS)
  2. 該網頁使用https協定,且使用瀏覽器開啟都合法,使用git卻不合法
情境2是因為ssl申請完畢後,需要有一個放到store的程序。git安裝時其實會去掃store,所以把原本的git移除以後重新安裝大概可以處理掉(網頁很多就直接教學說升級git,反正都要移除重裝了,不如就順便升級)。另外一種做法就是設定git的認證方式。windows上有schannel可以用(ubuntu目前還沒找到辦法,就只能自己手動輸入到store或是直接不認證)

git config --global http.sslBackend schannel


情境1的狀況,因為是本身的ssl認證狀態就是問題,所以最好就是從git的認證直接關掉:


git config --global http.sslVerify false


ref:

https://komodor.com/learn/how-to-fix-ssl-certificate-problem-unable-to-get-local-issuer-certificate-git-error/

https://forum.gitea.com/t/fatal-unable-to-access-ssl-certificate-problem-unable-to-get-local-issuer-certificate/1434

https://github.com/go-gitea/gitea/issues/8063

https://wiki.gentoo.org/wiki/Certificates

https://blog.csdn.net/sinat_24899403/article/details/114967572

沒有留言:

張貼留言

iscsi 連線問題筆記

如果要進行umount但是出現target buzy sudo fuser -km 掛載點 sudo umount 掛載點 iSCSI重啟 sudo open-iscsi restart  掛載lun iscsiadm -m discovery -t sendtargets -p...