Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add linux cooked capture v2 #1138

Merged
merged 21 commits into from
Aug 7, 2023
Merged

Add linux cooked capture v2 #1138

merged 21 commits into from
Aug 7, 2023

Conversation

jiangjiongyu
Copy link
Contributor

No description provided.

@codecov
Copy link

codecov bot commented May 23, 2023

Codecov Report

Merging #1138 (31270f2) into dev (0725fa1) will decrease coverage by 0.08%.
The diff coverage is 71.79%.

@@            Coverage Diff             @@
##              dev    #1138      +/-   ##
==========================================
- Coverage   82.18%   82.10%   -0.08%     
==========================================
  Files         154      156       +2     
  Lines       19941    20093     +152     
  Branches     7531     7575      +44     
==========================================
+ Hits        16388    16497     +109     
- Misses       3038     3074      +36     
- Partials      515      522       +7     
Flag Coverage Δ
alpine315 68.55% <47.61%> (-0.14%) ⬇️
centos7 71.93% <52.57%> (-0.12%) ⬇️
fedora34 68.37% <46.66%> (-0.17%) ⬇️
macos-11 60.05% <55.93%> (-0.10%) ⬇️
macos-12 60.17% <55.93%> (-0.04%) ⬇️
macos-ventura 60.11% <56.41%> (-0.04%) ⬇️
mingw32 68.81% <43.92%> (-0.20%) ⬇️
mingw64 68.81% <43.92%> (-0.23%) ⬇️
npcap 82.12% <76.72%> (-0.10%) ⬇️
ubuntu1804 72.13% <49.52%> (-0.15%) ⬇️
ubuntu2004 69.21% <51.42%> (-0.18%) ⬇️
ubuntu2204 68.14% <46.15%> (-0.21%) ⬇️
ubuntu2204-icpx 59.18% <55.28%> (-0.03%) ⬇️
unittest 82.10% <71.79%> (-0.08%) ⬇️
windows-2019 82.16% <76.72%> (-0.05%) ⬇️
windows-2022 82.17% <76.72%> (-0.05%) ⬇️
winpcap 82.15% <76.72%> (-0.03%) ⬇️
zstd 71.97% <61.15%> (-0.11%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
Packet++/header/RawPacket.h 83.33% <ø> (ø)
Packet++/src/Packet.cpp 89.28% <66.66%> (-0.12%) ⬇️
Packet++/src/Sll2Layer.cpp 69.93% <69.93%> (ø)
Packet++/header/Sll2Layer.h 100.00% <100.00%> (ø)
Packet++/header/SllLayer.h 100.00% <100.00%> (ø)
Packet++/src/RawPacket.cpp 93.54% <100.00%> (ø)
Packet++/src/SllLayer.cpp 59.13% <100.00%> (ø)

... and 3 files with indirect coverage changes

@seladb seladb changed the base branch from master to dev May 29, 2023 07:35
README.md Outdated Show resolved Hide resolved
Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
Packet++/src/Sll2Layer.cpp Outdated Show resolved Hide resolved
Packet++/src/Sll2Layer.cpp Outdated Show resolved Hide resolved
Packet++/src/Packet.cpp Outdated Show resolved Hide resolved
Tests/Packet++Test/Tests/Sll2Tests.cpp Show resolved Hide resolved
Tests/Packet++Test/Tests/Sll2Tests.cpp Outdated Show resolved Hide resolved
Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
Tests/Packet++Test/Tests/Sll2Tests.cpp Outdated Show resolved Hide resolved
@seladb
Copy link
Owner

seladb commented Jun 8, 2023

@jiangjiongyu did you see my comments? do you have time to address them?

Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
Packet++/header/Sll2Layer.h Show resolved Hide resolved
Packet++/header/ProtocolType.h Outdated Show resolved Hide resolved
Tests/Packet++Test/PacketExamples/Sll2Packet.pcap Outdated Show resolved Hide resolved
Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
Packet++/header/SllLayer.h Outdated Show resolved Hide resolved
Packet++/src/Sll2Layer.cpp Outdated Show resolved Hide resolved
Tests/Packet++Test/Tests/Sll2Tests.cpp Outdated Show resolved Hide resolved
Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
@bitFiedler
Copy link

Is this patch needed to support linux cooked capture v2 in live capture into file?
Because I thought libpcap das that and pcap++ is only a c++ wrapper.

I tried to understand why tcpdump creates pcap files with linux cooked capture v2 and pcap++ don't.

@seladb
Copy link
Owner

seladb commented Jun 28, 2023

Is this patch needed to support linux cooked capture v2 in live capture into file? Because I thought libpcap das that and pcap++ is only a c++ wrapper.

I tried to understand why tcpdump creates pcap files with linux cooked capture v2 and pcap++ don't.

@bitFiedler this PR will support SLLv2 which is currently not a supported protocol. This means that packets in a pcap file with this link type won't be parsed correctly and will contain only one layer which is the generic PayloadLayer

@seladb
Copy link
Owner

seladb commented Jul 7, 2023

@jiangjiongyu did you see my recent comments? Do you think you'll have time to fix the PR so we can merge it?

@seladb
Copy link
Owner

seladb commented Jul 15, 2023

@jiangjiongyu
Copy link
Contributor Author

@jiangjiongyu please fix the tests as they are failing:

image

https://github.com/seladb/PcapPlusPlus/actions/runs/5510656390/jobs/10156347599?pr=1138

I already check the test file path.Why those test can't pass?

@seladb
Copy link
Owner

seladb commented Jul 19, 2023

@jiangjiongyu you fixed the previous issue, but now there are other problems that need fixing:

Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
Packet++/header/Sll2Layer.h Outdated Show resolved Hide resolved
Packet++/src/Sll2Layer.cpp Outdated Show resolved Hide resolved
Packet++/src/Sll2Layer.cpp Outdated Show resolved Hide resolved
README.md Show resolved Hide resolved
Tests/Pcap++Test/Common/PcapFileNamesDef.h Outdated Show resolved Hide resolved
Tests/Pcap++Test/Tests/FilterTests.cpp Outdated Show resolved Hide resolved
@seladb seladb merged commit 5666e28 into seladb:dev Aug 7, 2023
35 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants