Subject: [SIP] UAS & UAC with different port numbers?

From: Damian Farias <[email-masked]>
Date: Thu, 17 Aug 2000 14:40:16 +0100

Hello.

I'm having a little doubt about port numbers in sip addresses. I know
that, for the UAS (at least), there is a default port number (5060). My
question is:

i - should I use the same port for the UAC
ii - another specific port, like 5061 or
iii - ANY_PORT?

With the first case (which I have been trying to implement because I
believe it's the right one), I'm having some trouble because both UAS
and UAC are simultaneously listening for requests and responses
respectively, and the only solution I could think of for routing
incoming SIP messages (requests or responses) to the right listener, was
(for both caller party and called party the UAS listening was initially
enabled and UAC listening disabled):

(for the caller)
disabling UAS listening
enabling UAC listening
sending the initial INVITE through the UAC
receiving a response
disabling UAC listening
enabling UAS listening
sending ACK through the UAC

(and for the callee)
receiving a request
sending a response.

Another pseudo-solution to this is (which I believe to be incorrect)
implementing a message interpreter under the UAS & UAC. This entity
would receive the incoming network packets, find out what kind of SIP
message has arrived (request or response) and deliver it to the right
listener.

With the second case, should the UAC port number be part of the From
field in an outgoing SIP request, so the responding UAS would know where
to send its message?

And finally, in the last case, how would the remote UAS know where to
send its response?

I hope anyone can help me on this. Please tell me of any other solutions
you may know about, including those which would show I'm completely
insane and ignorant on SIP.

Thanks.
(I'm sorry for the long message)

_______________________________________________
SIP mailing list
[email-masked]
http://lists.bell-labs.com/mailman/listinfo/sip

---

From: Jonathan Rosenberg <[email-masked]>
Date: Thu, 17 Aug 2000 16:07:47 -0400

The port for UAC is used for responses. You can get responses on any
port you want. If its not 5060, you include that port in the Via header
of the outgoing request.

-Jonathan R.

-- 
Jonathan D. Rosenberg                       72 Eagle Rock Ave.
Chief Scientist                             First Floor
dynamicsoft                                 East Hanover, NJ 07936
[email-masked]                     FAX:   (973) 952-5050
http://www.cs.columbia.edu/~jdrosen         PHONE: (732) 741-7244
http://www.dynamicsoft.com