HELP: Client-Server code for anonymous authentication NOT working

Mihir Kulkarni mihirk.31 at gmail.com
Mon Feb 6 03:06:12 CET 2012


Hello,
I am part of a team at University of California, Irvine who are trying our
hand at GNUTLS. We installed the package and all its dependencies. But when
trying with the example code given in the documentation, it throws up an
error. The details are:
I tried running the server and client with anonymous authentication. The
exact error that it gives is:

*CLIENT:*
mihir at GNU-Linux:~/GNUTLS/gnutls-2.8.6/client$ ./a.out
*** Handshake failed
GNUTLS ERROR: A TLS packet with unexpected length was received.

*SERVER:*
mihir at GNU-Linux:~/GNUTLS/gnutls-2.8.6/server$ ./a.out
Server ready. Listening to port '5556'.

- connection from 127.0.0.1, port 48108
*** Handshake has failed (A TLS packet with unexpected length was received.)

What is figured out so far is that the server goes into an infinite loop on
line 120 for the statements:
       do
        {
           ret = gnutls_handshake (session);
           printf("Do...\n");
         }
       while (gnutls_error_is_fatal (ret) == 0);


Can someone please tell me what might be going wrong?
Thank you for your help.

regards,
Mihir Kulkarni
Graduate Student
University of California, Irvine
http://goo.gl/CvRcG
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/attachments/20120205/64140178/attachment.htm>


More information about the Gnutls-help mailing list