Summary:ASTERISK-13531: [patch] Caller ID is missing for h323 calls.
Reporter:Naren Jayabalu (jnaren)Labels:
Date Opened:2009-02-06 08:39:29.000-0600Date Closed:2011-06-07 14:07:20
Versions:Frequency of
Environment:Attachments:( 0) bug14424.patch
( 1) h323capture
Description:Hi I am running

*CLI> core show version
Asterisk built by root @ box on a i686 running Linux on 2009-01-26 17:15:21 UTC

Extensions.conf has

exten => _8.,1,AGI(meta.agi,${EXTEN},${STRFTIME(${EPOCH},,%d-%b-%Y %H:%M:%S)},${CALLERID(ani)},${CALLERID(ani2)},${CALLERID(all)},${CALLERID(dnid)},${CALLERID(num)},${CALLERID(rdnis)},${CALLERID(num)},${CALLINGANI2}})

When a h323 calls comes in I do not get any callerid passed to the agi as parameters.

*CLI>     -- Executing [888112@default:1] AGI("H323/ip$MYIP:27863/23707", "meta.agi,888112,06-Feb-2009 14:28:31,,0,"" <>,888112,,,,0}") in new stack

when a sip call comes in i get the caller id.

Executing [888112@default:1] AGI("SIP/ASTIP-082593b8", "meta.agi,888112,06-Feb-2009 14:30:29,2073081111,0,"" <2073081111>,888112,2073081111,,2073081111,0}") in new stack

The calls work fine. No problem in both cases, but the Caller id is missing for h323 calls.


I am new to the asterisk world. Please help.
Comments:By: Leif Madsen (lmadsen) 2009-02-13 13:37:11.000-0600

Hey Jeff,

I didn't want to go ahead and assign this to you, but I was wondering if you might be able to take a look at this and determine why this might be happening? Do you think this is a configuration issue, or is there a possible bug here?

By: Jeff Peeler (jpeeler) 2009-02-17 15:25:21.000-0600

I'm assigning this to myself so I don't forget about it.

By: Daniel C (dalbaech) 2009-02-24 18:45:55.000-0600


Just in case you're using CCM, this happens by default if CCM was sending the call and the Gateway wasn't properly configured. On all of the "presentations" for the gateway, make sure it's all set to Allowed.


By: Naren Jayabalu (jnaren) 2009-02-25 04:43:37.000-0600

Hi Daniel.

We are using Quintum CMS and the caller id is passed to other softswitches and gateways without any problems. I am using the same settings for researching with asterisk. The same quintum gateway is used for sending the above sip call to asterisk which works fine.

If you require more information please let me know.




By: Daniel C (dalbaech) 2009-02-25 11:02:00.000-0600


I believe that this has been resolved in Asterisk I am unable to reproduce this error using the current version.

Here's my AGI script:
use Asterisk::AGI;
$AGI = new Asterisk::AGI;

my %input = $AGI->ReadParse();

my $target      = 0;
my $try         = 0;

$AGI->exec('AGI',"swift.agi,Your caller ID is: $ARGV[0]");
$AGI->exec('AGI',"swift.agi,'Your name field is: $ARGV[1]");

Here's my call:
exten => s,n,AGI(callerids.agi,${CALLERID(num)},${CALLERID(name)})


By: Leif Madsen (lmadsen) 2009-02-25 11:43:09.000-0600

Status changed to feedback while waiting on response from reporter regarding issue being resolved in latest 1.6.0 release.

By: Naren Jayabalu (jnaren) 2009-02-25 11:44:52.000-0600

I daniel i rebuilt my box with asterisk and still when a h323 call is sent i get the same problem. Can you please confirm your test enviornment. Can you please make a call without registering. It must be h323.

on extensions.conf i have

exten => _8.,1,AGI(meta.agi,${EXTEN},${CALLERID(num)})

when a H323 call comes in

*CLI> core show version
Asterisk built by root @ box on a i686 running Linux on 2009-02-25 17:16:23 UTC

*CLI>     -- Executing [888114@default:1] AGI("H323/ip$", "meta.agi,888114,") in new stack

please see the second parameter for meta.agi is blank




By: Jeff Peeler (jpeeler) 2009-02-25 12:24:48.000-0600

I can confirm here that some of the caller id information is missing, which is why I set the issue to acknowledged. I highly doubt the problem has been fixed since nobody else is looking at h323 issues. I'm still looking at it, but for my specific test case I have all the caller id information reported now. A patch will be coming soon.

By: Daniel C (dalbaech) 2009-02-25 12:47:14.000-0600


