pankaj kushwaha
pankaj kushwaha

Reputation: 379

What is the difference in contact and from header?

Can anyone please clarify - if both, contact and from header, contains the address of originator of SIP INVITE request, then what is the difference between them?

Upvotes: 5

Views: 4234

Answers (2)

Vladimir Ralev
Vladimir Ralev

Reputation: 1381

From header is the logical identity of the user that will be used for auth/callerid (i.e. sip:[email protected]). The Contact header is the TCP/IP network address where you should send all packets to (i.e. sip:[email protected]:43085;transport=tcp) - IP/port/transport info. While it's not entirely accurate, this is a good way to think about it in most cases.

Upvotes: 6

TMSZ
TMSZ

Reputation: 687

Contact header does not necessary contain address of originator, but lists URLs used to redirect future requests. It may be same as From, but doesn't have to. One common example is registration when SIP stacks (e.g. one used by Nokia E52 or re/baresip) are replacing user part with some unique identifier that helps distinguish following incoming requests.

Upvotes: 1

Related Questions