[OpenSER-Devel] [ openser-Patches-1574844 ] usrloc module does not check socket field on DB operations

SourceForge.net noreply at sourceforge.net
Thu Oct 4 11:06:57 CEST 2007


Patches item #1574844, was opened at 2006-10-11 01:00
Message generated for change (Comment added) made by bogdan_iancu
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=1574844&group_id=139143

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.1.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Curt Moore (tgrman)
>Assigned to: Bogdan (bogdan_iancu)
Summary: usrloc module does not check socket field on DB operations

Initial Comment:
When sharing the same location table between multiple
OpenSER servers, the usrloc module does not make a
distinction between registered contacts on different
OpenSER sockets.  This patch ensures that the functions
in ucontact.c will check the socket field whenever
doing an update or delete operation on a record in the
location table.

In line with this change, I also added the socket
column in the location table into the primary key for
that table.

There likely should also be a check done in the
preload_domain() function in udomain.c so that a more
specific SQL query is run and only the contact records
relevant to the current OpenSER instance will be
returned from the DB.  Presently it seems somewhat
inefficient to pull all records from the table and then
discard those which do not match one of the currently
listening sockets, as is currently being done in the
dbrow2info() function.  

I have most of the code for this written but am a
little confused on how to get a listing of all of the
currently available OpenSER sockets and add them into
the query.  My version, not included in this patch,
works but just hardcodes the current IP, which works
for my case but is obviously not extensible and what
would be desired.

Please let me know if further information is needed if
there is anything I can do in order to get this patch
committed.

Thanks,
-Curt

----------------------------------------------------------------------

>Comment By: Bogdan (bogdan_iancu)
Date: 2007-10-04 12:06

Message:
Logged In: YES 
user_id=1275325
Originator: NO

My personal opinion is that socket cheking is something not necessary
(even bogus in some scenarios), but only by some small number of scenarios
which can be solved via different configuration (like using different
tables).

If nobody gives a good reason, IMHO we should close this item.

Regards,
Bogdan

----------------------------------------------------------------------

Comment By: Nobody/Anonymous (nobody)
Date: 2007-09-27 11:09

Message:
Logged In: NO 

curt,

what if there is a load balancer in front of the openser server farm that
forwards e.g. a register request to another openser server than the one
that processed the previous one?  shouldn't this another openser server be
also allowed to update the record?

-- juha


----------------------------------------------------------------------

Comment By: Henning Westerholt (henningw)
Date: 2007-09-27 10:54

Message:
Logged In: YES 
user_id=337916
Originator: NO

This patch is almost a year old, is this still necessary?

Cheers,

Henning

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=1574844&group_id=139143



More information about the Devel mailing list