<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[wolfSSL - Embedded SSL Library — SSL_ERROR_WANT_READ after successful call to SSL_write()]]></title>
		<link>https://www.wolfssl.com/forums/topic87-sslerrorwantread-after-successful-call-to-sslwrite.html</link>
		<atom:link href="https://www.wolfssl.com/forums/feed-rss-topic87.xml" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in SSL_ERROR_WANT_READ after successful call to SSL_write().]]></description>
		<lastBuildDate>Tue, 15 Mar 2011 23:34:10 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: SSL_ERROR_WANT_READ after successful call to SSL_write()]]></title>
			<link>https://www.wolfssl.com/forums/post184.html#p184</link>
			<description><![CDATA[<p>Thanks, you&#039;re right, having SSL_ERROR_NONE when result &gt; 0 is more compatible with OpenSSL.&nbsp; I&#039;ve put it into our latest patch of our embedded SSL library which should be available tomorrow on github.</p>]]></description>
			<author><![CDATA[null@example.com (todd)]]></author>
			<pubDate>Tue, 15 Mar 2011 23:34:10 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post184.html#p184</guid>
		</item>
		<item>
			<title><![CDATA[SSL_ERROR_WANT_READ after successful call to SSL_write()]]></title>
			<link>https://www.wolfssl.com/forums/post182.html#p182</link>
			<description><![CDATA[<p>I have set up wolfSSL to do an asynchronous connect/accept. The idea is that SSL data is sent immediately, and there is no blocking to receive; instead, the SSL data from the other side is handled when it arrives. This is working well; the only thing I had to work out was what happens after the connection is set up, but before any application data has been received. In this case, the last call to SSL_read() finished the connection handshake, and then (since there was no more data), the ssl-&gt;error is set to WANT_READ. Now if I call SSL_write, it will succeed, (it returns the number of bytes written, rather than a negative error number). However, when I call SSL_get_error(ssl, result), it still returns SSL_ERROR_WANT_READ (rather than the SSL_ERROR_NONE which would be returned by OpenSSL).</p><p>This is not really a bug so much as a difference between wolfSSL and OpenSSL, so I&#039;m not sure if you want to fix it or not. I can just check the return value from SSL_write() and only call SSL_get_error() if SSL_write returns &lt;= 0. Another option is to change the SSL_get_error(ssl, result) function so that it returns SSL_ERROR_NONE if result is &gt; 0.</p><p>-Ken</p>]]></description>
			<author><![CDATA[null@example.com (kmackay)]]></author>
			<pubDate>Tue, 15 Mar 2011 23:03:14 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post182.html#p182</guid>
		</item>
	</channel>
</rss>
