[Libwebsockets] Firefox client websocket error

Sumit Dubey sumitd2002 at yahoo.com
Fri Feb 28 09:39:12 CET 2020


 Hi Andy,
I tried with protocols.tx_packet_size=1024 without any effect. I guess this is not an lws problem.Thank you for all your help.
Sumit
    On Thursday, 27 February 2020, 07:03:54 pm GMT+5:30, Andy Green <andy at warmcat.com> wrote:  
 
 

On February 27, 2020 6:59:04 AM GMT, Sumit Dubey <sumitd2002 at yahoo.com> wrote:
>libwebsockets::16::lws_ssl_capable_write failed:
>error:00000005:lib(0):func(0):DH lib, errno 10053

WSAECONNABORTED
10053

Software caused connection abort. An established connection was aborted by the software in your host computer, possibly due to a data transmission time-out or protocol error.

https://docs.microsoft.com/en-us/windows/win32/winsock/windows-sockets-error-codes-2

AFAICT this is "browser hung up on us"... the logs don't show us deciding to hang up on the browser, the first we hear about it is an error writing the rest of the 16KB blob you sent all at once.

-Andy

>Sumit
>On Wednesday, 26 February 2020, 06:05:06 pm GMT+5:30, Andy Green
><andy at warmcat.com> wrote:  
> 
> 
>
>On 2/26/20 12:07 PM, Sumit Dubey wrote:
>> I am on windows.
>
>Hm... what's the openssl version?
>
>Please try this one-line change (just do it by hand is OK)
>
>diff --git a/lib/tls/openssl/openssl-ssl.c
>b/lib/tls/openssl/openssl-ssl.c
>index 2a6ff9527..7feb57bcb 100644
>--- a/lib/tls/openssl/openssl-ssl.c
>+++ b/lib/tls/openssl/openssl-ssl.c
>@@ -352,7 +352,7 @@ lws_ssl_capable_write(struct lws *wsi, unsigned
>char 
>*buf, int len)
>                }
>        }
>
>-      lwsl_debug("%s failed: %s\n",__func__, ERR_error_string(m,
>NULL));
>+      lwsl_debug("%s failed: %s, errno %d\n",__func__, 
>ERR_error_string(m, NULL), LWS_ERRNO);
>        lws_tls_err_describe_clear();
>
>        wsi->socket_is_permanently_unusable = 1;
>
>
>Openssl err 5 is SSL_ERROR_SYSCALL... unfortunately, what that means
>and 
>how to react is platform-dependent, the patch above should make it also
>
>dump errno, please check the logs for "lws_ssl_capable_write failed" 
>after it failed and let's see what it says.
>
>It could be just telling us the other side hung up, or it could be some
>
>errno status we can ignore rather than fail.
>
>-Andy
>
>> Firefox is 73.0.1.
>> 
>> lws is master
>> SHA512 
>>
>0adc438720a2840fdc639c36fc35873133937ab43d4e4579306449d850f44669e2f650773a7cc551b1108bc155ec2fe3b20dd31d4d04bd870e29d7e34a9def1f
>> 
>> (I guess this is the commit no.)
>> 
>> Sumit
>> 
>> 
>> On Wednesday, 26 February 2020, 05:25:55 pm GMT+5:30, Andy Green 
>> <andy at warmcat.com> wrote:
>> 
>> 
>> 
>> 
>> On 2/26/20 11:47 AM, Sumit Dubey wrote:
>>  > Please find attached the lws logs around the time when the
>websocket got
>>  > disconnected.
>> 
>> So you're using h2... you mentioned port 80 so I assumed not
>> 
>>  >  >  >  > /The connection to wss://localhost:80/ was interrupted
>while
>> 
>> Firefox before 72 had a bug with its ws-over-h2 that I reported a
>year
>> ago on 65
>> 
>> https://bugzilla.mozilla.org/show_bug.cgi?id=1528850
>> 
>> they fixed it for 72.
>> 
>> If that's not it, what version of lws is it?  Try it on master if not
>> master.
>> 
>> It's dying here
>> 
>> libwebsockets::16::lws_ssl_capable_write failed:
>> error:00000005:lib(0):func(0):DH lib
>> 
>> that's a bit suspicious, is there something unusual about your
>platform?
>> 
>> 
>> -Andy
>> 
>    
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://libwebsockets.org/pipermail/libwebsockets/attachments/20200228/4312a5c1/attachment-0001.htm>


More information about the Libwebsockets mailing list