<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <font face="monospace">Hi Jacky,<br>
      <br>
      The m_dump() sends the MESSAGE to the AOR of the user, so,
      ideally, you should do take care of the "lookup(location)" in
      order to the get it properly routed.<br>
      <br>
      For the TLS part, do you use it between the end-point and
      opensips? if so, I guess the MESSAGE sent by m_dump() and looping
      back to opensips (for doing the lookup(location)) is via UDP ?<br>
      <br>
      I'm asking as from the TLS perspective the most important think to
      know is where (in the  routing logic) the TLS connection gets
      used/opened, as you need to be sure and correlate the destination
      IP (at the moment) with the IPs/mask you have in the TLS client
      domain.<br>
      <br>
      Best regards,<br>
    </font>
    <pre class="moz-signature" cols="72">Bogdan-Andrei Iancu

OpenSIPS Founder and Developer
  <a class="moz-txt-link-freetext" href="https://www.opensips-solutions.com">https://www.opensips-solutions.com</a>
OpenSIPS eBootcamp 2021 
  <a class="moz-txt-link-freetext" href="https://opensips.org/training/OpenSIPS_eBootcamp_2021/">https://opensips.org/training/OpenSIPS_eBootcamp_2021/</a></pre>
    <div class="moz-cite-prefix">On 9/28/21 3:03 AM, jacky z wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CAOB03Ds8wr7G9JXkCDhGS-G+LQu0dPwOS3aMOLTSh80ppHmeKg@mail.gmail.com">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div dir="ltr">
        <div dir="ltr">
          <div dir="ltr">
            <div dir="ltr">
              <div dir="ltr">Hi Team,
                <div><br>
                </div>
                <div>I want to use MSILO to forward offline messages. I
                  use TLS connections and have set up both server domain
                  and client domains. If we don't use outbound_proxy,
                  the logs show no error, but the message just was not
                  sent. I searched online and it was said that the
                  outbound proxy needs to be used. However, if we use
                  outbound_proxy, there will be errors- <span
style="color:rgb(36,41,47);font-family:-apple-system,BlinkMacSystemFont,"Segoe
                    UI",Helvetica,Arial,sans-serif,"Apple
                    Color Emoji","Segoe UI
                    Emoji";font-size:14px">no TLS client domain
                    found</span>. Actually, I have set up the client
                  domain. It seems the MSILO module can't recognize the
                  client domain. I have checked the messages were all in
                  the database table silo. Have you ever encountered
                  such issues? Any clue to debug? Thanks!</div>
                <div><br>
                </div>
                <div>Here are the scripts and logs</div>
                <div><br>
                </div>
                <div>
                  <p
style="box-sizing:border-box;margin-bottom:16px;color:rgb(36,41,47);font-family:-apple-system,BlinkMacSystemFont,"Segoe
                    UI",Helvetica,Arial,sans-serif,"Apple
                    Color Emoji","Segoe UI
                    Emoji";font-size:14px;margin-top:0px">When
                    m_dump() is called in "REGISTER":</p>
                  <div
style="box-sizing:border-box;color:rgb(36,41,47);font-family:-apple-system,BlinkMacSystemFont,"Segoe
                    UI",Helvetica,Arial,sans-serif,"Apple
                    Color Emoji","Segoe UI
                    Emoji";font-size:14px">
                    <pre style="white-space:pre-wrap;box-sizing:border-box;font-family:ui-monospace,SFMono-Regular,"SF Mono",Menlo,Consolas,"Liberation Mono",monospace;font-size:11.9px;margin-top:0px;margin-bottom:16px;padding:16px;overflow:auto;line-height:1.45;border-radius:6px"><code style="box-sizing:border-box;font-family:ui-monospace,SFMono-Regular,"SF Mono",Menlo,Consolas,"Liberation Mono",monospace;padding:0px;margin:0px;background:transparent;border-radius:6px;word-break:normal;border:0px;display:inline;overflow:visible;line-height:inherit">            if (m_dump()) {
                xlog("MSILO: offline messages dumped - if they were");
                }else{
                xlog("MSILO: no offline messages dumped");
                }; 
</code></pre>
                  </div>
                  <p
style="box-sizing:border-box;margin-top:0px;margin-bottom:16px;color:rgb(36,41,47);font-family:-apple-system,BlinkMacSystemFont,"Segoe
                    UI",Helvetica,Arial,sans-serif,"Apple
                    Color Emoji","Segoe UI
                    Emoji";font-size:14px">It can dump the message
                    from the database but can't send the message. Here
                    is the log:</p>
                  <p
