简体   繁体   English

由于设置`set_verify_mode(boost :: asio :: ssl :: verify_none);而导致的安全后果`

[英]Security consequences due to setting `set_verify_mode(boost::asio::ssl::verify_none);`

I'm using this example as a template in a server/client pair I wrote. 将此示例用作我编写的服务器/客户端对中的模板。 I honestly don't understand all the details on how the secure connection is done. 老实说,我不了解有关如何完成安全连接的所有详细信息。 I understand the simple private/public RSA encryption. 我了解简单的私有/公共RSA加密。 We encrypt with a public key, and only private keys can open it. 我们使用公钥加密,只有私钥才能打开它。 Is it as simple here? 这里简单吗? (this is not the real question here) (这不是真正的问题)

So my question is: In my client part I used set_verify_mode(boost::asio::ssl::verify_none); 所以我的问题是:在我的客户端部分中,我使用了set_verify_mode(boost::asio::ssl::verify_none); . Does this jeopardize the secure connection I'm using? 这会危害我正在使用的安全连接吗? Is the connection still secure and encrypted? 连接仍然安全和加密吗?

No, it's not safe setting SSL_VERIFY_NONE. 不,设置SSL_VERIFY_NONE是不安全的。 In this case if someone attack the connection the client won't be able to verify the sender's identity. 在这种情况下,如果有人攻击连接,则客户端将无法验证发件人的身份。

Detailed description of server and client behaviour for each flags on openssl site: openssl站点上每个标志的服务器和客户端行为的详细说明:

https://www.openssl.org/docs/manmaster/ssl/SSL_CTX_set_verify.html https://www.openssl.org/docs/manmaster/ssl/SSL_CTX_set_verify.html

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM