Kamailio is so cool, you could even do it without the dialog module. You
could simply use a hash table (htable module) and when/if a 183/180 is
received store the callid in the table (with an expiration). Anytime a 200
is received check the table (it’s in memory, so really fast), if not found,
reject.
Super simple.
On Sat, 3 Oct 2020 at 13:51, Valentin Christoph <
Christoph.Valentin(a)kontron.com> wrote:
I am not quite sure, but I would try to store a long-term flag with the
help of the dialog module.
[...]The dialog module provides dialog awareness for the Kamailio proxy.
It's functionality is to keep track of the current dialogs, to offer
information about them (e.g. how many dialogs are active), and to manage
various characteristics of dialogs. The module
exports several functions that can be used directly from the configuration
route script as well as functions for the RPC interface. [...]
[...]10.6. $dlg_var(key)
This is a read/write variable that can be used to store custom values
assigned with a dialog (e.g. the URI of a billing-server, an assigned
emergency-server). This pseudo-variable will be available only for
subsequential requests after doing loose_route().
Note: You will receive "NULL", if there is no dialog for this request.[...]
Hint: ACK is a subsequential request
Anyway, I am wondering if your approach would be compliant to RFC 3261.
KR
------------------------------
*Von:* sr-users <sr-users-bounces(a)lists.kamailio.org> im Auftrag von
Valter Nogueira <valter(a)fastway.com.br>
*Gesendet:* Freitag, 2. Oktober 2020 17:01
*An:* Kamailio (SER) - Users Mailing List <sr-users(a)lists.kamailio.org>
*Betreff:* [SR-Users] Drop calls with response 200 without previous
180/183 reponses
I would like to use Kamailio to drop every call that is answered with no
previous 180 / 183 responses or with 180 / 183 responses with no media
attached (no SDP?).
Is it possible? How could I accomplish this?
Thanks,
Valter
_______________________________________________
Kamailio (SER) - Users Mailing List
sr-users(a)lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
--
Regards,
David Villasmil
email: david.villasmil.work(a)gmail.com
phone: +34669448337