Hi
I'm using version 1.5.4 and the module userblacklist is not working how I was expecting.
The function check_user_black_list() returns the correct value. After some 5 minutes, it changes its return value. I'm blocking users that are not in the table. However, after this time, the functions says that they exist, but it is not true.
Someone know why it happens? Could it be a module's bug?
#avp 100 is a part of the username's RURI if(check_user_blacklist("$fU","$rd","$avp(s:100)")) {
sl_send_reply("403", "Forbidden"); exit; }
Tks, bruno machado
On Tuesday 19 October 2010, Bruno Machado wrote:
I'm using version 1.5.4 and the module userblacklist is not working how I was expecting. The function check_user_black_list() returns the correct value. After some 5 minutes, it changes its return value. I'm blocking users that are not in the table. However, after this time, the functions says that they exist, but it is not true.
Someone know why it happens? Could it be a module's bug?
Hi Bruno,
have you tried as well with the 1.5 branch state? After 1.5.4 has been released there were some a few fixes for the internal library that is used from the module. You probably don't refer to it, but the check_blacklist function caches also internally the database, so after changes you need to issue a fifo command.
Cheers,
Henning
Hi Henning
The last version tried was the 1.5.4. I will do what you say about the new files and I'll test the cfg with them. Finding the same results, I'll report to you.
Regarding the fifo, I also used it, trying to avoid that unexpected behavior, but it was not work. After some minutes, I can say that this function stops working. The only way I found was to restart the Kamailio. Another strange thing happened. I was testing the block function with an ATA. Redialing and redialing... The first 8 or 9 times, the call was denied by the function check_user_black_list(). I redialed once more and it was allowed! I didnt change anything in the database, neither used fifo. When I tried for
the last time, the invite was denied again. Weird...
In this case, I had to use other tools. So, I'm using avp_db_query at this moment.
Thanks for you reply, Henning.
Bruno Machado