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

Fix Plus upgrade install in Windows 7 #1194

Merged
merged 1 commit into from Sep 14, 2021

Conversation

mpheath
Copy link
Collaborator

@mpheath mpheath commented Sep 14, 2021

Windows 7 still has KmdUtil issues with the Plus installer while Windows 10 has been recently fixed.

Upgrade install from v0.9.5 to v0.9.6 was not a nice experience on Windows 7.

  • Upgrade install can cause CreateService error. Run Sandman without OS restart can cause the 1061 error.
  • Uninstall services\SbieDrv key remains.
  • Restart system removes the key.

Tried to remove services\SbieDrv key in the installer though makes no difference with errors.

Either restart the OS or run the command sc query sbiedrv removes the services\SbieDrv key. The command needs to run before the reinstall of the driver else an error condition may happen, in which an OS restart is needed.

The fix tested is to check if HKLM\SYSTEM\CurrentControlSet\services\SbieDrv exist, if it does, run sc query sbiedrv. This will run on Windows 7 and will not run on Windows 10. Not tested on Windows 8 or Windows 11. The command should be safe to run on any supported OS.

A better fix might be in KmdUtil source, though until solved there, this current fix can be used. Comments in kmdutil.c mentions the issue with the registry key possibly remaining.

   // fallback to stopping through SCM, otherwise the
   // driver registry key does not always disappear

The key may remain due to being in a undetermined state that sc query sbiedrv knows how to fix.

The Classic installer handles the KmdUtil errors though likes to do OS restarts. I prefer to avoid OS restarts if possible. i looked at SandboxieVS.nsi, though nothing that could be considered as an improvement with handling the driver as compared with Sandboxie-Plus.iss.

This fix helps the Plus installer run in Windows 7 similar to the experience in Windows 10.

@mpheath mpheath marked this pull request as ready for review September 14, 2021 06:44
@mpheath mpheath merged commit 3a8750c into sandboxie-plus:master Sep 14, 2021
@mpheath mpheath deleted the fix_win7 branch September 20, 2021 23:11
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.

None yet

1 participant