LLDP add PoE TLV
Checklist:
- [x] If you are new to Scapy: I have checked CONTRIBUTING.md (esp. section submitting-pull-requests)
- [x] I squashed commits belonging together
- [x] I added unit tests or explained why they are not relevant
- [x] I executed the regression tests (using
cd test && ./run_testsortox) - [x] If the PR is still not finished, please create a Draft Pull Request
This PR adds PoE (IEEE802.3bt) organization specific TLVs for LLDP layer
Different versions of PoE TLVs were added as separate classes instead of using ConditionalField to allow the user explicitly instantiate the desired TLV version.
Unit test failed because tshark is not installed on testing machine
Codecov Report
Merging #4346 (b736503) into master (0a2b2bc) will decrease coverage by
0.53%. Report is 3 commits behind head on master. The diff coverage is100.00%.
Additional details and impacted files
@@ Coverage Diff @@
## master #4346 +/- ##
==========================================
- Coverage 82.03% 81.50% -0.53%
==========================================
Files 350 350
Lines 82888 83230 +342
==========================================
- Hits 67994 67836 -158
- Misses 14894 15394 +500
| Files | Coverage Δ | |
|---|---|---|
| scapy/contrib/lldp.py | 94.62% <100.00%> (+2.09%) |
:arrow_up: |
Added PoE measure TLV. Again, macos tests are failing because tshark is not installed.
Changed to use ScalingField everywhere. Yet again, macos check failed because tshark is not installed.
Found the mistake in LLDPDUPowerViaMDI length. Fixed it and added tshark tests for this TLV (initially I thought it was unsupported by Wireshark)
Double-checked LLDPDUPowerViaMDIMeasure via Wireshark. For some strange reason, it reports the warning Invalid length, greather then expected even though package length, counting from Org code, is 26 octets long.