ESME_RSUBMITFAIL when trying to send SMS

Post Reply
a.thomas94
Posts: 4
Joined: Fri Jul 09, 2021 8:06 am

ESME_RSUBMITFAIL when trying to send SMS

Post by a.thomas94 » Fri Jul 09, 2021 8:09 am

Would you please help me out? I am trying to send sms but it always fails.

Configuration Settings:
<add key="SMPP_CONNECTION_RETRY_DELAY_IN_SECONDS" value="5"/>
<add key="SMPP_DATA_CODING" value="0"/>
<add key="SMPP_WORKING_THREADS" value="8"/>
<add key="SMPP_RECOVERY_DELAY_IN_MINUTES" value="1"/>
<add key="SMPP_ENABLE_THROTTLING" value="YES"/>
<add key="SMPP_THROTTLING_OCCURRENCES" value="2"/>
<add key="SMPP_THROTTLING_INTERVAL_IN_SECONDS" value="1"/>
<add key="SMPP_ENQUIRE_LINK_INTERVAL_IN_SECONDS" value="120"/>
<add key="SMPP_SENDER_NPI" value="0"/>
<add key="SMPP_SENDER_TON" value="5"/>

Logs:
2021-07-08 13:59:37.6622 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 388, MessageId:
2021-07-08 13:59:37.6622 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 389, SourceAddr: ONE AL, DestAddr: 355693422615
2021-07-08 13:59:38.1935 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 390, SourceAddr: ONE AL, DestAddr: 355682990663
2021-07-08 13:59:38.1935 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 389, MessageId:
2021-07-08 13:59:38.7248 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 391, SourceAddr: ONE AL, DestAddr: 355688526671
2021-07-08 13:59:38.7248 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 390, MessageId:
2021-07-08 13:59:39.2559 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 392, SourceAddr: ONE AL, DestAddr: 355682602290
2021-07-08 13:59:39.2559 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 391, MessageId:
2021-07-08 13:59:39.7873 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 393, SourceAddr: ONE AL, DestAddr: 355682474651
2021-07-08 13:59:39.7873 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 392, MessageId:
2021-07-08 13:59:40.3185 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 394, SourceAddr: ONE AL, DestAddr: 355682393638
2021-07-08 13:59:40.3185 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 393, MessageId:
2021-07-08 13:59:40.8498 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 395, SourceAddr: ONE AL, DestAddr: 355682650930
2021-07-08 13:59:40.8498 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 394, MessageId:
2021-07-08 13:59:41.3810 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 396, SourceAddr: ONE AL, DestAddr: 355695835922
2021-07-08 13:59:41.3810 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 395, MessageId:
2021-07-08 13:59:41.9122 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 397, SourceAddr: ONE AL, DestAddr: 355688352444
2021-07-08 13:59:41.9122 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 396, MessageId:
2021-07-08 13:59:42.4435 Debug Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 398, SourceAddr: ONE AL, DestAddr: 355685574317
2021-07-08 13:59:42.4435 Debug PDU Received: SubmitSmResp, Status: ESME_RSUBMITFAIL, Sequence: 397, MessageId:
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by alt » Mon Jul 12, 2021 10:25 am

Hi

If you send test SMS to the server created with SmppServer class, you should subscribe on evClientSubmitSm event. The ESME_RSUBMITFAIL status is returned when the SmppServer instance is not subscribed on this event.

If you send to the third-party SMPP server, you have to ask your provider for the reason of the response status.
a.thomas94
Posts: 4
Joined: Fri Jul 09, 2021 8:06 am

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by a.thomas94 » Mon Jul 12, 2021 1:07 pm

Thank you for replying.

I've done what you're suggesting.

The application has been working for a few months and when they used a new SMSC it stopped working.

Through debugging and experimentation I found out that there's something going on with TLV optional Tags.
PLsfix.PNG
PLsfix.PNG (49.51 KiB) Viewed 45030 times
In the image above if I comment the code where I've marked it with a red X and use Guid.NewGuid() below, it will send the message successfully and respond with OK, but if I don't do that and I submit the PDUS it will return RSUBMITFAIL.
Untitled.png
Untitled.png (158.74 KiB) Viewed 45030 times
Any ideas?
a.thomas94
Posts: 4
Joined: Fri Jul 09, 2021 8:06 am

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by a.thomas94 » Mon Jul 12, 2021 2:21 pm

I found out that when I attach parameter it returns RSUBMITFAIL, if I don't attach it returns OK.
What should I do? Is it a limitation of the infrastructure of the company? What it might be?
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by alt » Mon Jul 12, 2021 3:02 pm

I think the new SMSC doesn't support user_message_reference TLV parameter. Better to ask the SMSC directly.
a.thomas94
Posts: 4
Joined: Fri Jul 09, 2021 8:06 am

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by a.thomas94 » Wed Jul 14, 2021 6:07 am

alt wrote:
Mon Jul 12, 2021 3:02 pm
I think the new SMSC doesn't support user_message_reference TLV parameter. Better to ask the SMSC directly.
Hi Alt, please continue to support a little bit with answers.

I spoke with the people that maintain the SMSC and they sent me a photo were it shows that the messages I send are malformed and that user_message_reference is enabled.
Corrupted.png
Corrupted.png (185.16 KiB) Viewed 45010 times
Do you have any tips/ ideas on how should I proceed?
They also say that it malformed by the second optional parameter attached, but I don't do that in code, there is only one optional parameter I use.
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by alt » Thu Jul 15, 2021 8:22 am

The smpp stream looks correct. I will try to examine this case today and understand why wireshark considers it as malformed packet.
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by alt » Thu Jul 15, 2021 1:39 pm

The value of the user_message_reference parameter can take only 2 bytes. Please use ushort type:

Code: Select all

ushort value = 111;
byte[] data = new byte[2];
data[1] = (byte)(value & 255);
data[0] = (byte)((value >> 8) & 255);
jean121
Posts: 1
Joined: Thu Apr 07, 2022 7:50 am

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by jean121 » Thu Apr 07, 2022 7:55 am

alt wrote:
Mon Jul 12, 2021 3:02 pm
I think the new SMSC doesn't support user_message_reference TLV parameter. Better to ask the SMSC directly.
Yes It's right I Just Try thise
GB whatsapp
Alkiji
Posts: 1
Joined: Thu Aug 11, 2022 7:05 pm

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by Alkiji » Fri Aug 12, 2022 1:52 pm

Umm, hmmm, user_message_reference paramete, ah!..GBWhatsApp APK..Thanks for pointing out the error. I was doing the similar mistake.
papaisen
Posts: 1
Joined: Mon Jan 09, 2023 1:41 pm

Re: ESME_RSUBMITFAIL when trying to send SMS

Post by papaisen » Mon Jan 09, 2023 1:57 pm

I must say Thank you for this tips...Keep share with us...
Post Reply