damienvanrobaeys / Run-in-Sandbox

Run PS1, VBS, CMD, EXE, MSI, Intunewin, MSIX, or extract ISO, ZIP in Windows Sandbox very quickly just from a right-click
https://www.systanddeploy.com/2023/06/runinsandbox-quick-way-to-runextract.html
763 stars 86 forks source link

Sandbox constantly refreshing #38

Closed danzulfic closed 1 year ago

danzulfic commented 1 year ago

Loving the features included in this tool. An issue I'm running into is that if I use sandbox from your tool, it constantly refreshes the sandbox and closes all open windows. If I run sandbox natively it does not refresh at all. Any ideas of what may be causing the issue?

Joly0 commented 1 year ago

Hey, could you maybe elaborate a bit clearer what you mean by "it constantly refreshes the sandbox"? I have unfortunately no clue what you mean with this and i have never seen anything that would come close to your description ever

danzulfic commented 1 year ago

Hey, so when I run the application setup file from file explorer in sandbox. What will happen is the sandbox will almost restart every 20 seconds and close all of the windows that I have open. It won't fully restart the as stuff like PSADT will stay open and the application I'm testing will stay installed. Its very odd, I don't have the same issues when I run a normal sandbox.

Joly0 commented 1 year ago

Thats not really helping. Could you kindly tell us the software you want to run in sandbox, how you installed run-in-sandbox and how you run the software you want to run inside the sandbox?

Run-in-sandbox doesnt close any application by itself and it cant refresh the sandbox aswell.

All that run-in-sandbox does, is create a .wsb file (config file for running sandboxes) with your configuration and starts that. Afterwards, run-in-sandbox does what you tell it to do, but only inside the created sandbox

danzulfic commented 1 year ago

Let me see if I can break it down a bit better.

I run many applications, but lets take Zoom for example with a deployable .msi. Once I run and add the /qn flag and run it in sandbox. The desktop will look like such: image

If I open file explorer or registry editor to see what keys/files have been added. image

It will refresh which is the best way I can explain it. It will close every window with a black screen and then go back to the regular desktop view: image image

This issue only comes up if I run from the run-in-sandbox. If open a sandbox window and then copy the .msi file over this issue does not occur.

Joly0 commented 1 year ago

Hm, thats odd. But run-in-sandbox does nothing else than just running "msiexec.exe /i {specified msi file}" command inside the sandbox after starting it.

Nothing more, nothing less.

So i am not sure this is an issue with run-in-sandbox.

If you can, you could send us your .wsb file for that msi (should be located under c:\windows\temp), but you would have to do that while the sandbox is running or you would have to adjust the config file of run-in-sandbox so it doesnt cleanup the .wsb file after exit.

Maybe that could help identify the root cause of that issue, but i am afraid, this has nothing to do with run-in-sandbox

danzulfic commented 1 year ago

Just going to update this with a final note. I've updated to Windows 11 to test some features. The Sandbox isn't refreshing any longer in Windows 11.