Ovidiu Sas published a useful blog article about troubleshooting encrypted traffic flowing through Kamailio, it is available at:

It leverages siptrace module mirroring the SIP traffic to a running sngrep instance using HEP protocol, enabling live watching of what is received and sent by Kamailio, no matter of the transport layer. This method is particularly useful for TLS traffic, which it is not easy to catch directly from the network link layer.

The siptrace module an be controlled at runtime via RPC commands to enable/disable the traffic mirroring, providing the flexibility to mirror the traffic only when there is a need to troubleshoot.

Siptrace module can also store the traffic to the database or mirror to a Homer Sipcapture System, however the variant with sngrep is pretty lightweight, making easy to follow the traffic on its terminal-based diagrams.

For a complete different alternative, look at the sipdump module, in some cases could be useful by providing also Kamailio specific metadata associated with SIP routing.

If you write or are aware of other useful articles or tools for Kamailio, do not hesitate to contact us, we would gladly publish news about them.

Enjoy! Thanks for flying Kamailio!