yuanyuanxiang and deepseek-flash
5ee59415f9
Fix: throttle TLS/WS handshake failure logs
...
Exposed ports see a constant stream of scanners and HTTP probes. Every TLS
handshake attempt logged an ioctlsocket(FIONBIO=0) failure, but WSAEINVAL is
the documented result once WSAEventSelect owns the listening socket and the
code already falls back to select; that line alone accounted for 6678 of the
8970 "handshake" lines in a four-day log. It is now logged only for other
error codes.
A failed handshake used to print three or four lines (recv EOF,
AcceptSecurityContext, final status, failed-for-IP) with no per-peer dedup,
and WS upgrade failures printed once per HTTP probe. ServerTlsSession now
records a human-readable reason (Schannel status name for ASC failures)
instead of logging per connection; IOCPServer prints one line per peer per
hour with the reason and a suppressed count, for both TLS and WS. Peer
close_notify is a normal shutdown and is no longer logged; MCP TLS failures
now carry the same reason.
Failure details are copied before the context's I/O reference is released,
so the log path cannot touch a context that another thread may recycle. No
handshake, crypto or connection behaviour changes.
Verified with a Debug x64 build and a live probe run: six failed connections
to the device port produced exactly one TLS and one WS line, with no
ioctlsocket lines.
Co-Authored-By: deepseek-flash
2026-12-05 10:50:50 +01:00
..
2026-10-09 16:23:23 +02:00
2026-12-01 20:52:49 +01:00
2026-04-19 22:55:21 +02:00
2026-10-29 16:12:14 +01:00
2026-11-27 21:01:53 +01:00
2026-04-19 22:55:21 +02:00
2026-10-20 21:48:13 +02:00
2026-11-29 20:34:08 +01:00
2026-11-15 20:43:28 +01:00
2026-04-19 22:55:21 +02:00
2026-12-01 20:52:49 +01:00
2026-04-19 22:55:21 +02:00
2026-11-29 22:57:43 +01:00
2026-12-01 20:52:49 +01:00
2026-12-01 18:32:12 +01:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-05-23 13:37:28 +02:00
2026-11-16 18:36:48 +01:00
2026-10-15 13:48:27 +02:00
2026-10-15 13:48:27 +02:00
2026-11-30 12:49:54 +01:00
2026-11-30 12:49:54 +01:00
2026-11-06 12:13:07 +01:00
2026-11-06 12:13:07 +01:00
2026-08-20 17:54:33 +02:00
2026-08-15 11:09:14 +02:00
2026-10-10 13:58:38 +02:00
2026-04-19 22:55:21 +02:00
2026-11-30 13:30:58 +01:00
2026-11-30 13:30:58 +01:00
2026-10-08 22:15:31 +02:00
2026-10-08 22:15:31 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-10-08 21:53:53 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-09-03 13:29:39 +02:00
2026-09-03 13:29:39 +02:00
2026-11-26 20:56:19 +01:00
2026-06-20 13:01:35 +02:00
2026-10-24 15:45:49 +02:00
2026-10-24 15:45:49 +02:00
2026-11-02 19:39:17 +01:00
2026-10-04 18:23:06 +02:00
2026-11-29 20:34:08 +01:00
2026-11-26 20:56:19 +01:00
2026-05-22 00:31:54 +02:00
2026-10-08 21:53:53 +02:00
2026-04-19 22:55:21 +02:00
2026-05-05 21:21:38 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-09-06 09:39:59 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-11-01 20:40:02 +01:00
2026-11-01 20:40:02 +01:00
2026-11-06 17:17:18 +01:00
2026-11-07 15:34:45 +01:00
2026-04-19 22:55:21 +02:00
2026-11-05 14:22:12 +01:00
2026-11-05 14:22:12 +01:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-11-29 20:34:08 +01:00
2026-08-20 16:36:30 +02:00
2026-04-19 22:55:21 +02:00
2026-10-21 20:01:41 +02:00
2026-08-16 14:37:11 +02:00
2026-11-01 14:33:58 +01:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-11-29 20:34:08 +01:00
2026-11-29 20:34:08 +01:00
2026-12-05 10:50:50 +01:00
2026-10-30 17:22:17 +01:00
2026-11-29 14:31:41 +01:00
2026-11-29 14:31:41 +01:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-10-12 15:41:24 +02:00
2026-05-11 20:22:07 +02:00
2026-12-01 20:52:49 +01:00
2026-05-27 15:28:56 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-07-16 00:10:12 +02:00
2026-07-16 00:10:12 +02:00
2026-04-19 22:55:21 +02:00
2026-11-15 20:43:28 +01:00
2026-11-15 20:43:28 +01:00
2026-11-13 12:23:39 +01:00
2026-10-23 11:19:21 +02:00
2026-11-15 20:43:28 +01:00
2026-11-13 13:12:10 +01:00
2026-11-13 12:43:37 +01:00
2026-10-21 20:01:41 +02:00
2026-11-16 21:26:19 +01:00
2026-11-15 20:43:28 +01:00
2026-11-28 10:27:20 +01:00
2026-11-26 18:41:06 +01:00
2026-12-05 10:50:50 +01:00
2026-10-26 13:56:41 +01:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-08-05 20:07:21 +02:00
2026-10-10 13:58:38 +02:00
2026-04-19 22:55:21 +02:00
2026-10-04 14:39:38 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-10-08 21:53:53 +02:00
2026-04-25 17:30:07 +02:00
2026-11-11 13:44:49 +01:00
2026-05-13 13:05:31 +02:00
2026-11-28 20:09:39 +01:00
2026-04-19 22:55:21 +02:00
2026-10-08 21:53:53 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-11-29 20:34:08 +01:00
2026-11-20 14:31:22 +01:00
2026-11-20 14:31:22 +01:00
2026-11-07 15:34:45 +01:00
2026-11-07 15:34:45 +01:00
2026-11-23 17:46:36 +01:00
2026-11-29 14:31:41 +01:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-12-05 10:50:50 +01:00
2026-12-05 10:50:50 +01:00
2026-10-30 17:22:17 +01:00
2026-10-30 17:22:17 +01:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-11-29 22:57:43 +01:00
2026-11-29 22:57:43 +01:00
2026-09-11 16:28:37 +02:00
2026-09-11 16:28:37 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-10-19 10:05:58 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-11-06 17:17:18 +01:00
2026-10-09 14:05:52 +02:00
2026-08-13 12:59:29 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-05-10 17:36:46 +02:00
2026-11-06 12:13:07 +01:00
2026-11-06 12:13:07 +01:00
2026-11-07 15:45:48 +01:00
2026-11-07 15:45:48 +01:00
2026-10-08 21:53:53 +02:00
2026-10-06 17:50:30 +02:00
2026-04-19 22:55:21 +02:00
2026-04-19 22:55:21 +02:00
2026-11-28 11:10:16 +01:00
2026-11-16 18:36:48 +01:00
2026-11-16 18:36:48 +01:00
2026-05-17 18:46:21 +02:00
2026-11-10 19:13:45 +01:00
2026-11-10 19:13:45 +01:00
2026-04-19 22:55:21 +02:00
2026-05-30 18:10:15 +02:00
2026-05-30 18:10:15 +02:00