From b376979897e07a155fe7d96c15aaaac0b0caaab2 Mon Sep 17 00:00:00 2001 From: Michael Poole Date: Thu, 8 Jun 2006 01:58:36 +0000 Subject: [PATCH] Fix ping timeout handling for outbound server connections. git-svn-id: file:///home/klmitch/undernet-ircu/undernet-ircu-svn/ircu2/branches/u2_10_12_branch@1663 c9e4aea6-c8fd-4c43-8297-357d70d61c8c --- ChangeLog | 5 +++++ ircd/s_auth.c | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/ChangeLog b/ChangeLog index ba89165..b6b666f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2006-06-07 Michael Poole + + * ircd/s_auth.c (auth_ping_timeout): If the client never had an + auth request, kill them on ping timeout. + 2006-06-05 Michael Poole * ircd/s_auth.c (auth_timeout_callback): Clear AR_DNS_PENDING when diff --git a/ircd/s_auth.c b/ircd/s_auth.c index 33e2242..d512b63 100644 --- a/ircd/s_auth.c +++ b/ircd/s_auth.c @@ -733,6 +733,11 @@ int auth_ping_timeout(struct Client *cptr) auth = cli_auth(cptr); + /* Check whether the auth request is gone (more likely, it never + * existed, as in an outbound server connection). */ + if (!auth) + return exit_client_msg(cptr, cptr, &me, "Registration Timeout"); + /* Check for a user-controlled timeout. */ for (flag = 0; flag <= AR_LAST_SCAN; ++flag) { if (FlagHas(&auth->flags, flag)) { -- 2.20.1