Commands / Ports and connections

Ports and connections

sipp

Also sip, voip, call generator

Places or answers SIP calls to test VoIP: it drives the INVITE/200 OK/ACK/BYE exchange and reports the result.

SIP (Session Initiation Protocol) sets up voice calls (VoIP) on port 5060, usually over UDP. It reads like HTTP: an INVITE asks to start a call, the far end replies 100/180/200, the caller sends ACK, and a BYE ends it. SIP only signals; the audio itself flows separately as RTP. sipp acts as a caller (-sn uac) or an answering agent (-sn uas) using built-in scenarios.

sipp command usage

sipp -sn uac TARGET:5060 -m 1 -nd
sipp -sn uas -p 5060 -nd

Options

-sn uac
act as the caller (user agent client)
-sn uas
act as the answering agent (user agent server)
-m 1
stop after this many calls
-p 5060
the local SIP port to use
-nd
no interactive display: print the result and exit

sipp examples

sipp -sn uac 10.0.1.13:5060 -m 1 -nd
Places one call to the phone system and hangs up.
sipp -sn uas -p 5060 -nd
Answers incoming SIP calls on port 5060.

Reading the output

$ sipp -sn uac 10.0.1.13:5060 -m 1 -nd
  Successful call        |        0                  |        1
  Failed call            |        0                  |        0
  • Successful call counts calls that completed INVITE through BYE.
  • Failed call counts calls that timed out or were rejected.

Pitfalls

  • Classic SIP is plain text: a capture on 5060 shows the whole call set-up, numbers included.

Run it on real machines

Learn it on real machines.

Every lab is a small network of real Linux machines in your browser. Start with a free account: Google or email, no card.

Open this lab