Forum > Networking and Web Programming

THTTPApplication blocked by telnet connection

<< < (2/2)

zeljko:
Found that problem is in ssl_accept() which blocks forever on eg telnet connection, no idea how to fix this (opensslsockets.pp function TOpenSSLSocketHandler.Accept: Boolean). Maybe using select() ? Any ideas ?

zeljko:
Ok, solved by using fpAlarm() inside TOpenSSLSocketHandler.Accept...don't know if it's best solution but it works :)

Remy Lebeau:

--- Quote from: zeljko on June 21, 2024, 01:44:49 pm ---Found that problem is in ssl_accept() which blocks forever on eg telnet connection

--- End quote ---

Makes sense, but even so, I would still expect the HTTP server to be able to accept other clients while the Telnet client is blocked.

zeljko:
Gnutls have ability to timeout handshake for such connections, but openssl  does not, so as I can see by googling alarm is one of the solutions (unix only, don't know if there's anything like fpAlarm on windows)

Navigation

[0] Message Index

[*] Previous page

Go to full version