簡體   English   中英

應用程序無法在運行Debian的BeagleBone Black上驗證SSL自簽名證書

[英]Application fails to verify SSL self-signed certificate on a BeagleBone Black running Debian

以下代碼在我的Ubuntu機器(Python 2.7.6)中運行正常:

r = requests.get(GET_URL, verify=certificate_path)

當我在Debian的BeagleboneBlack中運行此代碼時,我得到了這個:

/usr/local/lib/python2.7/dist-packages/requests/packages/urllib3/util/ssl_.py:100:
InsecurePlatformWarning: A true SSLContext object is not available. This prevents 
urllib3 from configuring SSL appropriately and may cause certain SSL connections 
to fail.

For more information, see https://urllib3.readthedocs.org/en/latest/security.html
#insecureplatformwarning.   InsecurePlatformWarning

[Errno 1] _ssl.c:504: 
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed

certificate_path具有自簽名證書的路徑。 有人可以幫忙嗎?

在搜索了更多並嘗試了一些替代方案,包括評論中的建議方法后,我發現了這個鏈接: https//serverfault.com/questions/549679/issued-certificate-not-yet-valid-with-wget

問題是系統時鍾設置為過去日期

剛剛使用以下命令更正了日期,它對我有用:

$ ntpdate gps.ntp.br

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM