Topic: VERSION_ERROR -226 record layer version error

Hi,

I downloaded wolfSSL 2.4.0 to Windows 7 and compiled with VS 2008. But when I'm running the client example, I'm facing troubles.

.\Release\client -h www.gmail.com -p 443 -d -g

...  this works ... gmail sends me a web page.

but any other domain I tried fails ( outside google scene ). For example:

D:\projects\cyassl-2.4.0>.\Release\client -h www.yassl.com -p 443 -d -g

err = -226, record layer version error
yassl error: SSL_connect failed


any advices ?

thanks

Share

Re: VERSION_ERROR -226 record layer version error

Hi hasa,

err = -226, record layer version error

This is typically due to the wolfSSL client trying to connect to the target server with a different version of SSL/TLS than what the server supports.  By default, the wolfSSL client tries to connect with TLS 1.2, which not all servers support.  You can tell the wolfSSL client what SSL/TLS version to connect with by using the "-v" command line option, where:

-v 0 = SSL 3.0
-v 1 = TLS 1.0
-v 2 = TLS 1.1
-v 3 = TLS 1.2

Try switching the SSL version when running the wolfSSL client and see if that clears up the error you are seeing.

Best Regards,
Chris

Re: VERSION_ERROR -226 record layer version error

Thanks chrisc !  For some unknown reason no value between 0-3 works against www.yassl.com but -v 0 works with my dev server and it is enough by now.  smile

Share

Re: VERSION_ERROR -226 record layer version error

Hi hasa,

The reason that the client fails to connect to www.yassl.com is that we don't currently have SSL setup on our web hosting server.  You'll probably get a similar error if you try to connect with HTTPS from your browser as well.  For example:

https://www.yassl.com

Because we don't conduct any sort of electronic transactions or transmit personal data, we haven't had the need for it yet.  This means that the wolfSSL embedded SSL client is working correctly.

Best Regards,
Chris