Hi,
I need to configure 603+, so the idea is to send Reason “Network Blocked” with the 603 response code.
I tried testing these two options in the dial plan calling internally from an extension but the Reason message is not showing up.
A)
extensions.conf:
[from-internal]
exten => _.,1,Set(SIP_HEADER(Reason)=“Q.850;cause=21;text=‘Network Blocked’”)
exten => _.,n,Hangup(603)
[Apr 10 17:32:51] VERBOSE[3543817][C-00000021] pbx.c: Executing [1000050@from-internal:1] Set(“SIP/enswitch-local-00000036”, “SIP_HEADER(Reason”) in new stack
[Apr 10 17:32:51] WARNING[3543817][C-00000021] pbx_variables.c: Set requires an ‘=’ to be a valid assignment.
[Apr 10 17:32:51] DEBUG[3543817][C-00000021] pbx.c: Launching ‘Hangup’
[Apr 10 17:32:51] VERBOSE[3543817][C-00000021] pbx.c: Executing [1000050@from-internal:2] Hangup(“SIP/enswitch-local-00000036”, “603”) in new stack
Because of previous message then I also tried with SIPAddHeader:
B)
extensions.conf:
[from-internal]
exten => _.,1,SIPAddHeader(Reason: Q.850;cause=21;text=“Network Blocked”)
exten => _.,n,Hangup(603)
Asterisk full log:
[Apr 10 15:53:12] DEBUG[3512898][C-0000001f] chan_sip.c: SIP Header added “Reason: Q.850” as __SIPADDHEADER01
[Apr 10 15:53:12] DEBUG[3512898][C-0000001f] pbx.c: Launching ‘Hangup’
[Apr 10 15:53:12] VERBOSE[3512898][C-0000001f] pbx.c: Executing [1000050@from-internal:2] Hangup(“SIP/enswitch-local-00000035”, “603”) in new stack
Could it be because Asterisk is using chan_sip and it must be chan_pjsip?
Do you know if there is a way to set this up?
Thank you.