In SIP we have user-agents (clients and servers) and control-servers. The user-agents handle the signaling and media. The control servers handle only the SIP signaling. Using control-servers in peer-to-peer model serves the purpose of having more control over the sip cloud and doing some sort of translation on SIP message level. Having control means offering more services to the customers and getting more money (Business).
So how this model (Peer to Peer with control servers) looks like ?
As we see in the figure below the user-agent A sends its call (SIP control messages not the media) through its proxy (The proxy which is responsible for user A). You can call it the home proxy or the outgoing proxy or the mom proxy (for fun).
Remember i can ask my mom to do something for me at home but it is not suitable to ask my neighbor to do it for me. You got it !!! More control by the home proxy.
So the SIP as peer-to-peer model is not pure peer-to-peer model for signaling but it is pure peer-to-peer model for media.
DNS lookup: Each proxy has the IP addresses of its own registered users in its local database. SIP registration process is done before SIP call establishment. When the local proxy wants to route a call (SIP message) depending on the R-URI (Requested URI) it asks the DNS server about the IP address of the targeted domain and forward the call to the IP address returned from DNS server which is the IP address of the Ingoing proxy.
More Information: What does ”Peer-to-Peer Networking” mean?