wireshark, python, and Excel for graphing TCP window sizes

Filter the packets in which you are interested. In this case, we filter on the source IP…

…then export the packets to a CSV file…

…which we then parse in python to produce another CSV file…

f = open("good.csv","w")
for line in open("goodpackets.csv"):
  tmp = line.split(",")
  for elem in tmp[6].split(" "):
    if elem.find("Win=") > -1:
      f.write(tmp[1] + "," + str(elem.split("=")[1]) + '\n')

…for display and graphing in Excel…

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.