-
-
Notifications
You must be signed in to change notification settings - Fork 137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Capture network traffic in a .pcap file #591
Comments
I like the idea for pure convenience and for having the feature to further analyze page loads on a deeper level. It may help future analysis and the development of novel insights. However, it will introduce browsertime into the packet capture business and will create a lot of new things we may need to worry about in the future, if we support this. I am a bit worried that it is more than simply starting/stopping tcpdump. e.g. for inspecting layer 7 we may need the encryption keys used for https, browsers do handle that differently. |
Capturing the raw .pcap file should be simple. WebPageTest uses WinPcap just to read packets from an interface and dump them to a file (here). TcpDump works in the same way. I agree that having the TLS keylog would be useful to decrypt the stream. That is simple for Chrome and Firefox (just set an environment variable), but for mobile could be hard. That could be left as future work, as the raw PCAP file already is useful. |
I'll be busy with preparing the coming sitespeed.io release the coming weeks, but if you have time @marty90 to do a PR of what it would look like, it would be interesting! |
I can try to implement it ;) What do you think? |
@marty90 have a go if you have time and then we can help out in a PR to find a good structure. best to test out and if you find it useful we can help you get it in. |
This was released today in 8.0.0. |
Hi,
I think a useful feature could be to create the
.pcap
file containing the network traffic exchanged by the browser and the server, likewebpagetest
does.It should not be difficult to implement. Just start
tcpdump
before starting the browser, and close it immediately after.The text was updated successfully, but these errors were encountered: