I Have faced such behaviour asterisk.
I use local channel. In it there is a certain processing of a call and send it on SIP gateway.
When I call, through this channel, * at first does ANSWER, and only then sends it on SIP:
– Executing [111@test1:1] Dial(“SIP/2903-b7b27620”, “Local/1@call_local/111/n”) in new stack
– Called 1@call_local/111/n
– Executing [1@call_local:1] Dial(“Local/1@call_local-fbe6;2”, “SIP/91231234@cisco5350_1,45,gHh”) in new stack
– Local/1@call_local-fbe6;1 answered SIP/2903-b7b27620
– Called 91231234@cisco5350_1
– Local/1@call_local-fbe6;2 requested special control 20, passing it to SIP/cisco5350_1-09566570
– Local/1@call_local-fbe6;2 requested special control 20, passing it to SIP/cisco5350_1-09566570
– Local/1@call_local-fbe6;2 requested special control 20, passing it to SIP/cisco5350_1-09566570
Because of it asterisk2billing incorrectly considers the beginning of conversation and writes down wrong CDR.
I tested the same design with local channel on asterisk 1.4.26, there all Ok - ANSWER occurs, when comes 200 Ok on SIP:
– Executing [111@test1:1] Dial(“SIP/2903-b7d10518”, “Local/1@call_local/111/n”) in new stack
– Called 1@call_local/111/n
– Executing [1@call_local:1] Dial(“Local/1@call_local-98c3,2”, “SIP/91231234@cisco5350|45|gHh”) in new stack
– Called 91231234@cisco5350
– SIP/cisco5350-098512a0 is making progress passing it to Local/1@call_local-98c3,2
– Local/1@call_local-98c3,1 is making progress passing it to SIP/2903-b7d10518
– SIP/cisco5350-098512a0 answered Local/1@call_local-98c3,2
– Local/1@call_local-98c3,1 answered SIP/2903-b7d10518
How to change behaviour asterisk 1.6. that ASNWER in local channel occurred only after ANSWER will come on SIP?