This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: RE: RE: On Porting OpenSSL v1.0.0c


Hi, 

One thing hat comes to mind, error 5 is SSL_ERROR_SYSCALL, see: http://www.openssl.org/docs/ssl/SSL_get_error.html

It also suggests some more debug to use to find out what has happened (for example errno). You can also use something like the following to get a string of the error:

unsigned long l;
while ((l=ERR_get_error()))
{
    printf("ssl error: %s\n", ERR_error_string(l,NULL));
}

Because the underlying transport is not TCP, it might be returning an error because of blocking/non-blocking differences. Also I believe that openssl can use ioctl calls, this may be failing on a serial file descriptor. 

Mark Retallack 

-----Original Message-----
From: ecos-discuss-owner@ecos.sourceware.org [mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Anthony Massa
Sent: 26 April 2011 17:53
To: ecos-discuss@ecos.sourceware.org
Subject: [ECOS] RE: RE: On Porting OpenSSL v1.0.0c

Hi,

I have OpenSSL built into my image (along with a slightly older version of eCos).  I am not able to use the standard socket interface layer over Ethernet - basically the platform I'm using needs to communicate via serial for the network traffic.  So, basically the socket interface functions (connect, send, recv) are implemented to use this serial interface.  I have tested the raw socket interface for the connect, send, and recv functions and they appear to be able to echo with a server properly - so I believe the socket interface is running correctly.

I am running the test code I included above (ssltest.c) and find that the test is failing at line 725 when the SSL_connect function is called.

The output I see and errors returned are shown here:

do the SSL connection
SSL_connect status  -1
SSL_connect Error  5

I appreciate any feedback.

Thanks,
Anthony


--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]