Version 8.6.0 adds 1s delay for FTP SSL connections #12901
I did this
I expected the following
With 8.5.0 it's always below 0.1s:
With 8.6.0 or git master it's reproducably 1s slower:
Looking at the
Unfortunately it appears to be a bit fragile: It is not reproducible when using
curl 8.6.0-DEV (x86_64-suse-linux-gnu) libcurl/8.6.0-DEV OpenSSL/3.1.4 zlib/1.3 brotli/1.1.0 zstd/1.5.5 libidn2/2.3.4 libpsl/0.21.2 (+libidn2/2.3.4)
The text was updated successfully, but these errors were encountered:
Thanks for the report. What I can see here is the regular curl 1 second check on transfers. As you see, the read after the 1sec returns
The read shortly afterwards (probably triggered by a POLLIN) returns data and the TLS handshake continues. It looks like the server is slow responding.
It's not visible which FD it's trying to recv from. I guess it's read on the control vs read on the data channel?
FWICT it's the client.
I was able to reproduce it with
The delay is caused by
It checks for POLLIN for FD 6 but then reads from FD 5.
Thanks, that is very helpful! Could you check if #12913 fixes the issue for you?
The problem was the during setup of the data connection, we stopped polling of the control. This leads to the 1 second timeout until curl auto-checks control again and sees the data from the server. This only stalls transfers if the server stalls the TLS handshake while it is still working on control.
You mean that vsftpd waited until control data was sent before proceeding with the handshake on the data connection?