I am accepting the call via H323 from CCM. The version is using the default H323 included in menuselect with Asterisk.

Sorry I can't help any more, but I can't reproduce the issue using version


By: Daniel C (dalbaech) 2009-02-25 15:39:51.000-0600


I did notice on my AGI that the arguments may be parsed incorrectly if they contain a space or comma.

I changed my AGI to be:
$AGI->exec('AGI',"swift.agi,Your caller ID is: $ARGV[0]");
$AGI->exec('AGI',"swift.agi,'Your name field is: $ARGV[1] $ARGV[2]");

By: Jeff Peeler (jpeeler) 2009-02-25 16:36:23.000-0600

I'd like to see if this patch solves your problem. I have a feeling that storing the data in the source_e164 field is not a good idea, but this can easily be changed once I know that this provides the missing info.

By: Naren Jayabalu (jnaren) 2009-02-26 05:06:17.000-0600

Sorry Jeff. After adding your patch callerid is still missing. I think the variable token is null.

*CLI> [Feb 26 10:54:00] WARNING[15076]: ast_h323.cxx:848 void MyH323Connection::SetCallDetails(void*, const H323SignalPDU&, in: jpeeler: token = (null)|end|
   -- Executing [888114@default:1] AGI("H323/ip$", "meta.agi,888114,") in new stack
   -- Launched AGI Script /var/lib/asterisk/agi-bin/meta.agi

By: Jeff Peeler (jpeeler) 2009-02-26 10:38:52.000-0600

Yep, it is definitely null there. Which means that either the incoming call has missing information or I am looking in the wrong area for it. It did fix the problem locally for me. Can you obtain a wireshark trace of the incoming h323 call? Also include what the caller id should be.

By: Naren Jayabalu (jnaren) 2009-02-26 12:02:01.000-0600

Hi Jeff. I have added the h323 trace to this thread. The caller id is 2073081111. Thanks

By: Jeff Peeler (jpeeler) 2009-02-26 14:02:25.000-0600

jnaren: Can you upload that trace without checking the code submission box?

By: Jeff Peeler (jpeeler) 2009-02-26 14:17:00.000-0600

jnaren: Nevermind, I've unmarked it as code.

By: Jeff Peeler (jpeeler) 2009-02-26 18:33:40.000-0600

jnaren: What other softswitches and gateways are you using that properly recognize the caller ID? The caller ID information appears to be in a nonStandardData section which is defined in the H.225.0 spec as carrying "information not defined in this Recommendation (for example, proprietary data)." I'm looking into finding a way to at least be able return what appears to be a blob of data that also contains the caller ID.

By: Naren Jayabalu (jnaren) 2009-02-27 05:31:34.000-0600

Hi Jeff.

Here are the test results so far. The same results are produced with or without your latest patch.

Working combination for caller id on H323.

call originating from TDM -> Quintum GATEWAY CMS(P106-07-00) -> Quintum softswitch CRSP(P106-12-00) -> asterisk caller id)

Non working combination

call originating from TDM -> Quintum GATEWAY CMS(P106-07-00) -> asterisk caller id)

When comparing the wireshark trace between the two I see a seperate parameter called 'calling party number' under h225 q931 section for the good call.

As you mentioned for the incorrect call the caller id is presented in blob of data which the quintum softswitch somehow reads but the asterisk doesnt.

I will now take this up with quintum support, upgrade the gateway and see if the CMS is to standard.

Thanks for the help so far.



By: Jeff Peeler (jpeeler) 2009-02-27 10:43:01.000-0600

Based on your findings so far it seems that the softswitch is generating the caller id info in a standard compliant way while the gateway is not. Please report back your findings after you hear back from Quintum.

By: Leif Madsen (lmadsen) 2009-03-04 13:08:53.000-0600

Pinging original reporter?

By: Jeff Peeler (jpeeler) 2009-03-11 11:52:51

If I don't hear anything back soon, I'll probably go ahead and merge code that solves the problem for clients I've tested here and close this issue.

By: Naren Jayabalu (jnaren) 2009-03-11 12:06:02

I am sorry for the late reply Jeff. Please go ahead and merge code. I havent had a chance to chase the gateway suppliers for the latest version or the differences between the softswitch and gateway. And wont have one for the next few days. If i get somewhere i will update you. Thanks for all the help.



By: Jeff Peeler (jpeeler) 2009-03-11 15:22:05

Actually, after testing using Asterisk as an authoritative client I don't think there is any problem here. When testing with Ekiga I thought that perhaps the h323-ID should have been showing up as the caller number, which doesn't really make any sense. If the calling party number is not sent in the Q931 setup message the caller ID number won't show up.