When it comes to the implementation of capturing traffic with the utilization of Wireshark, we have to follow all the required steps that are highlighted below by our experienced research folks.
Install Wireshark in Ubuntu
To install the Wireshark in Ubuntu, we have to implement the below mentioned commands in the terminal.
sudo add-apt-repository ppa:wireshark-dev/stable
sudo apt update
sudo apt install wireshark
Program for Capture Traffic Packets Using Wireshark
In addition, Wireshark uses pcap to capture packets such as Unix-like systems implement pcap in the libpcap library and Windows uses a port of libpcap known as WinPcap. NS-3 code is used to program and write the trace file in .pcap format.
- Trace code based on lrWpan network
lrWpanHelper.EnablePcapAll (std::string (“lr-wpan-data”), true);
AsciiTraceHelper ascii;
Ptr<OutputStreamWrapper> stream = ascii.CreateFileStream (“lr-wpan-data.tr”);
lrWpanHelper.EnableAsciiAll (stream);
- Trace code based on wimax network
wimax.EnablePcap (“wimax-simple-ss0”, ssNodes.Get (0)->GetId (), ss[0]->GetIfIndex ());
wimax.EnablePcap (“wimax-simple-ss1”, ssNodes.Get (1)->GetId (), ss[1]->GetIfIndex ());
wimax.EnablePcap (“wimax-simple-bs0”, bsNodes.Get (0)->GetId (), bs->GetIfIndex ());
In fact, we are always ready to support you guys in the research platform so you can reach us to acquire more.