Why am I getting “Connection reset by peer” with Indy only on a HTTPS (SSL) site?

杀马特。学长 韩版系。学妹 提交于 2019-12-01 13:03:48

I was able to reproduce the issue, and it is due to Indy's TIdIOHandlerSocketOpenSSL component only enabling TLS v1.0 by default.

Like many other sites nowadays, AdultWorks does not accept TLS 1.0 anymore. In fact, it doesn't accept TLS 1.1, either. It requires TLS 1.2. Once I enabled TLS 1.2 in the IOHandler's SSLVersions property, TIdHTTP.Get() was able to access the site without error.

Thanks both for pointing in the right direction! Seems like besides the TLS 1.2 part, I was also using outdated dlls. Using updated dlls and the TLS 1.2 version made things work.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!