Sip sms between extensions using extensions_custom.conf doesn’t work anymore

Hi, I have the same problem as user has descripted in the following topic:

Any suggestions? It worked for me in the last two years and suddenly I can’t send any messages anymore.
Thanks
Norbert

Do you see anything in the logs?

No, I don’t see anything in the log - or I am to stupid to look into the correct one. Which one should I look? My clients (Digium phones, Zoiper app or other SIP phone) are giving out the message; 404 not fount.
My server is on the newest Asterisk ( 15.7.2) and Freepbx 14 is up-to-date, too.

Thanks for your help
Norbert

Run

tail -f /var/log/asterisk/full

Try reproducing the issue, post the logs here.

Hi, there is nothing in the full log file related to the issue.

Thanks
Norbert

Then that means it was never executed. Show your actual dialplan you are using for this.

Here are my chan_sip settings:
Sip settings
accept_outofcall_message=yes
outofcall_message_context=astsms

/etc/asterisk/extensions_custom.conf:
[astsms]
exten => _.,1,NoOp(SMS receiving dialplan invoked)
exten => _.,n,NoOp(To ${MESSAGE(to)})
exten => _.,n,NoOp(From ${MESSAGE(from)})
exten => _.,n,NoOp(Body ${MESSAGE(body)})
exten => _.,n,Set(ACTUALTO=${CUT(MESSAGE(to),@,1)})
exten => _.,n,MessageSend(${ACTUALTO},${MESSAGE(from)})
exten => _.,n,NoOp(Send status is ${MESSAGE_SEND_STATUS})
exten => _.,n,GotoIf($["${MESSAGE_SEND_STATUS}" != “SUCCESS”]?sendfailedmsg)
exten => _.,n,Hangup()
;
; Handle failed messaging
exten => _.,n(sendfailedmsg),Set(MESSAGE(body)="[${STRFTIME(${EPOCH},%d%m%Y-%H:%M:%S)}] Your message to ${EXTEN} has failed. Retry later.")
exten => _.,n,Set(ME_1=${CUT(MESSAGE(from),<,2)})
exten => _.,n,Set(ACTUALFROM=${CUT(ME_1,@,1)})
exten => _.,n,MessageSend(${ACTUALFROM},ServiceCenter)
exten => _.,n,Hangup()
exten => _.,n,Hangup()

As I mentioned I used it for almost two years and suddenly in February it stopped working.

So these are in your [general] settings in the sip_additional.conf file?

How is the SMS being sent? From a device, softphone, over a PSTN peer? The devices that are sending/receiving are all chan_sip?

Those setting are in the sip_general_additional.conf file (freepbx saved them in this location). All my peers are on chan_sip and I tried Softphones (Zoiper, Bria, MizoPhone) and serveral SIP phones (Digium A25 and UniData phones).

Then you need to do a deeper debug. Go into the Asterisk cli and do sip set debug on then send a message from one of those devices. If it doesn’t come in as a MESSAGE then Asterisk won’t process it. We need to verify that is what is happening.

Post the results here or pastebin them and link it.

Thanks for your great help. Here is the debug log when sending a test message from 1903 to 1915:
<— SIP read from TLS:172.23.69.61:38992 —>
MESSAGE sip:[email protected]:5061;transport=TLS SIP/2.0
Via: SIP/2.0/TLS 172.23.69.61:49632;branch=z9hG4bK-524287-1—8de0236c127c1c9b;rport
Max-Forwards: 70
To: sip:[email protected]:5061;transport=TLS
From: sip:[email protected]:5061;transport=TLS;tag=55a7f06b
Call-ID: Fy6Xh9bBQNt9xcFOG9YBdg…
CSeq: 2 MESSAGE
Allow: INVITE, ACK, CANCEL, BYE, NOTIFY, REFER, MESSAGE, OPTIONS, INFO, SUBSCRIBE
Content-Type: text/plain
User-Agent: Zoiper rv2.9.2
Allow-Events: presence, kpml, talk
Content-Length: 4

Test message
<------------->
— (12 headers 1 lines) —
Sending to 172.23.69.61:38992 (NAT)
Receiving message!
Looking for 1915 in dpma_message_context (domain pbx.ntmpng.org)

<— Transmitting (NAT) to 172.23.69.61:38992 —>
SIP/2.0 404 Not Found
Via: SIP/2.0/TLS 172.23.69.61:49632;branch=z9hG4bK-524287-1—8de0236c127c1c9b;received=172.23.69.61;rport=38992
From: sip:[email protected]:5061;transport=TLS;tag=55a7f06b
To: sip:[email protected]:5061;transport=TLS;tag=as2a316075
Call-ID: Fy6Xh9bBQNt9xcFOG9YBdg…
CSeq: 2 MESSAGE
Server: FPBX-14.0.11(15.7.2)
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Length: 0

Could it the problem that Asterisk looks in the dpma_message_context? I installed once the Digium DPMA and later I found out that it will not work with my Digium A25 Series phones. I removed the DPMA, but could it this still causing the issue?

Thanks
Norbert

I found the problem. For some unknown reason FreePBX adds the entry: outofcall_message_context=dpma_message_context
into the sip_general_additional.conf.

However, in the GUI I have the following entry:


FreePBX seems to override my astsms setting with dpma_message_context.
What can I do to get the issue fixed?
Thanks
Norbert

Submit a ticket. It sounds like the DPMA module uninstall was incomplete, and there’s nothing (I’m aware of) that we can do to help you.

Hello to all,
Mr. Norber Huebner, please rename the astsms to dpma_message_context at the extensions_custom.conf file and you will propably be fine!
It worked for me,
Thanks all for the support!

Yes, I did this and it is working.
Thank you so much for all your help! I really appreciate it!

I still think you need to write up a bug report and submit it. I still think that the DPMA uninstall is not working correctly, since the DPMA SMS artifact remains in the config file. Having a non-obvious solution to a problem like this isn’t a solution.

Hello to all,
This is not a solution, it’s a workaround!
But please keep in mind that I never installed or unistalled Digium dpma but I have the same entry at my sip_general_additional.conf file!
I searched all conf files that I believed it could contain the context code of the dpma_message_context entry but I couldn’t found anything, that’s why I tried to change the name.
I don’t know why I have this entry.
The only thing that I can think of is that I had to uninstall Digium Phones module because of a conflict with a newer Sangoma one, I don’t know if this is relevant or not but this happened about February. Before February sms service worked correctly.
Kind regards.

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