Hi Inaki,

I think you made a small confusion here. t_relay() returns -5 and not 
lookup() - so you need to check the return of t_relay after the lookup

Regards,
bogdan

Iñaki Baz Castillo wrote:
> Hi, I set:
>
>
> -------------------------------------------
> dst_blacklist = gw:{( any , GW_IP, 0 , "" )}
>
> [...]
>       
>       t_on_branch("ON_BRANCH_TO_USER");
>
>       if (!lookup("location")) {
>               if ($rc == -5)
>                       xlog("L_WARN", "WARN:  Fraudulent Contact !!! \n");
>               sl_send_reply("404", "Not Registered");
>               exit;
>       }
>
>       t_relay();
>
> [...]
>
> branch_route[ON_BRANCH_TO_USER] {
>       use_blacklist("gw");
> }
> -------------------------------------------
>
>
>
> I do a fraudulent REGISTER for an AoR (with GW_IP in "Contact" header) and 
> when calling that AoR I get a correct "473 Filtered destination". But I don't 
> see the WARN, so "lookup(location)" didn't reply -5.
> Why not? the IP in Contact column for taht AoR is GW_IP, 
> why "lookup(location)" doesn't realize of it?
>
> It supposed that  "lookup()" returns -5 if the destination is filtered (black 
> listed):
> http://www.openser.org/docs/modules/1.3.x/tm.html#AEN336
>
>
> Maybe it's a bug?
>
>
>   


_______________________________________________
Users mailing list
[email protected]
http://lists.openser.org/cgi-bin/mailman/listinfo/users

Reply via email to