Skip to content

Add registry abstraction layer to ease the manipulation of [MS-RRP] RPC#4936

Merged
gpotter2 merged 1 commit intosecdev:masterfrom
Ebrix:master
Mar 4, 2026
Merged

Add registry abstraction layer to ease the manipulation of [MS-RRP] RPC#4936
gpotter2 merged 1 commit intosecdev:masterfrom
Ebrix:master

Conversation

@Ebrix
Copy link
Contributor

@Ebrix Ebrix commented Feb 26, 2026

Checklist:

  • If you are new to Scapy: I have checked CONTRIBUTING.md (esp. section submitting-pull-requests)
  • I squashed commits belonging together
  • I added unit tests or explained why they are not relevant
  • The unit tests are part of the Scapy-Red project, they use the RPC.
  • I executed the regression tests (using tox)
  • If the PR is still not finished, please create a Draft Pull Request

The PR does 2 things :

    1. create a "windows" folder to move windows related code (typically move Windows security objects from smb2 to windows/security.py)
    1. add a registry.py file which gives "high" level abstraction of the ms_rrp.py RPC to allow the dev to easily interact with the RPC

Some import paths are modified

@codecov
Copy link

codecov bot commented Feb 26, 2026

Codecov Report

❌ Patch coverage is 21.58895% with 454 lines in your changes missing coverage. Please review.
✅ Project coverage is 80.28%. Comparing base (85825ed) to head (ab86a72).

Files with missing lines Patch % Lines
scapy/layers/windows/registry.py 0.00% 257 Missing ⚠️
scapy/layers/msrpce/raw/ms_rrp.py 0.00% 151 Missing ⚠️
scapy/layers/windows/security.py 71.61% 44 Missing ⚠️
scapy/layers/smbclient.py 50.00% 1 Missing ⚠️
scapy/modules/ldaphero.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4936      +/-   ##
==========================================
- Coverage   80.64%   80.28%   -0.36%     
==========================================
  Files         370      375       +5     
  Lines       91986    92410     +424     
==========================================
+ Hits        74180    74192      +12     
- Misses      17806    18218     +412     
Files with missing lines Coverage Δ
scapy/layers/kerberos.py 58.66% <100.00%> (ø)
scapy/layers/ldap.py 67.11% <100.00%> (ø)
scapy/layers/msrpce/msnrpc.py 64.43% <100.00%> (+0.10%) ⬆️
scapy/layers/msrpce/mspac.py 90.78% <100.00%> (ø)
scapy/layers/msrpce/rpcclient.py 57.58% <100.00%> (ø)
scapy/layers/smb.py 76.78% <100.00%> (+0.08%) ⬆️
scapy/layers/smb2.py 90.28% <100.00%> (+1.86%) ⬆️
scapy/layers/smbserver.py 72.82% <100.00%> (+0.03%) ⬆️
scapy/layers/windows/__init__.py 100.00% <100.00%> (ø)
scapy/layers/windows/erref.py 100.00% <100.00%> (ø)
... and 6 more

... and 7 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Ebrix Ebrix marked this pull request as ready for review February 26, 2026 13:05
@gpotter2 gpotter2 self-assigned this Feb 26, 2026
Copy link
Member

@gpotter2 gpotter2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for the PR and your interest in Scapy ! This is very cool work !!!!

I have minor comments, very picky, but overall it looks great 👍

This PR also:
- regroups windows helpers in a scapy/layers/windows folder
@gpotter2 gpotter2 force-pushed the master branch 3 times, most recently from fae6ca9 to ab86a72 Compare March 4, 2026 12:31
@gpotter2 gpotter2 merged commit 3147e10 into secdev:master Mar 4, 2026
23 of 24 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.

2 participants