8000 UUID cleanup by micolous · Pull Request #1882 · secdev/scapy · GitHub
[go: up one dir, main page]

Skip to content

UUID cleanup #1882

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

Closed
wants to merge 3 commits into from
Closed

UUID cleanup #1882

wants to merge 3 commits into from

Conversation

micolous
Copy link
Contributor
@micolous micolous commented Mar 2, 2019

There are multiple implementations of a UUID-like field, and some places where we don't use this at all (but could!). This pull request merges them, and brings it into a new scapy.field.UUIDField.

This impacts s.l.bluetooth, s.l.dhcp6, s.c.dce_rpc, s.c.opc_da and s.c.pnio_rpc.

  • Merge functionality of s.l.bluetooth.BTUUIDField and s.c.dce_rpc.UUIDField into s.fields.UUIDField
  • Moves s.c.dce_rpc.RandUUID to s.volatile
  • Adds support for RFC 4122 "versioned" UUIDs to RandUUID, and adds tests
  • Moves UUIDField tests that don't use EndiannessField from s/c/dce_rpc.uts to t/regression.uts
  • dhcp6: Migrates DUID_UUID.uuid to UUIDField, and adds tests (tested only with regression tests, based on my reading of the RFC)
  • opc_da: Migrate from PUUID to UUIDField, removes PUUID (tested only with regression tests)
  • pnio_rpc: Fix regressions from dce_rpc changes (tested only with regression tests)
  • Fix re module stomping in t/regression.uts

Tests still pass on py2.7 and 3.7 (skipping root/netaccess tests)

@codecov
Copy link
codecov bot commented Mar 2, 2019

Codecov Report

Merging #1882 into master will decrease coverage by 1.59%.
The diff coverage is 95.16%.

@@            Coverage Diff            @@
##           master    #1882     +/-   ##
=========================================
- Coverage   85.88%   84.29%   -1.6%     
=========================================
  Files         187      179      -8     
  Lines       42733    41667   -1066     
=========================================
- Hits        36701    35122   -1579     
- Misses       6032     6545    +513
Impacted Files Coverage Δ
scapy/layers/dhcp6.py 62.56% <ø> (-22.24%) ⬇️
scapy/layers/bluetooth.py 87.01% <ø> (+0.19%) ⬆️
scapy/contrib/opc_da.py 79.41% <ø> (+0.67%) ⬆️
scapy/contrib/dce_rpc.py 97.82% <100%> (+2.98%) ⬆️
scapy/contrib/pnio_rpc.py 91.85% <100%> (-0.39%) ⬇️
scapy/fields.py 91.75% <94.11%> (+0.08%) ⬆️
scapy/volatile.py 78.34% <95.38%> (+1.91%) ⬆️
scapy/arch/common.py 41.3% <0%> (-50%) ⬇️
scapy/contrib/isotp.py 65.97% <0%> (-22.34%) ⬇️
... and 41 more

micolous added 3 commits March 9, 2019 12:57
- Merge functionality of `s.l.bluetooth.BTUUIDField` and
  `s.c.dce_rpc.UUIDField`

- Moves `s.c.dce_rpc.RandUUID` to `s.volatile`

- Adds support for RFC 4122 "versioned" UUIDs to `RandUUID`, and adds tests

- Moves some `UUIDField` tests from `s/c/dce_rpc.uts` to `t/regression.uts`

- Migrates `s.l.dhcp6.DUID_UUID.uuid` to `UUIDField`, and adds tests

- Fix `re` stomping in `t/regression.uts`
@micolous
Copy link
Contributor Author
micolous commented Mar 9, 2019

GitHub's UI wouldn't let me flip this to "ready", so I created a new, non-draft PR in #1892.

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.

1 participant
0