TCP + TLS receive error 8E00 (36352)

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
NiMc_1688136
Level 5
Level 5
10 sign-ins 50 questions asked 10 solutions authored

On rare occasions while pulling an OTA image from a server using TCP i get a result of 36352 returned from wiced_tcp_receive. This error is persistent while the transfer is pending even with the socket closing and reopening.

I am not sure where this return code is coming from. I have searched the return codes within mbedTLS and LWIP and i am not seeing a match.

The connection to the server succeeded, TLS handshake succeeded, initial communication with the server is working so i do not see a TLS or communication error.

FreeRTOS + LWIP + 6.2.1 SDK

I have no logs/captures with WPRINT_SECURITY_DEBUG or WPRINT_SECURITY_ERROR enabled.

0 Likes
3 Replies
RaktimR_11
Moderator
Moderator
Moderator
500 replies posted 250 replies posted 100 replies posted

Even I did a text search in the whole SDK for 36352; but not a single hit. My suggestion would be to have the debug macros enabled and check when you receive the error, is there any additional debug prints?

Also, when the socket is reopened, do you receive that packet or the packet is lost and the image transfer gets stopped?

0 Likes

Upon further investigation i see the errors over a larger population of our devices and in other TCP sockets/connections Many of these devices are running production code or at customer sites where serial logging is impossible so I will see what I can do to log additional information.

I also see other invalid values returned from wiced_tcp_receive

34688 (0x8780)

36480 (0x8E80)

I am periodically polling the socket for received data through wiced_tcp_receive. I currently treat these unknown return values as a general error that triggers the connection to be closed. I wonder what would happen if i ignore it.

0 Likes

I enabled

WPRINT_ENABLE_WWD_ERROR

WPRINT_ENABLE_SECURITY_INFO

WPRINT_ENABLE_SECURITY_ERROR

I did not see anything reported when i encountered the strange return values, in this case it was 36480.

0 Likes