report IP of peer who sent failing registration (bug #4089)
authorKevin P. Fleming <kpfleming@digium.com>
Wed, 27 Apr 2005 02:52:14 +0000 (02:52 +0000)
committerKevin P. Fleming <kpfleming@digium.com>
Wed, 27 Apr 2005 02:52:14 +0000 (02:52 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@5511 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_iax2.c

index 7b05361..d9e224a 100755 (executable)
@@ -7182,7 +7182,7 @@ retryowner2:
                        case IAX_COMMAND_REGREJ:
                                if (iaxs[fr.callno]->reg) {
                                        if (authdebug) {
-                                               ast_log(LOG_NOTICE, "Registration of '%s' rejected: %s\n", iaxs[fr.callno]->reg->username, ies.cause ? ies.cause : "<unknown>");
+                                               ast_log(LOG_NOTICE, "Registration of '%s' rejected: '%s' from: '%s'\n", iaxs[fr.callno]->reg->username, ies.cause ? ies.cause : "<unknown>", ast_inet_ntoa(iabuf, sizeof(iabuf), sin.sin_addr));
                                                manager_event(EVENT_FLAG_SYSTEM, "Registry", "Channel: IAX2\r\nUsername: %s\r\nStatus: Rejected\r\nCause: %s\r\n", iaxs[fr.callno]->reg->username, ies.cause ? ies.cause : "<unknown>");
                                        }
                                        iaxs[fr.callno]->reg->regstate = REG_STATE_REJECTED;