[Home]

Summary:ASTERISK-27726: chan_mobile: presents incorrect inbound Caller-ID names
Reporter:Brian (bpmartin20)Labels:
Date Opened:2018-03-07 15:51:59.000-0600Date Closed:2018-05-18 16:07:32
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Addons/chan_mobile
Versions:13.19.1 14.7.6 15.2.2 Frequency of
Occurrence
Constant
Related
Issues:
Environment:Attachments:
Description:chan_mobile requires that each cell phone be defined in chan_mobile.conf with unique name (e.g. "iphone").  I observed that when presenting inbound caller ID information, chan_mobile always presents the name of phone that received the call instead of the name of the caller.  So a call from "John Smith" at 505-555-5555 is presented as a call from "iphone" at 505-555-5555.

Looking into the source code, I see that hfp_parse_clip parses out the caller ID number, but does not attempt to parse out the optional caller ID name.  

Later in the code, the ast_channel routine calls ast_channel_alloc to create the channel.  When it does this it provides the cell phone name (e.g. “iphone”) as the fourth parameter, where the caller ID name should really belong (or a null string if caller ID name is not provided, so the dial plan can use alternate databases to retrieve a name).

These portions of the code have not changed in versions 14.x or 15.x, so the problem presumably also appears there, though I don't have an environment to test with.

This is an initial issue report.  I intend to develop a patch that I will submit for review through Gerrit.
Comments:By: Asterisk Team (asteriskteam) 2018-03-07 15:52:00.054-0600

Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution.

A good first step is for you to review the [Asterisk Issue Guidelines|https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines] if you haven't already. The guidelines detail what is expected from an Asterisk issue report.

Then, if you are submitting a patch, please review the [Patch Contribution Process|https://wiki.asterisk.org/wiki/display/AST/Patch+Contribution+Process].

By: Joshua C. Colp (jcolp) 2018-03-12 07:59:19.928-0500

As you stated you expect to provide a patch for this I am assigning it to you. If you have changed your mind please comment and the issue will automatically transition back to triage.

By: Asterisk Team (asteriskteam) 2018-03-26 12:00:01.176-0500

Suspended due to lack of activity. This issue will be automatically re-opened if the reporter posts a comment. If you are not the reporter and would like this re-opened please create a new issue instead. If the new issue is related to this one a link will be created during the triage process. Further information on issue tracker usage can be found in the Asterisk Issue Guidlines [1].

[1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines

By: Brian (bpmartin20) 2018-03-26 13:16:01.630-0500

Initial coding is complete and I expect to test and debug this week and next as time permits.  

If anyone following this issue can direct me to formal syntax specifications for the AT+CLIP message that contains the caller-ID information, that would be helpful.  I've researched ITU-T specifications, but they don't seem to drill down to specific fields and syntax.  CNAM is typically found in field 5, but one document out of Australia seemed to indicate that fields 2 and 3 are sometimes not present (including the field separator), which would move CNAM back to field 3.  I'm coding based on what specifications and samples I can find, but a source of formal documentation might prevent future bugs.

By: Asterisk Team (asteriskteam) 2018-03-26 13:16:01.920-0500

This issue has been reopened as a result of your commenting on it as the reporter. It will be triaged once again as applicable.

By: Joshua C. Colp (jcolp) 2018-03-26 13:27:01.385-0500

Since you are actively working on this I have assigned it to you and put it into progress.

By: Brian (bpmartin20) 2018-04-26 14:41:22.087-0500

I uploaded patches via gerrit on Apr. 17.  I don't believe it's waiting for peer review, but please let me know if there is something else I need to do.

By: Friendly Automation (friendly-automation) 2018-05-18 16:07:33.805-0500

Change 8801 merged by Jenkins2:
chan_mobile: support handling of caller-id names ("cnam").

[https://gerrit.asterisk.org/8801|https://gerrit.asterisk.org/8801]

By: Friendly Automation (friendly-automation) 2018-05-18 16:14:02.747-0500

Change 8804 merged by Jenkins2:
chan_mobile: support handling of caller-id names ("cnam").

[https://gerrit.asterisk.org/8804|https://gerrit.asterisk.org/8804]

By: Friendly Automation (friendly-automation) 2018-05-18 17:45:21.674-0500

Change 8803 merged by Kevin Harwell:
chan_mobile: support handling of caller-id names ("cnam").

[https://gerrit.asterisk.org/8803|https://gerrit.asterisk.org/8803]