[Home]

Summary:ASTERISK-07693: called number presentation has changed to 4 digits since 1.2.11
Reporter:Steve Hanselman (shanselman)Labels:
Date Opened:2006-09-08 03:35:45Date Closed:2011-06-07 14:08:25
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:We have a PRI with 3 digit presentation, this was fine on 1.2.10, have now upgraded to 1.2.11 and Asterisk is now changing this to be 4 digit presentation (leading 0 on our 3 digits).


****** STEPS TO REPRODUCE ******

Place an inbound call to the system

****** ADDITIONAL INFORMATION ******

Here's the relevant debug that highlights the issue:-

Called number is 111, in the call later we see it as 0111

dell*CLI> pri debug span 1
Enabled debugging on span 1
1 < Protocol Discriminator: Q.931 (8)  len=37
1 < Call Ref: len= 2 (reference 4557/0x11CD) (Originator)
1 < Message type: SETUP (5)
1 < [1 041  031  801  901  a31 ]
1 < Bearer Capability (len= 5) [ Ext: 1  Q.931 Std: 0  Info transfer capability: Speech (0)
1 <                              Ext: 1  Trans mode/rate: 64kbps, circuit-mode (16)
1 <                              Ext: 1  User information layer 1: A-Law (35)
1 < [1 181  031  a11  831  831 ]
1 < Channel ID (len= 5) [ Ext: 1  IntID: Implicit, PRI Spare: 0, Preferred Dchan: 0
1 <                        ChanSel: Reserved
1 <                       Ext: 1  Coding: 0   Number Specified   Channel Type: 3
1 <                       Ext: 1  Channel: 3 ]
1 < [1 6c1  0d1  011  831  301  371  391  371  331  371  351  301  391  391  331 ]
1 < Calling Number (len=15) [ Ext: 0  TON: Unknown Number Type (0)  NPI: ISDN/Telephony Numbering Plan (E.164/E.163) (1)
1 <                           Presentation: Presentation allowed of network provided number (3) '07973750993' ]
1 < [1 701  041  a11  311  311  311 ]
1 < Called Number (len= 6) [ Ext: 1  TON: National Number (2)  NPI: ISDN/Telephony Numbering Plan (E.164/E.163) (1) '111' ]
1 < [1 a11 ]
1 < Sending Complete (len= 1)
1 -- Making new call for cr 4557
1 -- Processing Q.931 Call Setup
1 -- Processing IE 4 (cs0, Bearer Capability)
1 -- Processing IE 24 (cs0, Channel Identification)
1 -- Processing IE 108 (cs0, Calling Party Number)
1 -- Processing IE 112 (cs0, Called Party Number)
1 -- Processing IE 161 (cs0, Sending Complete)
1 > Protocol Discriminator: Q.931 (8)  len=10
1 > Call Ref: len= 2 (reference 4557/0x11CD) (Terminator)
1 > Message type: CALL PROCEEDING (2)
1 > [1 181  031  a91  831  831 ]
1 > Channel ID (len= 5) [ Ext: 1  IntID: Implicit, PRI Spare: 0, Exclusive Dchan: 0
1 >                        ChanSel: Reserved
1 >                       Ext: 1  Coding: 0   Number Specified   Channel Type: 3
1 >                       Ext: 1  Channel: 3 ]
   -- Accepting voice call from '07973750993' to '0111' on channel 0/3, span 1
   -- Executing SetCallerPres("Zap/3-1", "allowed") in new stack
   -- Executing Set("Zap/3-1", "CALLFILENAME=20060907-083615-Inbound-07973750993-0111") in new stack
   -- Executing Monitor("Zap/3-1", "wav|20060907-083615-Inbound-07973750993-0111|m") in new stack
   -- Executing Dial("Zap/3-1", "Zap/g2/0111w") in new stack
   -- Requested transfer capability: 0x00 - SPEECH
   -- Called g2/0111w
   -- Zap/32-1 is proceeding passing it to Zap/3-1
   -- Zap/32-1 is ringing

Comments:By: Stefano Brandimarte (stevens) 2006-09-08 04:36:43

hello. Do You have a similar output generated by * 1.2.10? In zapata.conf the
pridialplan and nationalprefix settings are used in these cases. How did You set
those parameters?

By: Steve Hanselman (shanselman) 2006-09-08 04:56:51

I've just found some 1.2.10 output, none of the config files have changed so either a default has been changed, or a new option has been added.

Sep  6 12:16:40 VERBOSE[2766] logger.c: < Protocol Discriminator: Q.931 (8)  len=37
Sep  6 12:16:40 VERBOSE[2766] logger.c: < Call Ref: len= 2 (reference 2488/0x9B8) (Originator)
Sep  6 12:16:40 VERBOSE[2766] logger.c: < Message type: SETUP (5)
Sep  6 12:16:40 VERBOSE[2766] logger.c: < [Sep  6 12:16:40 VERBOSE[2766] logger.c: < [04Sep  6 12:16:40 VERBOSE[2766] logger.c: < [0
4 03Sep  6 12:16:40 VERBOSE[2766] logger.c: < [04 03 80Sep  6 12:16:40 VERBOSE[2766] logger.c: < [04 03 80 90Sep  6 12:16:40 VERBOSE
[2766] logger.c: < [04 03 80 90 a3Sep  6 12:16:40 VERBOSE[2766] logger.c: < [04 03 80 90 a3]
Sep  6 12:16:40 VERBOSE[2766] logger.c: < Bearer Capability (len= 5) [ Ext: 1  Q.931 Std: 0  Info transfer capability: Speech (0)
Sep  6 12:16:40 VERBOSE[2766] logger.c: <                              Ext: 1  Trans mode/rate: 64kbps, circuit-mode (16)
Sep  6 12:16:40 VERBOSE[2766] logger.c: <                              Ext: 1  User information layer 1: A-Law (35)
Sep  6 12:16:40 VERBOSE[2766] logger.c: < [Sep  6 12:16:40 VERBOSE[2766] logger.c: < [18Sep  6 12:16:40 VERBOSE[2766] logger.c: < [1
8 03Sep  6 12:16:40 VERBOSE[2766] logger.c: < [18 03 a1Sep  6 12:16:40 VERBOSE[2766] logger.c: < [18 03 a1 83Sep  6 12:16:40 VERBOSE
[2766] logger.c: < [18 03 a1 83 87Sep  6 12:16:40 VERBOSE[2766] logger.c: < [18 03 a1 83 87]
Sep  6 12:16:40 VERBOSE[2766] logger.c: < Channel ID (len= 5) [ Ext: 1  IntID: Implicit, PRI Spare: 0, Preferred Dchan: 0
Sep  6 12:16:40 VERBOSE[2766] logger.c: <                        ChanSel: Reserved
Sep  6 12:16:40 VERBOSE[2766] logger.c: <                       Ext: 1  Coding: 0   Number Specified   Channel Type: 3
Sep  6 12:16:40 VERBOSE[2766] logger.c: <                       Ext: 1  Channel: 7 ]
Sep  6 12:16:40 VERBOSE[2766] logger.c: < [Sep  6 12:16:40 VERBOSE[2766] logger.c: < [6cSep  6 12:16:40 VERBOSE[2766] logger.c: < [6
c 0dSep  6 12:16:40 VERBOSE[2766] logger.c: < [6c 0d 01Sep  6 12:16:40 VERBOSE[2766] logger.c: < [6c 0d 01 83Sep  6 12:16:40 VERBOSE
[2766] logger.c: < [6c 0d 01 83 30Sep  6 12:16:40 VERBOSE[2766] logger.c: < [6c 0d 01 83 30 31Sep  6 12:16:40 VERBOSE[2766] logger.c
: < [6c 0d 01 83 30 31 32Sep  6 12:16:40 VERBOSE[2766] logger.c: < [6c 0d 01 83 30 31 32 30Sep  6 12:16:40 VERBOSE[2766] logger.c: <
[6c 0d 01 83 30 31 32 30 36Sep  6 12:16:40 VERBOSE[2766] logger.c: < [6c 0d 01 83 30 31 32 30 36 32Sep  6 12:16:40 VERBOSE[2766] lo
gger.c: < [6c 0d 01 83 30 31 32 30 36 32 32Sep  6 12:16:40 VERBOSE[2766] logger.c: < [6c 0d 01 83 30 31 32 30 36 32 32 34Sep  6 12:1
6:40 VERBOSE[2766] logger.c: < [6c 0d 01 83 30 31 32 30 36 32 32 34 32Sep  6 12:16:40 VERBOSE[2766] logger.c: < [6c 0d 01 83 30 31 3
2 30 36 32 32 34 32 37Sep  6 12:16:40 VERBOSE[2766] logger.c: < [6c 0d 01 83 30 31 32 30 36 32 32 34 32 37 30Sep  6 12:16:40 VERBOSE
[2766] logger.c: < [6c 0d 01 83 30 31 32 30 36 32 32 34 32 37 30]
Sep  6 12:16:40 VERBOSE[2766] logger.c: < Calling Number (len=15) [ Ext: 0  TON: Unknown Number Type (0)  NPI: ISDN/Telephony Number
ing Plan (E.164/E.163) (1)
Sep  6 12:16:40 VERBOSE[2766] logger.c: <                           Presentation: Presentation allowed of network provided number (3
) '01206224270' ]
Sep  6 12:16:40 VERBOSE[2766] logger.c: < [Sep  6 12:16:40 VERBOSE[2766] logger.c: < [70Sep  6 12:16:40 VERBOSE[2766] logger.c: < [7
0 04Sep  6 12:16:40 VERBOSE[2766] logger.c: < [70 04 a1Sep  6 12:16:40 VERBOSE[2766] logger.c: < [70 04 a1 31Sep  6 12:16:40 VERBOSE
[2766] logger.c: < [70 04 a1 31 30Sep  6 12:16:40 VERBOSE[2766] logger.c: < [70 04 a1 31 30 30Sep  6 12:16:40 VERBOSE[2766] logger.c
: < [70 04 a1 31 30 30]
Sep  6 12:16:40 VERBOSE[2766] logger.c: < Called Number (len= 6) [ Ext: 1  TON: National Number (2)  NPI: ISDN/Telephony Numbering P
lan (E.164/E.163) (1) '100' ]
Sep  6 12:16:40 VERBOSE[2766] logger.c: < [Sep  6 12:16:40 VERBOSE[2766] logger.c: < [a1Sep  6 12:16:40 VERBOSE[2766] logger.c: < [a
1]
Sep  6 12:16:40 VERBOSE[2766] logger.c: < Sending Complete (len= 1)
Sep  6 12:16:40 VERBOSE[2766] logger.c: -- Making new call for cr 2488
Sep  6 12:16:40 VERBOSE[2766] logger.c: -- Processing Q.931 Call Setup
Sep  6 12:16:40 VERBOSE[2766] logger.c: -- Processing IE 4 (cs0, Bearer Capability)
Sep  6 12:16:40 VERBOSE[2766] logger.c: -- Processing IE 24 (cs0, Channel Identification)
Sep  6 12:16:40 VERBOSE[2766] logger.c: -- Processing IE 108 (cs0, Calling Party Number)
Sep  6 12:16:40 VERBOSE[2766] logger.c: -- Processing IE 112 (cs0, Called Party Number)
Sep  6 12:16:40 VERBOSE[2766] logger.c: -- Processing IE 161 (cs0, Sending Complete)
Sep  6 12:16:40 VERBOSE[2766] logger.c: > Protocol Discriminator: Q.931 (8)  len=10
Sep  6 12:16:40 VERBOSE[2766] logger.c: > Call Ref: len= 2 (reference 2488/0x9B8) (Terminator)
Sep  6 12:16:40 VERBOSE[2766] logger.c: > Message type: CALL PROCEEDING (2)
Sep  6 12:16:40 VERBOSE[2766] logger.c: > [Sep  6 12:16:40 VERBOSE[2766] logger.c: > [18Sep  6 12:16:40 VERBOSE[2766] logger.c: > [1
8 03Sep  6 12:16:40 VERBOSE[2766] logger.c: > [18 03 a9Sep  6 12:16:40 VERBOSE[2766] logger.c: > [18 03 a9 83Sep  6 12:16:40 VERBOSE
[2766] logger.c: > [18 03 a9 83 87Sep  6 12:16:40 VERBOSE[2766] logger.c: > [18 03 a9 83 87]
Sep  6 12:16:40 VERBOSE[2766] logger.c: > Channel ID (len= 5) [ Ext: 1  IntID: Implicit, PRI Spare: 0, Exclusive Dchan: 0
Sep  6 12:16:40 VERBOSE[2766] logger.c: >                        ChanSel: Reserved
Sep  6 12:16:40 VERBOSE[2766] logger.c: >                       Ext: 1  Coding: 0   Number Specified   Channel Type: 3
Sep  6 12:16:40 VERBOSE[2766] logger.c: >                       Ext: 1  Channel: 7 ]
Sep  6 12:16:40 DEBUG[2757] devicestate.c: Changing state for Zap/7 - state 2 (In use)
Sep  6 12:16:40 VERBOSE[2766] logger.c:     -- Accepting call from '01206224270' to '100' on channel 0/7, span 1

By: Stefano Brandimarte (stevens) 2006-09-08 07:46:05

shanselman: at first sight i cannot find a code change between the two releases
in the callerid assignment behaviour. The rule are:

- if a number is NATIONAL (TON: National Number (2)) the "nationalprefix" will
 be added in front of it (the function in chan_zap.c is apply_plan_to_number())

Your logs show this behaviour. What are the settings of "prilocaldialplan" and
"nationalprefix" into Your zapata.conf file? They, as far as i can see, should
be set to "national" and "0" respectively to produce the results as shown.

By: Steve Hanselman (shanselman) 2006-09-08 08:07:38

Those are indeed the settings, but it wasn't doing that before and if you look at the 1.2.10 TON is national there too as well.

ls -l /etc/asterisk/zapata.conf
-rwxr--r-- 1 asterisk asterisk 18159 Jul 12 13:41 /etc/asterisk/zapata.conf

As you can see, that file hasn't changed for a while, so presumably somebody has fixed a bug with failing to honour the settings, are these documented somewhere as I'd like to check the whole file against the documentation to ensure that it's all set as it should be?

By: Stefano Brandimarte (stevens) 2006-09-08 09:06:06

shanselman: i made a diff between the two chan_zap.c (1.2.10 vs 1.2.11) and the
results show no substantial changes. I'm still looking for a reason for Your
different behaviour, but in the meantime could You please check if the asterisk
1.2.10 was a patched version or not? Could be reasonable for You to switch back
to 1.2.10 to conduct some more tests? And, if possible, could You please post
Your whole zapata.conf? Via email, if You prefer, stevens at stevens dot it.

By: Steve Hanselman (shanselman) 2006-09-12 04:35:33

Whatever was changed has now been changed back as of this mornings upgrade to 1.2.12 and the relevant zaptel/libpri!

We now have three digit presentation properly handled.

By: Stefano Brandimarte (stevens) 2006-09-12 04:48:30

shanselman: a diff between chan_zap.c from both version (1.2.11 and 1.2.12)
shows only the line changes reported below; imho nothing has changed in the
field of called/calling number handling.

@@ -68,7 +68,7 @@

#include "asterisk.h"

-ASTERISK_FILE_VERSION(__FILE__, "$Revision: 39081 $")
+ASTERISK_FILE_VERSION(__FILE__, "$Revision: 41069 $")

#include "asterisk/lock.h"
#include "asterisk/channel.h"
@@ -8485,10 +8485,11 @@
                                               res = set_actual_gain(pri->pvts[chanpos]->subs[SUB_REAL].zfd, 0, pri->pvts[chanpos]->rxgain, pri->pvts[chanpos]->txgain, law);
                                               if (res < 0)
                                                       ast_log(LOG_WARNING, "Unable to set gains on channel %d\n", pri->pvts[chanpos]->channel);
-                                               if (e->ring.complete || !pri->overlapdial)
+                                               if (e->ring.complete || !pri->overlapdial) {
                                                       /* Just announce proceeding */
+                                                       pri->pvts[chanpos]->proceeding = 1;
                                                       pri_proceeding(pri->pri, e->ring.call, PVT_TO_CHANNEL(pri->pvts[chanpos]), 0);
-                                               else  {
+                                               } else  {

By: jmls (jmls) 2006-11-01 12:32:15.000-0600

can this be closed then ?

By: Serge Vecher (serge-v) 2006-11-07 12:19:35.000-0600

well, since this has been fixed, I'll close the issue then. If anybody determines a specific revision of libpri or asterisk that has fixed this, please find a bug marshall on #asterisk-bugs IRC channel so they can add this information to the bug  "for the record". Thanks.

By: pj (pj) 2006-11-09 12:38:27.000-0600

I don't know, if my issue can relate with this, but after update from 1.2.9.1 to 1.2.13, I don't see "caller id name", when calling from callmanager to ip phone connected to asterisk using asterisks original chan_h323.
With 1.2.13 and chan_ooh323 it's working, but chan_ooh323 have other issue (I reported to ooh323 devel), so I must stay on 1.2.9.1 :-(

By: Matthew Fredrickson (mattf) 2006-11-10 15:32:33.000-0600

No, that sounds like a separate issue.  Please open a new bug if you are having CID name problems.