SIP Message Logging
The mod_sofia wiki page discusses how to enable SIP messages logging Debugging Sofia Sip.
The easiest way to turn it on is from the Freeswitch console. Type:
sofia profile internal siptrace on sofia profile external siptrace on
You can use wireshark or other network protocol analyser to view/save SIP and RTP. In windows xp it is not always possible to sniff traffic that doesn't leave the network card (e.g. if sip phone and freeswitch are on the same machine).
You can place a SIP or TCP proxy between sip phone and freeswitch and configure the sip phone to use the proxy as it's outbound proxy. The proxy should be configured to forward to freeswitch.
Grinder, a java load testing app, can be configured as a port forwarding TCP proxy. You cam configure it to listen to, say, 5090 and forward to freeswitch on 5060. The Sip UA should then be configured to use port 5090.
Note, due to the nature of SIP subsequent sip requests (e.g. BYE) won't use the proxy but will pass directly between sip phone and freeswitch unless the proxy is 'record routing'.