Partially fix bug #117 - tls_require ignored entirely in 0.3.0 released
If tls_require is enabled then the hub will simply close the connection if a user connects without TLS. In the future we should redirect the user either to another server or to the adcs server.
This commit is contained in:
parent
1a98bb6810
commit
0de66286fa
@ -46,6 +46,13 @@ static void probe_net_event(struct net_connection* con, int events, void *arg)
|
||||
if (memcmp(probe_recvbuf, "HSUP", 4) == 0)
|
||||
{
|
||||
LOG_TRACE("Probed ADC");
|
||||
#ifdef SSL_SUPPORT
|
||||
if (probe->hub->config->tls_enable && probe->hub->config->tls_require)
|
||||
{
|
||||
LOG_TRACE("Not TLS connection - closing connection.");
|
||||
}
|
||||
else
|
||||
#endif
|
||||
if (user_create(probe->hub, probe->connection, &probe->addr))
|
||||
{
|
||||
probe->connection = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user