Skip to content

Commit

Permalink
Added support for Loopback
Browse files Browse the repository at this point in the history
  • Loading branch information
DidierStevens committed Dec 20, 2019
1 parent cb29184 commit 3fd191f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions python/ja3.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,8 @@ def process_pcap(pcap, any_port=False):
linktype = pcap.datalink()
if linktype == dpkt.pcap.DLT_LINUX_SLL:
decoder = dpkt.sll.SLL
elif linktype == dpkt.pcap.DLT_NULL or linktype == dpkt.pcap.DLT_LOOP:
decoder = dpkt.loopback.Loopback

results = list()
for timestamp, buf in pcap:
Expand Down
2 changes: 2 additions & 0 deletions python/ja3/ja3.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,8 @@ def process_pcap(pcap, any_port=False):
linktype = pcap.datalink()
if linktype == dpkt.pcap.DLT_LINUX_SLL:
decoder = dpkt.sll.SLL
elif linktype == dpkt.pcap.DLT_NULL or linktype == dpkt.pcap.DLT_LOOP:
decoder = dpkt.loopback.Loopback

results = list()
for timestamp, buf in pcap:
Expand Down
2 changes: 2 additions & 0 deletions python/ja3s.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,8 @@ def process_pcap(pcap, any_port=False):
linktype = pcap.datalink()
if linktype == dpkt.pcap.DLT_LINUX_SLL:
decoder = dpkt.sll.SLL
elif linktype == dpkt.pcap.DLT_NULL or linktype == dpkt.pcap.DLT_LOOP:
decoder = dpkt.loopback.Loopback

results = list()
for timestamp, buf in pcap:
Expand Down

0 comments on commit 3fd191f

Please sign in to comment.