Extracting webRTC Audio(RTP) from a Firefox session

This guide is useful if you are working with SharpenCare to troubleshoot audio issues using Sharpen Q phone. This process allows the gathering of RTP(media) from the browser webRTC traffic. This is necessary if you need to either have unencrypted RTP for quality analysis, or you need RTP captured at the browser rather than the network interface as tcpdump or Wireshark would accomplish. Currently the only known way to gather RTP from a browser session into a log is through Firefox. Follow the steps below to setup.

The instructions vary slightly for Windows, MacOS, and Linux, so make sure you choose the correct set of instructions below.

Windows

Video demonstration
  1. Open Command Prompt

  2. Enter md "%USERPROFILE%\Desktop\RTPLogs" and press Enter

    1. This creates a new directory on the user’s desktop, ‘RTPLogs’

  3. Enter set MOZ_LOG=timestamp,signaling:5,jsep:5,RtpLogger:5 and press Enter

    1. This sets the logging levels for RTP and signaling

  4. Enter set MOZ_LOG_FILE=%USERPROFILE%\Desktop\RTPLogs\log.txt and press Enter

    1. This sets the logging destination path

  5. Identify the path of your Firefox installation (most commonly C:\Program Files\Mozilla Firefox)

  6. In the command prompt enter cd C:\Program Files\Mozilla Firefox and press Enter

  7. Launch Firefox by entering firefox.exe and press Enter

  8. Perform your test

  9. Close the browser

  10. Navigate to the ‘RTPLogs’ directory on your desktop to find your log files

  11. Select all files and add them to a new compressed zip file

    1. Press and hold (or right-click) the file or folder, select (or point to) Send to, and then select Compressed (zipped) folder.

      A new zipped folder with the same name is created in the same location.

  12. Send the zip file to SharpenCare

MacOS

  1. Open the terminal

  2. Enter cd and press return

  3. Enter mkdir Documents\RTPLogs and press return

    1. This creates a new directory on the user’s Documents directory, ‘RTPLogs’

  4. Enter export MOZ_LOG=timestamp,signaling:5,jsep:5,RtpLogger:5 and press return

    1. This sets the logging levels for RTP and signaling

  5. Enter export MOZ_LOG_FILE=~/Documents/RTPLogs/log.txt and press return

    1. This sets the logging destination path

  6. Identify the path of your Firefox installation (should be Applications/Firefox.app/Contents/MacOS)

  7. In the terminal enter cd /Applications/Firefox.app/Contents/MacOS and press return

  8. Launch Firefox by entering ./firefox-bin and press return

  9. Perform your test

  10. Close the browser

  11. Navigate to the ‘RTPLogs’ directory in your Documents directory to find your log files

  12. Select all files and add them to a new compressed zip file

    1. Highlight and right-click the files and choose “Compress…”

      A new zipped folder with the same name is created in the same location.

  13. Send the zip file to SharpenCare

Linux

  1. Open the terminal

  2. Enter cd and press Enter

  3. Enter cd Documents and press Enter

  4. Enter mkdir RTPLogs and press Enter

    1. This creates a new directory on the user’s Documents directory, ‘RTPLogs’

  5. Enter export MOZ_LOG=timestamp,signaling:5,jsep:5,RtpLogger:5 and press Enter

    1. This sets the logging levels for RTP and signaling

  6. Enter export MOZ_LOG_FILE=~/Documents/RTPLogs/log.txt and press Enter

    1. This sets the logging destination path

  7. Identify the path of your Firefox installation (commonly /usr/lib64/firefox)

  8. In the terminal enter cd /usr/lib64/firefox and press Enter

  9. Launch Firefox by entering ./firefox and press Enter

  10. Perform your test

  11. Close the browser

  12. Navigate to the ‘RTPLogs’ directory in your Documents directory to find your log files

  13. Select all files and add them to a new compressed zip file

    1. Highlight and right-click the files and choose “Compress…”

      A new zipped folder with the same name is created in the same location.

  14. Send the zip file to SharpenCare

 

Related content