Ask Your Question
0

How to get the corresponding rtp load through a known phone number and convert it to wav

asked 2020-11-24 06:10:33 +0000

lurry412 gravatar image

I am trying to use tshark for an experiment.Using a known phone number, use tshark to get the rtp load of the call after the call is hung up, and convert it into a wav file.

My current workflow is as follows: 1.Record the pcap when the call occurs by running the -f and -w of the tshark command. 2.Copy pcap through rsync -auz, because the tshark command that records the pcap file does not stop. 3.Get sip.Call-ID and sip.display.info by running the tshark command -Y sip.Method == BYE. 4.Filter out the sip.Call-ID corresponding to the phone number from sip.display.info through the known phone number. 5.Run the tshark command via sip.Call-ID -Y sip.Method == INVITE to get frame.number. 6.Run the tshark command -Y rtp.setup-frame through frame.number to get ssrc 7.Run the tshark command through ssrc to get the rtp.payload and convert it to a wav file.

Such a process is very inefficient. I would like to ask if there is any efficient way?

sorry about my English.Thanks and Best Regards.

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2020-11-24 08:37:47 +0000

Jaap gravatar image

So you're trying to build a SIP call recorder? If you want to do this from Tshark components than this is basically the way to do that. Adding a lot a scripting can automate this process. As you can tell from this, Tshark wasn't build for this.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2020-11-24 06:10:33 +0000

Seen: 192 times

Last updated: Nov 24 '20