<div id="geary-body" dir="auto"><div>Thank you for reply,</div><div>You referring to ticket <a href="https://github.com/OpenSIPS/opensips/issues/1778">https://github.com/OpenSIPS/opensips/issues/1778</a></div><div><br></div><div>volga629</div></div><div id="geary-quote" dir="auto"><br>On Wed, Nov 13, 2019 at 10:47, Răzvan Crainea <razvan@opensips.org> wrote:<br><blockquote type="cite"><div class="plaintext" style="white-space: pre-wrap;">Johan is right, there's currently no way the SMPP module sees the changes in the script.
But you can open a feature request for this, to add additional fields to the send_smpp_msg() command, to specify the from and to fields.

Best regards,
Răzvan

On 11/13/19 9:57 AM, Johan De Clercq wrote:
<blockquote>You need to resubmit the message to opensips. It,s only then that you will see the modification of the from header. Same applies for to.

Outlook voor iOS <<a href="https://aka.ms/o0ukef">https://aka.ms/o0ukef</a>> downloaden
------------------------------------------------------------------------
*Van:* Users <<a href="mailto:users-bounces@lists.opensips.org">users-bounces@lists.opensips.org</a>> namens volga629 via Users <<a href="mailto:users@lists.opensips.org">users@lists.opensips.org</a>>
*Verzonden:* woensdag, november 13, 2019 3:19 AM
*Aan:* Users
*Onderwerp:* [OpenSIPS-Users] replace From
Hello Everyone,
Which way will be correct to replace From with alias.

Code

         # Check valid DID is present
         alias_db_find("dbaliases", $fu, $avp(from_alias), "r");
         xlog("Found DID ~> $avp(from_alias)\r");
         if($avp(from_alias)) {
                 uac_replace_from( , $avp(from_alias));
         } else {
                 sl_send_reply(404, "Assigned did is required\n\r");
                 exit;
         }

I see in log

Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: Found DID ~> sip:4384783197@dev-sip.networklab.tld
Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: DBG:uac:w_replace_from: dsp=(nil) (len=0) , uri=0x7ffde612a6c0 (len=37)
Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: DBG:uac:replace_uri: uri to replace [sip:452390@dev-sip.networklab.tld], replacement is [sip:4384783197@dev-sip.networklab.tld], enclosed=0
Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: DBG:uac:replace_uri: encode is=<AAAAAAAGCgcOCHNVXEFtFwwGAx0MBFkBFx8bDhBFGA0GLnRsZA--> len=52
Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: DBG:rr:add_rr_param: adding (;vsf=AAAAAAAGCgcOCHNVXEFtFwwGAx0MBFkBFx8bDhBFGA0GLnRsZA--)

But original  from still in place

Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: DBG:proto_smpp:send_submit_or_deliver_request: sending submit_sm
Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: DBG:proto_smpp:send_submit_or_del iver_request: *FROM: 452390*
Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: DBG:proto_smpp:send_submit_or_deliver_request: TO:  destination number
Nov 13 01:13:18 dev1-fr /usr/sbin/opensips[5217]: DBG:proto_smpp:send_submit_or_deliver_request: MESSAGE: Hello type = 65537

Any help thank you.

volga629

_______________________________________________
Users mailing list
<a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>

</blockquote>
<div>-- 
</div>Răzvan Crainea
OpenSIPS Core Developer
  <a href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a>

_______________________________________________
Users mailing list
<a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</div></blockquote></div>