<div dir="ltr">Thanks Viktor.<div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
</span>Client-side sessions can be serialized via i2d_SSL_SESSION and the<br>
resulting binary data can be stored in a file for reuse by a client<br>
via d2i_SSL_SESSION() followed by SSL_set_session() (which copies<br>
the session, so you can free the session obtained via d2i at that<br>
point).<br>
<br></blockquote><div>I did this thing using PEM_write_SSL_SESSION and PEM_write_SSL_SESSION respectively, which seemed to work for the server side session handling. But when I use the above mentioned methods, it gives me that illegal parameter (47) error.</div><div>As a matter of fact, I was able to load the session_id into the Client hello message, and even the server method responded with the same session_id. But the next message was the fatal error which terminated the handshake.</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Of course the client needs to want to reconnect to the same SSL<br>
peer with the same security policy, otherwise session reuse is<br>
unwise.<br>
<span class="HOEnZb"><font color="#888888"><br></font></span></blockquote><div>I ensured I am using the same client_method (security policy), but still can't figure out why the error comes up.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="HOEnZb"><font color="#888888">
--<br>
        Viktor.<br>
--<br>
openssl-users mailing list<br>
To unsubscribe: <a href="https://mta.openssl.org/mailman/listinfo/openssl-users" rel="noreferrer" target="_blank">https://mta.openssl.org/mailman/listinfo/openssl-users</a><br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr">Regards<br>Shubham Chauhan<br>2013099<br>B.Tech CSE</div></div>
</div></div>