web-dev-qa-db-ja.com

SSLは、「ピアの証明書発行者がユーザーによって信頼されていないものとしてマークされています」を発行します。

特定の機能にSSLを必要とする公開サーバーが存在します。

それでも、あらゆる形式でSSLを使用するすべてのものが戻ります

curl: (60) Peer's certificate issuer has been marked as not trusted by the user.

これは「yumでssl-verify = falseを使用するか、curlリクエストで--insecureを使用するか」の問題ではありません。

私はそれらの両方で私の通話を行うことができることを理解しています。しかし最終的には、これらのサーバーを使用する開発ではSSLが必要になるため、SSLを使用できる必要があります。

CAが古くなっているようです。私は以下を試しました https://access.redhat.com/solutions/15490

Cacert.pemファイルを自分でインポートしようとしました(認めますが、ここでは知識が不足しているため、間違った可能性があります)。

サーバーの日付と時刻を確認して、問題がないことを確認しました。

このマシンにCentosを再インストールすることに煩わされることさえありません。これに対する解決策。

任意の助けいただければ幸いです。以下は、yum、curl、certbot --Apacheの実行などを実行したときに得られる例の一部です。

ヤム

[root@localhost work]# yum reinstall mc
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Could not get metalink https://mirrors.fedoraproject.org/metalink?repo=epel- 
7&Arch=x86_64 error was
14: curl#60 - "Peer's certificate issuer has been marked as not trusted by 
the user."
 * base: repos.dfw.quadranet.com
 * epel: mirror.compevo.com
 * extras: repos-tx.psychz.net
 * updates: mirror.us.oneandone.net
 * webtatic: repo.webtatic.com
https://us-east.repo.webtatic.com/yum/el7/x86_64/repodata/repomd.xml: [Errno 
14] curl#60 - "Peer's certificate issuer has been marked as not trusted by 
the user."
Trying other mirror.
It was impossible to connect to the CentOS servers.
This could mean a connectivity issue in your environment, such as the 
requirement to configure a proxy,
or a transparent proxy that tampers with TLS security, or an incorrect 
system clock.
You can try to solve this issue by using the instructions on 
https://wiki.centos.org/yum-errors
If above article doesn't help to resolve this issue please use 
https://bugs.centos.org/.

https://uk.repo.webtatic.com/yum/el7/x86_64/repodata/repomd.xml: [Errno 14] 
curl#60 - "Peer's certificate issuer has been marked as not trusted by the 
user."
Trying other mirror.
https://sp.repo.webtatic.com/yum/el7/x86_64/repodata/repomd.xml: [Errno 14] 
curl#60 - "Peer's certificate issuer has been marked as not trusted by the 
user."
Trying other mirror.
https://repo.webtatic.com/yum/el7/x86_64/repodata/repomd.xml: [Errno 14] 
curl#60 - "Peer's certificate issuer has been marked as not trusted by the 
user."
Trying other mirror.

CURL

[root@localhost work]# curl https://www.google.com
curl: (60) Peer's certificate issuer has been marked as not trusted by the 
user.
More details here: http://curl.haxx.se/docs/sslcerts.html

curl performs SSL certificate verification by default, using a "bundle"
 of Certificate Authority (CA) public keys (CA certs). If the default
 bundle file isn't adequate, you can specify an alternate file
 using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
 the bundle, the certificate verification probably failed due to a
 problem with the certificate (it might be expired, or the name might
 not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
 the -k (or --insecure) option.

CERTBOT(LETSENCRYPT SSL CERT要求の場合)

[root@localhost work]#  Sudo certbot --Apache
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator Apache, Installer Apache
Enter email address (used for urgent renewal and security notices) (Enter 
'c' to cancel): [email protected]
Starting new HTTPS connection (1): acme-v02.api.letsencrypt.org
An unexpected error occurred:
SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed 
(_ssl.c:579)
Please see the logfiles in /var/log/letsencrypt for more details.
1
James F

これに答えて、今後の参考のために閉じたかった。

プロキシサーバーを使用していたことがわかりました。私の仕事にはかなり興味深い状況があります(3つの会社、2つの会社の所有者が私の会社から分離した2つの会社)。

B社のシステム管理者がプロキシサーバーを何年も前にループに入れていて、そのすべてを忘れていたことがわかりました。すべての会社のシステム管理者ロール全体を引き継ぐ私の会社のシステム管理者を入力します。誰もプロキシについて彼に話しません。誰も知らないまま何年も実行されています。

1
James F

私のここではCentOS7で、pyspiderを実行してエラーを表示:

Exception HTTP 599 Peer's certificate issuer has been marked as not trusted by the user

そしてそれを修正するために次の手順を使用します:

無効なlibcurl .soファイルを変更します。

/usr/lib64/libcurl.so.4 -> libcurl.so.4.3.0_openssl

有効なlibcurl .soファイルに:

/usr/lib64/libcurl.so.4 -> libcurl.so.4.3.0

そしてpycurlを再インストールします:

pip3 uninstall pycurl
export PYCURL_SSL_LIBRARY=nss
export LDFLAGS=-L/usr/local/opt/openssl/lib;export CPPFLAGS=-I/usr/local/opt/openssl/include;pip install pycurl --compile --no-cache-dir

詳細な説明参照 another SO post

1
crifan