I download pcap file from Wiki this PCAP
import binascii
import pyshark
cap = pyshark.FileCapture('200722_tcp_anon.pcapng')
for pkt in cap:
text = pkt.tcp.payload.raw_payload
print(text)
cap.close()
But I got an error
Traceback (most recent call last):
File "main.py", line 7, in <module>
text = pkt.tcp.payload.raw_payload
File "C:\Users\User\AppData\Local\Programs\Python\Python37-32\lib\site-packages\pyshark\packet\layer.py", line 36, in __getattr__
raise AttributeError()
AttributeError
Why is that?