Hello jacks004,
A 10-second delay occurs when TlsHostCertificateFingerprint doesn’t match, due to the client retrying before failing the TLS handshake.
I don't think so.
We can see in the session log that there is indeed a question (that we can't see using scripting) and exactly 10 seconds after that, WinSCP cancels the session :
< 2025-06-30 11:03:20.874 If you trust this certificate, press Yes. To connect without storing certificate, press No. To abandon the connection press Cancel.
< 2025-06-30 11:03:20.874 Continue connecting and store the certificate?
. 2025-06-30 11:03:30.877 Answer: Cancel
. 2025-06-30 11:03:30.877 Peer certificate rejected.
And the corresponding extended debug log shows the wait loop :
[2025-06-30 11:03:20.876] [0004] ExeSessionProcess.ProcessEvent entering
[2025-06-30 11:03:20.876] [0004] Acquiring communication structure
[2025-06-30 11:03:20.876] [0004] Acquired communication structure
[2025-06-30 11:03:20.876] [0004] ExeSessionProcess.ProcessChoiceEvent entering
[2025-06-30 11:03:20.876] [0004] Options: [YNAC], Timer: [10000], Timeouting: [True], Timeouted: [-2], Break: [-1]
[2025-06-30 11:03:20.906] [0001] Waiting for log update and dispatching events for 200
[2025-06-30 11:03:21.105] [0001] Waiting for log update and dispatching events for 400
[2025-06-30 11:03:21.502] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:22.315] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:23.130] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:23.941] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:24.751] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:25.565] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:26.377] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:27.189] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:28.002] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:28.815] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:29.628] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:30.441] [0001] Waiting for log update and dispatching events for 800
[2025-06-30 11:03:30.877] [0004] Options Result: [-2]
[2025-06-30 11:03:30.877] [0004] ExeSessionProcess.ProcessChoiceEvent leaving
[2025-06-30 11:03:30.877] [0004] Releasing communication structure
[2025-06-30 11:03:30.877] [0004] Released communication structure
[2025-06-30 11:03:30.877] [0004] Response event set
[2025-06-30 11:03:30.877] [0004] ExeSessionProcess.ProcessEvent leaving