I'm writing my own simple soft phone, but I fail to understand the basics of how SIP works, so I wanted to see on a low level how a server responds to messages like the REGISTER request. I have a simple OpenWRT PBX in my router at home, and a couple of hard and Android softphones are working normally - they seem to register, perform calls both between themselves and outside too, so I'm sure it's functional. It's serving requests over UDP and port 5060.
But when I try to get a response from the server on a low level, how I used to do with tcp and telnet, just to see what's going on when a phone is working, the server doesn't seem to respond anything.
Can you please guide me how I can use netcat or some other telnet-like tool to see how the server responds over udp to any request, be them good or malformed?