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

Proper unregistering of WinDivert #14

Open
TheMythologist opened this issue Jan 24, 2023 · 1 comment
Open

Proper unregistering of WinDivert #14

TheMythologist opened this issue Jan 24, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@TheMythologist
Copy link
Owner

Current premature termination will cause Windivert DLLs to still be loaded into memory (and thus undeletable)

A simple cleanup script/block

if pydivert.WinDivert.is_registered():
    pydivert.WinDivert.unregister()
@TheMythologist TheMythologist added the bug Something isn't working label Jan 24, 2023
@TheMythologist
Copy link
Owner Author

Further investigation:
We may just need to call pydivert.Windivert.close on the handle instead. But this should be handled with python's with context operator, so this may not be necessary at all.

Reference: https://pythonhosted.org/pydivert/#pydivert.WinDivert.close

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant