]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
If peer fails ACL check, fail peer at REGISTER
authorOlle Johansson <oej@edvina.net>
Tue, 31 Oct 2006 09:17:53 +0000 (09:17 +0000)
committerOlle Johansson <oej@edvina.net>
Tue, 31 Oct 2006 09:17:53 +0000 (09:17 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@46606 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_sip.c

index d994e973116d5cec5e24ab3c7c3d1347cbd17d5a..b5f15cff4912d0dfcdd50ce2e316e25644db3c2d 100644 (file)
@@ -8105,8 +8105,10 @@ static enum check_auth_result register_verify(struct sip_pvt *p, struct sockaddr
        build_contact(p);
        peer = find_peer(name, NULL, 1);
        if (!(peer && ast_apply_ha(peer->ha, sin))) {
+               /* Peer fails ACL check */
                if (peer)
                        ASTOBJ_UNREF(peer, sip_destroy_peer);
+               peer = NULL;
        }
        if (peer) {
                /* Set Frame packetization */