[Asterisk-code-review] chan sip.c: wrong peer searched in sip report security event (asterisk[13])

Kevin Harwell asteriskteam at digium.com
Thu Aug 13 15:01:30 CDT 2015


Hello Anonymous Coward #1000019,

I'd like you to reexamine a change.  Please visit

    https://gerrit.asterisk.org/1082

to look at the new patch set (#2).

Change subject: chan_sip.c: wrong peer searched in sip_report_security_event
......................................................................

chan_sip.c: wrong peer searched in sip_report_security_event

In chan_sip, after handling an incoming invite a security event is raised
describing authorization (success, failure, etc...). However, it was doing
a lookup of the peer by extension. This is fine for register messages, but
in the case of an invite it may search and find the wrong peer, or a non
existent one (for instance, in the case of call pickup). Also, if the peers
are configured through realtime this may cause an unnecessary database lookup
when caching is enabled.

This patch makes it so that sip_report_security_event searches by IP address
when looking for a peer instead of by extension after an invite is processed.

ASTERISK-25320 #close

Change-Id: I9b3f11549efb475b6561c64f0e6da1a481d98bc4
---
M channels/chan_sip.c
M channels/sip/include/security_events.h
M channels/sip/security_events.c
3 files changed, 7 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/82/1082/2
-- 
To view, visit https://gerrit.asterisk.org/1082
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I9b3f11549efb475b6561c64f0e6da1a481d98bc4
Gerrit-PatchSet: 2
Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-Owner: Kevin Harwell <kharwell at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019



More information about the asterisk-code-review mailing list