]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
Added documentation of rehandshake usage in gnutls if full-duplex capability is required.
authorNikos Mavrogiannopoulos <nmav@gnutls.org>
Thu, 21 Jan 2010 08:44:38 +0000 (09:44 +0100)
committerNikos Mavrogiannopoulos <nmav@gnutls.org>
Thu, 21 Jan 2010 08:44:38 +0000 (09:44 +0100)
lib/gnutls_handshake.c

index b4e81649bb55a17c396e95f2a0142cb893e399e6..618b20c506d261d071897ec15f0c3a1e706de054 100644 (file)
@@ -1257,7 +1257,6 @@ _gnutls_recv_handshake_header (gnutls_session_t session,
 
       if (ret < 0)
        {
-         gnutls_assert ();
          return ret;
        }
 
@@ -2520,6 +2519,13 @@ _gnutls_recv_hello (gnutls_session_t session, opaque * data, int datalen)
   * gnutls_handshake() function in order to negotiate the new
   * parameters.
   *
+  * Since TLS is full duplex some application data might have been
+  * sent during peer's processing of this message. In that case
+  * one should call gnutls_record_recv() until GNUTLS_E_REHANDSHAKE
+  * is returned to clear any pending data. Care must be taken if
+  * rehandshake is mandatory to terminate if it does not start after
+  * some threshold.
+  *
   * If the client does not wish to renegotiate parameters he will
   * should with an alert message, thus the return code will be
   * %GNUTLS_E_WARNING_ALERT_RECEIVED and the alert will be