本文介绍了AWS SES证书验证失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 我已成立了SES成功地在一个AWS实例。现在,我想用它在第二(未克隆)例如,当我运行任何SES脚本,我得到一个错误:I have set up SES successfully on one AWS instance. Now I am trying to use it on a second (not cloned) instance and when I run any of the SES scripts, I get an error:ses-get-stats.pl -k aws-credentials -q我得到:无法连接到email.us-east-1.amazonaws.com:443~~V(证书验证失败)LWP ::协议:: HTTPS ::插座:SSL连接尝试失败,未知errorerror:14090086:SSL例程: SSL3_GET_SERVER_CERTIFICATE:证书验证失败/usr/local/share/perl/5.8.8/LWP/Protocol/http.pm线51获取Perl的东西,工作是一个挑战,有可能我不同做了它的实例。任何地方,我应该寻找解决这一问题?Getting the Perl stuff working was a challenge and it is possible I did it differently on the instance. Any place I should be looking to fix this?当我运行:openssl s_client -CAfile .../cacert.pem -connect email.us-east-1.amazonaws.com:443 < /dev/null我得到:CONNECTED(00000003)depth=1 /C=US/O=VeriSign, Inc./OU=VeriSign Trust Network/OU=Terms of use at https://www.verisign.com/rpa (c)09/CN=VeriSign Class 3 Secure Server CA - G2verify error:num=20:unable to get local issuer certificateverify return:0---Certificate chain 0 s:/C=US/ST=Washington/L=Seattle/O=Amazon.com Inc./CN=email.us-east-1.amazonaws.com i:/C=US/O=VeriSign, Inc./OU=VeriSign Trust Network/OU=Terms of use at https://www.verisign.com/rpa (c)09/CN=VeriSign Class 3 Secure Server CA - G2 1 s:/C=US/O=VeriSign, Inc./OU=VeriSign Trust Network/OU=Terms of use at https://www.verisign.com/rpa (c)09/CN=VeriSign Class 3 Secure Server CA - G2 i:/C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority - G2/OU=(c) 1998 VeriSign, Inc. - For authorized use only/OU=VeriSign Trust Network---Server certificate-----BEGIN CERTIFICATE-----MIIFRDCCBCygAwIBAgIQGcGV1HNHcHHJGun1oi7qbTANBgkqhkiG9w0BAQ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BIshzgVy19RzB2BggrBgEFBQcBAQRqMGgwJAYIKwYBBQUHMAGGGGh0dHA6Ly9vY3NwLnZlcmlzaWduLmNvbTBABggrBgEFBQcwAoY0aHR0cDovL1NWUlNlY3VyZS1HMi1haWEudmVyaXNpZ24uY29tL1NWUlNlY3VyZUcyLmNlcjBuBggrBgEFBQcBDARiMGChXqBcMFowWDBWFglpbWFnZS9naWYwITAfMAcGBSsOAwIaBBRLa7kolgYMu9BSOJsprEsHiyEFGDAmFiRodHRwOi8vbG9nby52ZXJpc2lnbi5jb20vdnNsb2dvMS5naWYwDQYJKoZIhvcNAQEFBQADggEBAF/FIwfH4c0XiIPmF6yKfyiAWp+YuxSteMQzlPluZdxRVdXmukJMABKMbKLyroTV8g9G28aMFIIRYLdCZUHci0mlbeTXmfjpMVIvhWlxYFsE+ZHpC3i77fQMtalv8bmlThjMy9aVMB8xfUzMSvxRJbSdHIATqHx7CI8ogT5xEYrflbPk0J4ba380Vw3VArmNUKv9pYtgStv8YikXMK5ufw0sSBFSo2GAumkvH/DJi8d3AnronpD5WWLs24N6uZCvWqWtKK/FiUhVJUMXrDohrbX+88P5fbVymeOShUiE1bU6sGPbhiHzXH7VvSYHmeaTGUNtjG1aV/pywHMrnJ7V7Xs=-----END CERTIFICATE-----subject=/C=US/ST=Washington/L=Seattle/O=Amazon.com Inc./CN=email.us-east-1.amazonaws.comissuer=/C=US/O=VeriSign, Inc./OU=VeriSign Trust Network/OU=Terms of use at https://www.verisign.com/rpa (c)09/CN=VeriSign Class 3 Secure Server CA - G2---No client certificate CA names sent---SSL handshake has read 3075 bytes and written 300 bytes---New, TLSv1/SSLv3, Cipher is RC4-MD5Server public key is 1024 bitCompression: NONEExpansion: NONESSL-Session: Protocol : TLSv1 Cipher : RC4-MD5 Session-ID: EA1C64EA86BFBE11BE8395F15DBF6B21228719EB215857257CD71AB2EFC3AE9E Session-ID-ctx: Master-Key: 9BFE26D5AFD9C1D222DF73A607CD491F617CD87BC7DCD15904954F198692E22ACACBFAA03A6F10B9F87073DA162B4EB3 Key-Arg : None Start Time: 1302693748 Timeout : 300 (sec) Verify return code: 20 (unable to get local issuer certificate)---DONE这是相同的响应,在哪里ses-get-stats.pl的工作实例。This is the same response as on the instance where ses-get-stats.pl works.创建证书文件所建议的daxim,运行后:After creating a certificate file as suggested by daxim, running:openssl s_client -CAfile test.cer -connect email.us-east-1.amazonaws.com:443 < /dev/null返回: CONNECTED(00000003)depth=2 /C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority - G2/OU=(c) 1998 VeriSign, Inc. - For authorized use only/OU=VeriSign Trust Networkverify return:1depth=1 /C=US/O=VeriSign, Inc./OU=VeriSign Trust Network/OU=Terms of use at https://www.verisign.com/rpa (c)09/CN=VeriSign Class 3 Secure Server CA - G2verify return:1depth=0 /C=US/ST=Washington/L=Seattle/O=Amazon.com Inc./CN=email.us-east-1.amazonaws.comverify return:1---Certificate chain 0 s:/C=US/ST=Washington/L=Seattle/O=Amazon.com Inc./CN=email.us-east-1.amazonaws.com i:/C=US/O=VeriSign, Inc./OU=VeriSign Trust Network/OU=Terms of use at https://www.verisign.com/rpa (c)09/CN=VeriSign Class 3 Secure Server CA - G2 1 s:/C=US/O=VeriSign, Inc./OU=VeriSign Trust Network/OU=Terms of use at https://www.verisign.com/rpa (c)09/CN=VeriSign Class 3 Secure Server CA - G2 i:/C=US/O=VeriSign, Inc./OU=Class 3 Public Primary Certification Authority - G2/OU=(c) 1998 VeriSign, Inc. - For authorized use only/OU=VeriSign Trust Network其次是额外信息,包括证书。followed by additional information including the certificate.推荐答案由于某些原因,你的OpenSSL没有拿到中级证书。 (过时的软件?)For some reason, your OpenSSL does not get the intermediate certificate. (Outdated software?)在https://knowledge.verisign.com/support/ssl-certificates-support/index?page=content&actp=CROSSLINK&id=AR1513.您可以使用它与OpenSSL的工具 -CAfile 参数和环境变量 HTTPS_CA_FILE 对Perl HTTPS协议栈。要使用它的全系统,将其放置在适当的CA证书的目录,例如: 的/ etc / SSL /证书和 c_rehash $ 目录。You can use it with the -CAfile parameter in OpenSSL tools and with the environment variable HTTPS_CA_FILE for the Perl HTTPS stack. To use it system-wide, place it in the appropriate ca-certificates directory, e.g. /etc/ssl/certs, and c_rehash the directory. 这篇关于AWS SES证书验证失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
06-08 12:03