PJSIP extensions try to call not existing SIP extension instead PJSIP extensions (snom)

I had a strange issue on my freepbx 16 with asterisk 16.

Their are currently only PJSIP extensions but when i try to call from a snom with an fkey

<fkey idx="0" context="1" label="Person A" perm="R">speed [email protected]</fkey>

(i tried different approeaches also with blf and asterisk xml definition for snom)

The phone receive the message that their is no one available. On the freepbx i see in the log the following:

== Using SIP RTP Audio TOS bits 184
  == Using SIP RTP Audio TOS bits 184 in TCLASS field.
  == Using SIP RTP Audio CoS mark 5
    -- Executing [5002771@from-internal:1] GotoIf("PJSIP/5002770-00004bd2", "0?notfromlocal") in new stack
    -- Executing [5002771@from-internal:2] GotoIf("PJSIP/5002770-00004bd2", "0?notfromlocal") in new stack
    -- Executing [5002771@from-internal:3] GotoIf("PJSIP/5002770-00004bd2", "0?notfromlocal") in new stack
    -- Executing [5002771@from-internal:4] GotoIf("PJSIP/5002770-00004bd2", "0?notfromlocal") in new stack
    -- Executing [5002771@from-internal:5] NoOp("PJSIP/5002770-00004bd2", ""add custom ringtone for internal call"") in new stack
    -- Executing [5002771@from-internal:6] SIPAddHeader("PJSIP/5002770-00004bd2", ""Alert-Info:<http://www.notused.com>;info=friends;x-line-id=0"") in new stack
    -- Executing [5002771@from-internal:7] NoOp("PJSIP/5002770-00004bd2", "") in new stack
    -- Executing [5002771@from-internal:8] Dial("PJSIP/5002770-00004bd2", "SIP/5002771") in new stack
[2023-03-07 11:46:16] WARNING[72909][C-00011510]: chan_sip.c:6366 create_addr: Purely numeric hostname (5002771), and not a peer--rejecting!
[2023-03-07 11:46:16] NOTICE[72909][C-00011510]: app_dial.c:2687 dial_exec_full: Unable to create channel of type 'SIP' (cause 20 - Subscriber absent)
  == Everyone is busy/congested at this time (1:0/0/1)
    -- Auto fallthrough, channel 'PJSIP/5002770-00004bd2' status is 'CHANUNAVAIL'
    -- Executing [h@from-internal:1] Macro("PJSIP/5002770-00004bd2", "hangupcall") in new stack
    -- Executing [s@macro-hangupcall:1] GotoIf("PJSIP/5002770-00004bd2", "1?theend") in new stack
    -- Goto (macro-hangupcall,s,3)
    -- Executing [s@macro-hangupcall:3] ExecIf("PJSIP/5002770-00004bd2", "0?Set(CDR(recordingfile)=)") in new stack
    -- Executing [s@macro-hangupcall:4] Hangup("PJSIP/5002770-00004bd2", "") in new stack
  == Spawn extension (macro-hangupcall, s, 4) exited non-zero on 'PJSIP/5002770-00004bd2' in macro 'hangupcall'
  == Spawn extension (from-internal, h, 1) exited non-zero on 'PJSIP/5002770-00004bd2'
  == Using SIP RTP Audio TOS bits 184
  == Using SIP RTP Audio TOS bits 184 in TCLASS field.
  == Using SIP RTP Audio CoS mark 5
    -- Executing [5002772@from-internal:1] GotoIf("PJSIP/5002770-00004bd3", "0?notfromlocal") in new stack
    -- Executing [5002772@from-internal:2] GotoIf("PJSIP/5002770-00004bd3", "0?notfromlocal") in new stack
    -- Executing [5002772@from-internal:3] GotoIf("PJSIP/5002770-00004bd3", "0?notfromlocal") in new stack
    -- Executing [5002772@from-internal:4] GotoIf("PJSIP/5002770-00004bd3", "0?notfromlocal") in new stack
    -- Executing [5002772@from-internal:5] NoOp("PJSIP/5002770-00004bd3", ""add custom ringtone for internal call"") in new stack
    -- Executing [5002772@from-internal:6] SIPAddHeader("PJSIP/5002770-00004bd3", ""Alert-Info:<http://www.notused.com>;info=friends;x-line-id=0"") in new stack
    -- Executing [5002772@from-internal:7] NoOp("PJSIP/5002770-00004bd3", "") in new stack
    -- Executing [5002772@from-internal:8] Dial("PJSIP/5002770-00004bd3", "SIP/5002772") in new stack
[2023-03-07 11:46:22] WARNING[72992][C-00011511]: chan_sip.c:6366 create_addr: Purely numeric hostname (5002772), and not a peer--rejecting!

Why the hell is the asterisk try to reach a SIP/5002711 extension which don’t exist and not PJSIP/5002711 ?

That appears to be custom dialplan code. The FreePBX code for this goes through many macros, and is much longer. Also the FreePBX code would try both chan_pjsip and chan_sip ways of doing headers and would do so in a pre-dial hook, called from Dial.

I presume the customisation was done to add the Alert-Info header. It appears to be misusing a valid but unsold domain name, although possibly only as a placeholder.

thanks for your answer. the domain above is only a placeholder domain, because the pbx is available public and so i don’t like posting all infos in the internet :wink:

As i know i don’t setup a custom dialplan but i look into it if a colleague setup something in the custom config files, and do some copy&paste stuff from an old config or something.

RFC 2606: Reserved Top Level DNS Names exists to cover such usage.

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.