Uploaded image for project: 'FreePBX'
  1. FreePBX
  2. FREEPBX-18336

Failing to add Alert-Info header on inbound calls

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 14
    • Fix Version/s: 13
    • Component/s: Inbound Routes
    • Labels:
      None
    • ToDo:
    • Asterisk Version:
      13.22.0
    • Distro Version:
      14.0.3.20
    • Distro:
      FreePBX Distro

      Description

      Looks like the function func-apply-sipheaders is not adding sip headers.  When I set the Alert-Info field for an inbound route on the FreePBX GUI, the header is not being added when I attempt a call.  I believe that the line below should have a "!=" instead of an "="

      exten => s,n,ExecIf($["${HASH(SIPHEADERS,${sipkey})}" = “”]?Set(Addheader=1))

      [func-apply-sipheaders]
      include => func-apply-sipheaders-custom
      exten => s,1,Noop(Applying SIP Headers to channel)
      exten => s,n,Set(SIPHEADERKEYS=${HASHKEYS(SIPHEADERS)})
      exten => s,n,ExecIf($["${HASH(SIPHEADERS,Alert-Info)}" = “unset”]?Set(Rheader=1))
      exten => s,n,While($["${SET(sipkey=${SHIFT(SIPHEADERKEYS)})}" != “”])
      exten => s,n,Set(sipheader=${HASH(SIPHEADERS,${sipkey})})
      exten => s,n,ExecIf($["${HASH(SIPHEADERS,${sipkey})}" = “”]?Set(Addheader=1))
      exten => s,n,ExecIf($["${Addheader}" = “1”]?SIPAddHeader(${sipkey}:${sipheader}))
      exten => s,n,ExecIf($["${Addheader}" = “1”]?Set(PJSIP_HEADER(add,${sipkey})=${sipheader}))
      exten => s,n,EndWhile
      exten => s,n,ExecIf($["${Rheader}" = “1”]?SIPRemoveHeader(Alert-Info)
      exten => s,n,ExecIf($["${Rheader}" = “1”]?Set(PJSIP_HEADER(remove,Alert-Info)=))
      exten => s,n,Return()

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  jphilip Philip Joseph
                  Reporter:
                  jdriek john riek
                • Votes:
                  1 Vote for this issue
                  Watchers:
                  7 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Feedback Requested:

                    NextupJiraPlusStatus

                    Error rendering 'slack.nextup.jira:nextup-jira-plus-status'. Please contact your Jira administrators.