<!DOCTYPE html><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">Hi All,</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">I still have problems with opensips3.4 push notifications:</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">Somehow INVITEs keep looping and get rejected.</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">Code:</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">...</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">route{</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">...</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">if (has_totag()) {</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">...</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">if (!is_method("ACK"))</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">        async (pn_process_purr("location"), resume_route);</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">...</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">}</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">...</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"># do lookup with method filtering</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">#--</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">lookup("location", "method-filtering");</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">$var(rc) = $retcode;</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">switch ($var(rc)) {</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">case 1:</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    # we found at least 1 non-PN contact!</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">xlog("L_INFO", "DBG: 1 contacts found non-PN ($var(rc))\n");</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    $var(do_relay) = true;</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    break;</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">case 2:</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    # success, but all contacts are PN-enabled, so we're</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    # sending PNs / awaiting re-registrations from them</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">xlog("L_INFO", "DBG: contacts found send PN? ($var(rc))\n");</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    $var(do_relay) = false;</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    #$avp(skip_relay) = true;</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    break;</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">default:</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    xlog("L_INFO", "DBG: no contacts found ($var(rc))\n");</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    t_reply(404, "Not Found");</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    exit;</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">}</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">if ($var(do_relay) && !t_relay())</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">    send_reply(500, "Internal Server Error");</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">...</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">if($var(do_relay) == true)</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">route(relay);</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">}</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">...</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">from log (looping log, it repeats untill server REJECT the INVITE or until CANCEL):</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">DBG:core:parse_headers: this is the first via</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.485706+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:_parse_to: end of header reached, state=10</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.485748+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:_parse_to: display={}, ruri={sip:<a href="mailto:to@dummy.com" target="_blank" tabindex="-1" style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box; color: rgb(0, 0, 255); text-decoration: underline;">to@dummy.com</a>}</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.485807+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:get_hdr_field: <To> [20]; uri=[sip:<a href="mailto:to@dummy.com" target="_blank" tabindex="-1" style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box; color: rgb(0, 0, 255); text-decoration: underline;">to@dummy.com</a>]</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.485854+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:get_hdr_field: to body [<sip:<a href="mailto:to@dummy.com" target="_blank" tabindex="-1" style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box; color: rgb(0, 0, 255); text-decoration: underline;">to@dummy.com</a>>#015#012]</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.485915+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:get_hdr_field: cseq <CSeq>: <1></div></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.485962+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:get_hdr_field: found end of header</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486040+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:parse_headers: flags=ffffffffffffffff</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486088+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:get_dummy_sip_msg: setting as static to 0xffffb1a612c0</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486145+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:evi_raise_event_msg: found subscriber E_UL_CONTACT_REFRESH</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486207+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:dup_ref_script_route_in_shm: dupping 0xffffaa264f60 [E_UL_CONTACT_REFRESH], idx 1, ver/cnt 1, to new 0xffffaa26d9e0 [E_UL_CONTACT_REFRESH], idx 1, ver/cnt 1</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486283+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:release_dummy_sip_msg: cleaning the static sip msg 0xffffb1a612c0</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486352+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:destroy_avp_list: destroying list (nil)</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486409+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:ipc_handle_job: received job type 0[RPC] from process 6</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486467+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:get_dummy_sip_msg: reusing the static sip msg 0xffffb1a612c0</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486533+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:parse_params: Parsing params for:[sip:rvg@82.151.164.77:57775;pn-prid=F1B7F53A99A35254A55CCAE2EDF80C1FAE12F353592BB6ED203ADA0175E34AD9:voip;pn-provider=apns;pn-param=ABCD1234.cllkit.voip;pn-silent=1;pn-timeout=0;transport=udp]</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486571+00:00 xsp2 /usr/local/sbin/opensips[2061136]: ERROR: -- ** --pn_send was called sip:<a href="mailto:user@dummy.com" target="_blank" tabindex="-1" style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box; color: rgb(0, 0, 255); text-decoration: underline;">user@dummy.com</a></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486651+00:00 xsp2 /usr/local/sbin/opensips[2061136]: ERROR:core:route_param_get: route $param variable accepts only integer indexes</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486746+00:00 xsp2 /usr/local/sbin/opensips[2061136]: message repeated 2 times: [ ERROR:core:route_param_get: route $param variable accepts only integer indexes]</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486787+00:00 xsp2 /usr/local/sbin/opensips[2061136]: ERROR:pn params:  <null>,#012                   ,#012                  </div></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486822+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:release_dummy_sip_msg: cleaning the static sip msg 0xffffb1a612c0</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.486913+00:00 xsp2 /usr/local/sbin/opensips[2061136]: DBG:core:destroy_avp_list: destroying list (nil)</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">2024-03-09T09:41:13.697168+00:00 xsp2 /usr/local/sbin/opensips[2061135]: DBG:core:parse_msg: SIP Request:</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">Any advice appreciated, regards,</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;">Ronald Geerligs</div><div style="outline: 0px; -webkit-tap-highlight-color: transparent; box-sizing: border-box;"><br></div></body></html>