[SR-Users] How to drop 200 OK in onreply_route ?

Denys Pozniak denys.pozniak at gmail.com
Thu Feb 4 11:47:14 CET 2021


Hello!

In the configuration below Kamailio Proxy creates a transaction for the SIP
PUBLISH to get info from the HTTP server in async mode.
But before creating a transaction, a synthetic 200 OK is sent, so that I
need somehow to drop the real 200 OK from the upstream Presence Server.
If drop 200 OK in *reply_route*, tm module starts to retransmit.
Those it is necessary that the 200 OK be consumed by the tm module, but
does not go further.


*if ( !is_method("PUBLISH") ) {*


*        sl_send_reply("200", "Ok");        t_newtran();*


*        $http_req(suspend) = 1;         http_async_query("$var(url)",
"CALLBACK");*
*}*


*route[CALLBACK] {*
*        <some header manipulation>*



*        t_on_reply("PUBLISH_REPLY");        route(RELAY);        exit;*
*}*






*onreply_route[PUBLISH_REPLY] {        if ( t_check_status("200") ) {
          drop; # Does not work!!!        }}*

Any advice is appreciated

-- 

BR,
Denys Pozniak
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20210204/265db51a/attachment.htm>


More information about the sr-users mailing list