Under what circumstances would this happen, practically?
A previously allocated port for a recently shutdown connection is not immediately
recycled.
On Dec 19, 2022, at 4:22 PM, Benjamín Visón
<bvisonl(a)gmail.com> wrote:
Hello!
I'm examining the WebSocket module and I am wondering how it handles multiple
connections from the same port.
For context, imagine the following scenario:
UA1 ==> Load Balancer:41914 ==> Kamailio (WS)
UA2 ==> Load Balancer:41914 ==> Kamailio (WS)
Now, imagine Kamailio perceives UA1 from port 41914. What happens if that UA1 suddenly
drops and another UA2 comes in from the same port? (before the connection closed event is
fired for UA1)
I understand by looking at the source code that `wsconn_add` is called and that this new
connection is added to the list. But what happens with the previous UA entry? does it gets
overwritten or does it stays there?
The reason for my question is: I am perceiving the above scenario like this:
Let's say UA1 is sip:d3315cf8@9a431b1f90e5.invalid;transport=ws SIP/2.0
and UA2 is sip:asd08a08@555343439666.invalid;transport=ws. If UA2 comes in and takes over
the port that UA1 was using, and I send an INVITE to UA1 UA2 ends up receiving the invite
(obviously because it now has that port allocated).
So what I am thinking is that both d3315cf8(a)9a431b1f90e5.invalid and
asd08a08(a)555343439666.invalid are mapped to the same port for a short period of time.
Thoughts?
Saludos,
Benjamín Visón / IT Engineer / Software Developer
bvisonl(a)gmail.com / (829)-664-5163
https://www.linkedin.com/in/bvisonl/
__________________________________________________________
Kamailio - Users Mailing List - Non Commercial Discussions
To unsubscribe send an email to sr-users-leave(a)lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the sender!
Edit mailing list options or unsubscribe:
--
Alex Balashov | Principal | Evariste Systems LLC
Tel: +1-706-510-6800 / +1-800-250-5920 (toll-free)
Web: