The SIP Protocol and IPv6
The SIP protocol was created at a time when IPv6 was already a few years old. Therefore, the SIP protocol has built in IPv6 support from start. One of the large groups behind the SIP protocol, the 3GPP, was working very early with SIP over IPv6.
Because of the lack of implementations of IPv6 in actual networks, the implementations are not there. And the IPv4-only implementations are not prepared for a life with two IP protocols.
To summarize: The protocol natively supports IPv6. The phones, clients and servers might not do it.
IPv6 in SIP URI’s
The SIP URI looks the same as with a URI with IPv4 addresses. As in all URI’s, an IPv6 address is enclosed in square brackets. The IPv6 address blocks are separated using a colon between every block. In many notations, a colon separate the hostname or IP address with the protocol port. In order to be able to parse the full IPv6 address and separate the port, the address is encapsulated with the square brackets like this example:
sip:6000@[2620:0:2ef0:7070:250:60ff:fe03:32b7]:5060;transport=tcp
IPv6 in Via headers
Via headers shows the path a request has taken across a SIP network and helps proxys routing responses back along the same path. For IPv6, the via header contains an IPv6 address in square brackets:
Via: SIP/2.0/TCP [2620:0:2ef0:7070:250:60ff:fe03:32b7]:5060;branch=z9hG4bK4882ebf2298267bc4ba97d222289760c.1;rport
IPv6 in SDP
IPv6 addresses in the SDP has the “IP6” marker – otherwise the SDP looks the same as the IPv4 SDP.
v=0 o=edvphone 1 1 IN IP6 2620:0:2ef0:7070:250:60ff:fe03:32b7 c=IN IP6 2620:0:2ef0:7070:250:60ff:fe03:32b7
Example SIP messages with IPv6 addresses
Copied from RFC 5118 – SIP IPv6 Torture messages
<br /> REGISTER sip:[2001:db8::10] SIP/2.0<br /> To: sip:user@example.com<br /> From: sip:user@example.com;tag=81x2<br /> Via: SIP/2.0/UDP [2001:db8::9:1];branch=z9hG4bKas3-111<br /> Call-ID: SSG9559905523997077@hlau_4100<br /> Max-Forwards: 70<br /> Contact: "Caller" <sip:caller@[2001:db8::1]><br /> CSeq: 98176 REGISTER<br /> Content-Length: 0<br />
SIP INVITE with IPv6 in message body and SDP
</p> <p>INVITE sip:user@[2001:db8::10] SIP/2.0<br /> To: sip:user@[2001:db8::10]<br /> From: sip:user@example.com;tag=81x2<br /> Via: SIP/2.0/UDP [2001:db8::20];branch=z9hG4bKas3-111<br /> Call-ID: SSG9559905523997077@hlau_4100<br /> Contact: "Caller"<br /> CSeq: 8612 INVITE<br /> Max-Forwards: 70<br /> Content-Type: application/sdp<br /> Content-Length: 268</p> <p>v=0<br /> o=assistant 971731711378798081 0 IN IP6 2001:db8::20<br /> s=Live video feed for today's meeting<br /> c=IN IP6 2001:db8::20<br /> t=3338481189 3370017201<br /> m=audio 6000 RTP/AVP 2<br /> a=rtpmap:2 G726-32/8000<br /> m=video 6024 RTP/AVP 107<br /> a=rtpmap:107 H263-1998/90000</p> <p>