How Registration works and fails

From Kolmisoft Wiki
Revision as of 14:59, 23 March 2016 by Nerijuss (talk | contribs) (Created page with 'This is description how SIP Registration works and what makes it fail. There are two parties in SIP Registration. Client and Server which accepts registration. In this example w…')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

This is description how SIP Registration works and what makes it fail.

There are two parties in SIP Registration. Client and Server which accepts registration. In this example we assume that Client is SIP Phone and Server is MOR server.

Registration is initiated by Phone.

SIP Phone            MOR
   |    REGISTER      |      (Phone sends initial REGISTER request to MOR) 
   |----------------->|
   |                  |
   | 401 Unauthorized |      (MOR responds with 401 Unauthorized which means that SIP Phone should include credentials (username and password) to its registration request)
   |<-----------------|
   |                  |
   |    REGISTER      |      (Phone repeats registration, but now it includes credentials)
   |----------------->|
   |                  |
   |     200 OK       |      (credentials are correct, so MOR responses with 200 OK; Phone is registered now; Device status is OK; MOR will send calls to Phone, because it is online)
   |<-----------------|
   |                  |
   |                  |
   |                  |
   |     OPTIONS      |      (after 60 seconds, MOR sends OPTION packet to Phone to check if phone is still online)
   |<-----------------|
   |                  |
   |     200 OK       |      (phone responds to OPTION request with 200 OK, which says that is online, so Device status keeps OK)
   |----------------->|
   |                  |
   |                  |
   |                  |
   |     OPTIONS      |      
   |<-----------------|
   |                  |      (MOR keeps sending these OPTIONS packets every 60; Device status keeps OK, as long as Phone responds with OK to these requests)
   |     200 OK       | 
   |----------------->|
   |                  |
          ...

          ...

   |     OPTIONS      |      
   |<-----------------|      (now, if for some reasons, Phone stops responding to OPTIONS sent by MOR, Device status becomes UNREACHABLE;
   |                  |       it means that Phone is not online anymore and therefore MOR will not send calls to this Phone)
   |     OPTIONS      |      
   |<-----------------|
   |                  |
   |     OPTIONS      |      
   |<-----------------|
 
          ...
          
          ...
   |     OPTIONS      |      
   |<-----------------|      (MOR will keep trying to send OPTIONS packets and will expect response for 1 hour after last response from phone)
   |                  |
   |     OPTIONS      |      
   |<-----------------|
   |                  |
   |     OPTIONS      |      
   |<-----------------|
   |                  |
   |                  |
   |                  |      (if, after one hour of trying, Phone is still not reponding, MOR stops trying; Device status becomes UNKNOWN;
   |                  |       now Phone can become reachable again only by repeating REGISTRATION again)
   |                  |