I'm using Pcapy and impacket module for packet sniffer.
I'm able to capture the whole data in a variable and display it.
I want extract the IP addresses , Port no's and Payload data into separate variable and display it.

code is as follows:
Code:
import sys
import string
from threading import Thread

import pcapy
from pcapy import findalldevs, open_live
import impacket
from
...