2018-04-06

Network Probe with a Raspberry Pi

From Cloudshark's - Building a network capture probe with Raspberry Pi
Published: 2016.0331

Here are the basics - 

  1. Install dumpcap on your Raspberry Pi (it comes as part of the tshark package): sudo apt-get install tshark
  2. Download our script: wget https://github.com/cloudshark/cloudshark-capture/archive/master.zip and unpack the script.
  3. Edit the api_token variable up at the top and insert your API token. You can change the promptvariable to y which will let the script ask you before uploading to CloudShark.
  4. If you’re using your own CloudShark system, enter the URL in the cloudshark_url variable. Otherwise leave it as https://www.cloudshark.org/ .
  5. Make the script executable: chmod +x cloudshark_capture.sh
  6. Run the script and pass it any arguments you would normally pass to dumpcap/tshark. For example, if you want to capture 5 packets on interface eth0: ./cloudshark_capture.sh -i eth0 -c 5
  7. Grab the returned URL and paste into your browser!
Now get creative, and figure out other practical applications.