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

Saving files on Classic hangs #519

Closed
ghost opened this issue Feb 3, 2021 · 12 comments
Closed

Saving files on Classic hangs #519

ghost opened this issue Feb 3, 2021 · 12 comments
Labels
fixed in next build Fixed in the next Sandboxie version Workaround Temporary or alternative solution

Comments

@ghost
Copy link

ghost commented Feb 3, 2021

This started happening a few months ago, on the most recent versions of Chrome, most recent versions of Sandboxie Classic, Windows 10 64bit. When I try to save a file the browser will hang for like 20-30 seconds until the save window pops up, a few more seconds when selecting a different folder or making a folder, and a few more seconds after clicking save. If I have multiple windows of chrome, only the window where I try to save will hang (the entire window, can't move to other tabs in that window, but can use the other windows).

Thanks a lot for all the work you do, really amazing job <3

@typpos
Copy link
Contributor

typpos commented Feb 4, 2021

v5.47.1 x64

Sorry, I'm unable to reproduce this.

Are you running any Chrome extensions that might interfere? Can you please try to reproduce following the steps below.

I did..

  • Start Windows Sandbox (ie, a clean VM in Win 10 x64)
  • Download and install Chrome 88.0.4324.146
  • Download and install Sandboxie Classic v.5.47.1 x64
  • Start Sandboxie Control
  • DefaultSandbox > Context Menu > Start From Start Menu > Chrome
  • Go to github sandboxie download page
  • Download a file (right click save as): works
  • Save page: works
Sandboxie.ini
[GlobalSettings]

Template=WindowsLive
Template=OfficeLicensing

[DefaultBox]

ConfigLevel=8
AutoRecover=y
BlockNetworkFiles=y
Template=SkipHook
Template=FileCppy
Template=qWave
Template=BlockPorts
Template=LingerPrograms
Template=Chrome_Phishing_DirectAccess
Template=Firefox_Phishing_DirectAccess
Template=AutoRecoverIgnore
RecoverFolder=%{374DE290-123F-4565-9164-39C4925E467B}%
RecoverFolder=%Personal%
RecoverFolder=%Favorites%
RecoverFolder=%Desktop%
BorderColor=#00FFFF,ttl
Enabled=y

[UserSettings_90A007A5]

SbieCtrl_UserName=wdagutilityaccount
SbieCtrl_BoxExpandedView=DefaultBox
SbieCtrl_NextUpdateCheck=1613005005

@ghost
Copy link
Author

ghost commented Feb 4, 2021

That's so odd, I've been having this issue for quite a few months on my main pc, and on my laptop, and continue to have it after 2 fresh windows installs (upgraded the SSDs). Just noticed that it happens on every browser, and even in incognito. With or without extensions.

I reproduced the steps you mentioned in Windows Sandbox (with the exact versions you mentioned) it still hangs while sandboxed (less time, something around 7 seconds, while on my main it can take 20-30 seconds), and the unsandboxed chrome works instantly.

This is what happens when I try to save in a sandboxed browser, I am trying to click the tabs, but the window is frozen waiting for the save dialog:
https://gyazo.com/f7618e2d95419ddbe21bccc8d0ceba1c

This is how fast it is while not sandboxed (it always used to be that fast until a few months ago):
https://gyazo.com/a9ccf132f45b0a1758aadea056feb3db

This is my sandbox.ini, almost identical, also tried copying yours and it did the same thing:
https://gyazo.com/eb6b30c527b4a4560fe50a8d3c2088f3

@typpos
Copy link
Contributor

typpos commented Feb 4, 2021

Reproduced, but unreliably.

I can reproduce the issue with notepad.exe, so it's not about browsers, but I can't reliably reproduce it nor can I pin it down to a specific issue in the file system or settings.

In some of my sandboxes on a physical PC, when an application shows the Save File Dialog, the application stalls for a number of seconds, anything between 2 and 10 seconds. In other sandboxes the dialog shows quickly. This has been the case for some time, probably months.

The application is not idle while stalling. Procmon lists around 35k queries by the app to registry and file system, fairly evenly spread out.

The confusing bits: I can copy such a sandbox and manually copy the files. This typically reproduces the problem in the new sandbox (stall times might change). When I empty the sandbox by deleting the files in unsandboxed File Explorer, the problem remains. But when I create a new sandbox with the same ini settings, then I can't reliably reproduce the problem. In one instance I changed the ini for a failng empty sandbox to that of a working one, which made the problem go away, and when I reverted the ini to the failing settings, the problem did not return, even when I restarted the sandboxie service !?!?

I am suspecting something outside the sandbox, like the Windows icon cache files, recycle bin, or some cached local network lookups.

That's so odd

I totally agree

@ghost
Copy link
Author

ghost commented Feb 9, 2021

Messed around with the sandbox settings and found that changing Applications/Accessibility and checking Screen Readers: JAWS, NVDA, Window-Eyes, System Access will make the save dialog pop up much faster, like a couple of seconds till it appears, down from 20-30 seconds, which is great, but don't really want to sacrifice protection. Still quite a bit slower than when unsandboxed.

The setting: https://gyazo.com/a1feec76ad382104d0254f3219a7af11

@DavidXanatos
Copy link
Member

hmm... and a on my PC that dialogs since somew10 update sometimes also hang for minutes even when no SB is involved :p

@typpos so copying it take the issue with it deleting files doesn't resolve it, so may be its the sandboxed registry does deleting RegHive has an effect on the issue?

@DavidXanatos DavidXanatos added more info needed More information is needed to move forward to investigate ToDo To be done labels Feb 9, 2021
@typpos
Copy link
Contributor

typpos commented Feb 9, 2021

does deleting RegHive has an effect on the issue

I deleted sandbox content with unsandboxed File Explorer, ie, all files including RegHive were deleted.

After more trials, I now suspect the issue is affected by setting NoAddProcessToJob=y. I don't know the security implications, though, and a proper solution would be preferrable. Also not sure if this works all the time. All with 5.47.0 x64.

The File Save As dialog opens quickly with:

[DefaultBox]

ConfigLevel=8
BorderColor=#00ffff,ttl,1
Enabled=y
NoAddProcessToJob=y

and it takes 10 seconds with

[DefaultBox]

ConfigLevel=8
BorderColor=#00ffff,ttl,1
Enabled=y

Both with:

GlobalSettings
[GlobalSettings]

Template=WindowsRasMan
Template=LogitechSetPoint
Template=AdobeLicensing
Template=AdobeAcrobatReader
Template=7zipShellEx
Template=WindowsLive
Template=nVidia_Stereoscopic3D
Template=OfficeLicensing
Template=SkipHook
Template=FileCppy
Template=AutoRecoverIgnore
Template=LingerPrograms
Template=BlockPorts
Template=qWave
FileRootPath=D:\Sandbox\%USER%\%SANDBOX%
TemplateReject=ScreenReader
SeparateUserFolders=y
KeyRootPath=\REGISTRY\USER\Sandbox_%USER%_%SANDBOX%
IpcRootPath=\Sandbox\%USER%\%SANDBOX%\Session_%SESSION%
EditAdminOnly=n
ForceDisableAdminOnly=n
ForgetPassword=n
BoxNameTitle=n

@Dyras
Copy link
Contributor

Dyras commented Feb 22, 2021

Still happening with 0.7.1 if that is of interest.

@DavidXanatos
Copy link
Member

grafik
this option fixes the issue, the down side is that it negatively impacts the ability to run one and teh sme application in two boxes.
I'm looking into a proper fix.
please report back if that fix works fro you as well.

@DavidXanatos
Copy link
Member

I have narrowed down he issue and am looking into properer fix

@Dyras
Copy link
Contributor

Dyras commented Mar 22, 2021

Seems to work just fine for me now when I've enabled that.

@ghost
Copy link
Author

ghost commented Mar 22, 2021

Installed Plus and same here, that setting seems to make the saving process very fast, seems to still be slower than unsandboxed but probably was always like that and just didn't notice cause it's more than fast enough for general use.

@DavidXanatos DavidXanatos added fixed in next build Fixed in the next Sandboxie version and removed ToDo To be done more info needed More information is needed to move forward under investigation labels Mar 22, 2021
@darchon7
Copy link

tried changing the option and that seems to have fixed the issue for me so far too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fixed in next build Fixed in the next Sandboxie version Workaround Temporary or alternative solution
Projects
None yet
Development

No branches or pull requests

4 participants