[OpenSER-Users] A function to know if a user is registered?

Iñaki Baz Castillo ibc at in.ilimit.es
Thu Aug 9 17:21:52 CEST 2007


Because I use pua_usrloc I want to apply pua_set_publish() in a REGISTER only 
if the user wasn't already registered (in order to avoid new NOTIFY with 
just "online" which can substitute the user client real state PUBLISH).

So I need a function to determine if the user is registered. I can't use:
  if ( ! lookup("location") { ...
because that function checks the URI in "location" table, and in a REGISTER 
message the URI is just:
  sip:server

So I need a function to check if the "To:" field ($tu) is registered. Is that 
exist? or should I make a custom avp_query and so?

Thanks.


-- 
Iñaki Baz Castillo
ibc at in.ilimit.es




More information about the sr-users mailing list