title: How to capture traffic in python
body: <p>I have a webdriver using selenium that opens a browser for me, points it to an ip Address, does a bunch of stuff and closes.</p>
  
  <p>I want to know all of the urls accessed during this time. That is, any ads that are loaded, any css calls that were made out to any url and so on. </p>
  
  <p>Here is the code im using</p>
  
  <pre><code>from selenium import webdriver
  
  browser = webdriver.Firefox(profile) # Get local session of firefox
  browser.get(url) # Open a url and wait for it to finish
  </code></pre>