style="box-sizing:border-box;margin-top:0px;color:rgb(36,41,47);font-family:-apple-system,BlinkMacSystemFont,"Segoe
                    UI",Helvetica,Arial,sans-serif,"Apple
                    Color Emoji","Segoe UI
                    Emoji";font-size:14px;margin-bottom:0px">Sep 18
                    17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_msg: method:<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_msg: uri:
                    <a class="moz-txt-link-freetext" href="sip:10000@xxx.com:5061;transport=tls">sip:10000@xxx.com:5061;transport=tls</a><br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_msg: version: <SIP/2.0><br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_headers: flags=ffffffffffffffff<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_via_param: found param type 232, =
                    <z9hG4bKe0c6.787dad54.0>; state=16<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_via: end of header reached, state=5<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_headers: via found,
                    flags=ffffffffffffffff<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_headers: this is the first via<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_to_param: transport=tls<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:_parse_to: end of header reached, state=29<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:_parse_to: display={}, ruri={sip:<a
                      href="mailto:10000@xxx.com" target="_blank"
style="box-sizing:border-box;background-color:transparent;text-decoration-line:none"
                      moz-do-not-send="true">10000@xxx.com</a>:5061}<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:get_hdr_field: [50]; uri=[sip:<a
                      href="mailto:10000@xxx.com" target="_blank"
style="box-sizing:border-box;background-color:transparent;text-decoration-line:none"
                      moz-do-not-send="true">10000@xxx.com</a>:5061]<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:get_hdr_field: to body [sip:<a
                      href="mailto:10000@xxx.com" target="_blank"
style="box-sizing:border-box;background-color:transparent;text-decoration-line:none"
                      moz-do-not-send="true">10000@xxx.com</a>:5061]<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:get_hdr_field: cseq : <10><br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:get_hdr_field: content_length=78<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:get_hdr_field: found end of header<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_headers: flags=ffffffffffffffff<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:parse_headers: flags=78<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:proto_tls:proto_tls_send: no open tcp connection
                    found, opening new one<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:probe_max_sock_buff: getsockopt: snd is
                    initially 16384<br style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:probe_max_sock_buff: using snd buffer of
                    416 kb<br style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:init_sock_keepalive: TCP keepalive enabled
                    on socket 119<br style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:print_ip: tcpconn_new: new tcp connection
                    to: <a href="http://142.107.16.203:5061/"
                      target="_blank" moz-do-not-send="true">142.107.16.203</a><br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:tcpconn_new: on port 5061, proto 3<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:proto_tls:tls_conn_init: Creating a whole new
                    ssl connection<br style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    ERROR:proto_tls:tls_conn_init: no TLS client domain
                    found<br style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    ERROR:core:tcp_conn_new: failed to do proto 3
                    specific init for conn 0x7f0559e116b8<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    DBG:core:tcpconn_destroy: destroying connection
                    0x7f0559e116b8, flags 0018<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    ERROR:proto_tls:tls_sync_connect: tcp_conn_create
                    failed, closing the socket<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    ERROR:proto_tls:proto_tls_send: connect failed<br
                      style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    ERROR<span
                      style="box-sizing:border-box;font-family:"Apple
                      Color Emoji","Segoe UI
                      Emoji","Segoe UI
                      Symbol";font-size:1em;line-height:1;vertical-align:-0.075em">™️</span>msg_send:
                    send() to <a href="http://142.107.16.203:5061/"
                      target="_blank" moz-do-not-send="true">142.107.16.203:5061</a> for
                    proto tls/3 failed<br style="box-sizing:border-box">
                    Sep 18 17:29:55 sipserver /usr/sbin/opensips[9794]:
                    ERROR<span
                      style="box-sizing:border-box;font-family:"Apple
                      Color Emoji","Segoe UI
                      Emoji","Segoe UI
                      Symbol";font-size:1em;line-height:1;vertical-align:-0.075em">™️</span>t_uac:
                    attempt to send to 'sip:<a
                      href="mailto:10000@xxx.com" target="_blank"
style="box-sizing:border-box;background-color:transparent;text-decoration-line:none"
                      moz-do-not-send="true">10000@xxx.com</a>:5061;transport=tls'
                    failed</p>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a class="moz-txt-link-freetext" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>