1 (edited by Zeddi 2014-01-08 00:20:16)

Topic: [SOLVED] Build error with TEST_IPV6 and HAVE_OCSP defined

Testing my work-in-progress port on eCos, I stumbled across a build error in src/io.c when TEST_IPV6 and HAVE_OCSP are defined together.

I verified this error on Cygwin x32 on my Windows 7 machine with wolfSSL 2.7.0 (got the same error with 2.8.0 as well):

src/io.c: In function 'tcp_connect':
src/io.c:513:5: warning: array subscript has type 'char' [-Wchar-subscripts]
src/io.c:536:9: error: 'SOCKADDR_IN_T' has no member named 'sin_family'
src/io.c:537:9: error: 'SOCKADDR_IN_T' has no member named 'sin_port'
src/io.c:539:13: error: 'SOCKADDR_IN_T' has no member named 'sin_addr'
src/io.c:541:13: error: 'SOCKADDR_IN_T' has no member named 'sin_addr'

The problem seems to be that the TEST_IPV6-define is tested and depending on this, the SOCKADDR_IN_T and AF_INET_V are set, but the remaining code is not fully IPv6-aware.

I saw that the IPv6 handling inside wolfssl/test.h looks more thorough which made me wonder why it's handled in two different ways.

Can you please confirm whether this is a bug and if/when it will be resolved (perhaps with 2.9.0)?

Kind regards
- Daniel

Share

Re: [SOLVED] Build error with TEST_IPV6 and HAVE_OCSP defined

Hi Daniel,

Thanks for bringing this to our attention.  Yes, this is something we will need to fix.  wolfssl/test.h is used in our example applications which have had IPv6 support for quite a while now, where OCSP was added more recently.

We'll put this on our todo list, but I can't give you a definitive timeline at the moment.  How pressing is this fix for you?

Thanks,
Chris

3 (edited by Zeddi 2013-11-27 02:13:13)

Re: [SOLVED] Build error with TEST_IPV6 and HAVE_OCSP defined

Hi Chris,

thanks for the quick response.
In theory, I would need this quite soon as OCSP with IPv6 is one of the requirements I have for my application.
You don't have to rush onto this though, because I'm quite sure that I can tinker with the code to get it working myself and substitute the corresponding code with a clean fix from you guys later on.

Regards
- Daniel

Share

Re: [SOLVED] Build error with TEST_IPV6 and HAVE_OCSP defined

I have fixed this with commit fe4f104. It'll be rolled into the next embedded SSL release.