一、UAS接受UAC的INVITE
1--------------------------------------------------------------------
INVITE sip:10.21.5.122:5070 SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:5080;rport;branch=z9hG4bK84228
Max-Forwards: 70
To: <sip:10.21.5.122:5070>
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK05791102
Call-ID: 448769130314@127.0.0.1
CSeq: 1 INVITE
Contact: <sip:bob@127.0.0.1:5080>
Expires: 3600
User-Agent: mjsip stack 1.6
Content-Length: 148
Content-Type: application/sdp
v=0
o="Bob" <sip:bob@10.21.5.37> 0 0 IN IP4 127.0.0.1
s=Session SIP/SDP
c=IN IP4 127.0.0.1
t=0 0
m=audio 4000 RTP/AVP 0
a=rtpmap:0 PCMU/8000
2--------------------------------------------------------------------
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 127.0.0.1:5080;branch=z9hG4bK84228;received=10.21.5.37;rport=5080
To: <sip:10.21.5.122:5070>
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK05791102
Call-ID: 448769130314@127.0.0.1
CSeq: 1 INVITE
Server: mjsip stack 1.6
Content-Length: 0
3--------------------------------------------------------------------
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 127.0.0.1:5080;branch=z9hG4bK84228;received=10.21.5.37;rport=5080
To: <sip:10.21.5.122:5070>
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK05791102
Call-ID: 448769130314@127.0.0.1
CSeq: 1 INVITE
Server: mjsip stack 1.6
Content-Length: 0
4--------------------------------------------------------------------
SIP/2.0 200 OK
Via: SIP/2.0/UDP 127.0.0.1:5080;branch=z9hG4bK84228;received=10.21.5.37;rport=5080
To: <sip:10.21.5.122:5070>;tag=6ce0d0898ed82063
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK05791102
Call-ID: 448769130314@127.0.0.1
CSeq: 1 INVITE
Contact: <sip:alice@10.21.5.122:5070>
Server: mjsip stack 1.6
Content-Length: 150
Content-Type: application/sdp
v=0
o="Bob" <sip:bob@10.21.5.37> 0 0 IN IP4 127.0.0.1
s=Session SIP/SDP
c=IN IP4 10.21.5.122
t=0 0
m=audio 3000 RTP/AVP 0
a=rtpmap:0 PCMU/8000
5--------------------------------------------------------------------
ACK sip:alice@10.21.5.122:5070 SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:5080;rport;branch=z9hG4bK29925
Max-Forwards: 70
To: <sip:10.21.5.122:5070>;tag=6ce0d0898ed82063
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK05791102
Call-ID: 448769130314@127.0.0.1
CSeq: 1 ACK
Contact: <sip:bob@127.0.0.1:5080>
Expires: 3600
User-Agent: mjsip stack 1.6
Content-Length: 0
6--------------------------------------------------------------------
BYE sip:alice@10.21.5.122:5070 SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:5080;rport;branch=z9hG4bK79827
Max-Forwards: 70
To: <sip:10.21.5.122:5070>;tag=6ce0d0898ed82063
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK05791102
Call-ID: 448769130314@127.0.0.1
CSeq: 2 BYE
User-Agent: mjsip stack 1.6
Content-Length: 0
7---------------------------------------------------------------------
SIP/2.0 200 OK
Via: SIP/2.0/UDP 127.0.0.1:5080;branch=z9hG4bK79827;received=10.21.5.37;rport=5080
To: <sip:10.21.5.122:5070>;tag=6ce0d0898ed82063
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK05791102
Call-ID: 448769130314@127.0.0.1
CSeq: 2 BYE
Server: mjsip stack 1.6
Content-Length: 0
二、UAS拒绝UAC的INVITE
1--------------------------------------------------------------------
INVITE sip:10.21.5.122:5070 SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:5080;rport;branch=z9hG4bK64835
Max-Forwards: 70
To: <sip:10.21.5.122:5070>
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK42166145
Call-ID: 610463019331@127.0.0.1
CSeq: 1 INVITE
Contact: <sip:bob@127.0.0.1:5080>
Expires: 3600
User-Agent: mjsip stack 1.6
Content-Length: 148
Content-Type: application/sdp
v=0
o="Bob" <sip:bob@10.21.5.37> 0 0 IN IP4 127.0.0.1
s=Session SIP/SDP
c=IN IP4 127.0.0.1
t=0 0
m=audio 4000 RTP/AVP 0
a=rtpmap:0 PCMU/8000
2--------------------------------------------------------------------
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 127.0.0.1:5080;branch=z9hG4bK64835;received=10.21.5.37;rport=5080
To: <sip:10.21.5.122:5070>
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK42166145
Call-ID: 610463019331@127.0.0.1
CSeq: 1 INVITE
Server: mjsip stack 1.6
Content-Length: 0
3--------------------------------------------------------------------
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 127.0.0.1:5080;branch=z9hG4bK64835;received=10.21.5.37;rport=5080
To: <sip:10.21.5.122:5070>
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK42166145
Call-ID: 610463019331@127.0.0.1
CSeq: 1 INVITE
Server: mjsip stack 1.6
Content-Length: 0
4--------------------------------------------------------------------
SIP/2.0 403 Forbidden
Via: SIP/2.0/UDP 127.0.0.1:5080;branch=z9hG4bK64835;received=10.21.5.37;rport=5080
To: <sip:10.21.5.122:5070>
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK42166145
Call-ID: 610463019331@127.0.0.1
CSeq: 1 INVITE
Server: mjsip stack 1.6
Content-Length: 0
5--------------------------------------------------------------------
ACK sip:10.21.5.122:5070 SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:5080;rport;branch=z9hG4bK64835
Max-Forwards: 70
To: <sip:10.21.5.122:5070>
From: "Bob" <sip:bob@10.21.5.37>;tag=z9hG4bK42166145
Call-ID: 610463019331@127.0.0.1
CSeq: 1 ACK
User-Agent: mjsip stack 1.6
Content-Length: 0