File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -6297,16 +6297,15 @@ static void event_new_fd(void *ctx)
62976297 this -> dead = true;
62986298
62996299 remove_now :
6300- #ifdef WITH_TLS
6301- /*
6302- * Close it. Which sets the status to EOL, so we
6303- * have to update that, too.
6304- *
6305- * proxy_tls_close also clears this->tls, so it's
6306- * safe run this check multiple times, as the
6307- * second time it won't close the same socket.
6308- */
6309- if ((this -> type == RAD_LISTEN_PROXY ) && this -> tls ) {
6300+ sock = this -> data ;
6301+
6302+ #if defined(WITH_PROXY ) && defined(WITH_TLS )
6303+ if ((this -> type == RAD_LISTEN_PROXY ) && sock -> ssn ) {
6304+ /*
6305+ * Close it. Which sets the status to EOL, so we
6306+ * have to update that, too.
6307+ */
6308+ sock -> client_closed = true; /* no need to call SSL_shutdown() */
63106309 proxy_tls_close (this );
63116310 this -> status = RAD_LISTEN_STATUS_REMOVE_NOW ;
63126311 }
@@ -6356,7 +6355,6 @@ static void event_new_fd(void *ctx)
63566355#endif
63576356 ) {
63586357 home_server_t * home ;
6359- sock = this -> data ;
63606358
63616359 home = sock -> home ;
63626360 if (!home || !home -> limit .max_connections ) {
Original file line number Diff line number Diff line change @@ -92,6 +92,7 @@ void tls_socket_close(rad_listen_t *listener)
9292 ROPTIONAL (RDEBUG3 , DEBUG3 , "(TLS) Closing connection" );
9393 rad_free (& sock -> packet );
9494 TALLOC_FREE (sock -> request );
95+ TALLOC_FREE (sock -> ssn );
9596 radius_update_listener (listener );
9697
9798 /*
You can’t perform that action at this time.
0 commit comments