[asterisk-dev] Wrong SIP to SIP SIP Cause mapping
Matthew Jordan
mjordan at digium.com
Fri May 25 11:10:29 CDT 2012
----- Original Message -----
> From: "Pavel Troller" <patrol at sinus.cz>
> To: "Asterisk Developers Mailing List" <asterisk-dev at lists.digium.com>
> Sent: Friday, May 25, 2012 10:59:24 AM
> Subject: Re: [asterisk-dev] Wrong SIP to SIP SIP Cause mapping
>
> Hi!
>
> Oh, Mamma mia, Alex is right!!!!
> I've just tested a void public number through PRI and I've got CC=1
> -
> Unallocated number.
> Then I dialled the same number through SIP trunk and I've got
> CC=34,
> but on the SIP the response code was really 404 Not Found, which is
> equivalent to 1 - Unallocated number.
> Something is really broken here! Of course I'm paying attention to
> $HANGUPCAUSE and I'm handling it in my own intercept scripts, and
> they
> are proved OK, so the problem must be in wrong $HANGUPCAUSE contents.
> It's 1.8 branch.
> I hope I will find the cause soon and I'll post it here.
> With regards, Pavel.
>
As has already been pointed out, Asterisk is a B2BUA, not a proxy. There
is no guarantee that a response from one UA will be 'passed through'
Asterisk to another UA. I won't weigh in on whether or not this qualifies
as a bug or merely a change in behavior. The fact that Asterisk is not a
proxy gives weight to this being not a bug; that being said, there is a
definite difference between a 4xx and a 5xx response, which would give some
weight to this being a bug.
The change in behavior was mostly likely introduced by r351130. This fixed
some issues wherein, on a response to a 404, merely queueing a congestion
control frame was not sufficient to tear down the channel. The congestion
control frame was replaced with an explicit channel hang up with a cause of
AST_CAUSE_CONGESTION, which maps to a SIP response type of "503".
--
Matthew Jordan
Digium, Inc. | Software Developer
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
Check us out at: http://digium.com & http://asterisk.org
More information about the asterisk-dev
mailing list