You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Java API supports cancellation/interruption, which requires a thread that's waiting on a socket to be wake-up-able from another thread. To implement this Java opens either a loopback TCP connection or in recent versions a UNIX domain socket, so it can use e.g. WaitForMultipleObjectsEx to wake up either on TCP traffic or when another thread tries to cancel the operation, which it does by writing a single byte to the wakeup channel.
Outside of app containers this works.
Inside of app containers this fails in a rather inexplicable way, in which creating the UNIX domain socket in %TEMP% works but connecting to it as a client does not.
This causes Java to fail to establish the local cancellation connection and therefore the entire outbound network connection.
De-virtualizing %TEMP% using the AppManifest.xml fixes the problem, so the bug is definitely in Windows, most likely somewhere in bindflt or the UNIX domain sockets driver. Unfortunately, whilst de-virtualizing %TEMP% does fix the issue, it then causes the Microsoft Store to throw a fit and demand explanations about why it's being done, which seems to then trigger extended reviews and pushback.
So for App Isolation to work, bugs like this need to be fixed. Also please note: bugs need to be fixed in Win10 too, because the decision to ship an app as MSIX can't really be isolated to just Win11 users. But at the moment MS is not backporting fixes to Win10 and this makes MSIX harder to use. My company makes a product that packages apps for the desktop and this is one of the bugs we automatically work around.
The text was updated successfully, but these errors were encountered:
@tiangao-ms It's an app container issue, I'm not sure what team is responsible for that inside MS but as this is about Win32 sandboxing I guess it's not that important which team is responsible? Someone has to fix the bugs, right? The sandbox would depend on app containers regardless of whether MSIX existed or not.
Version
Windows 10/11
Repro Steps
Unexpected Results
Exception as discussed here: https://mail.openjdk.org/pipermail/nio-dev/2022-November/012525.html
Analysis:
De-virtualizing %TEMP% using the AppManifest.xml fixes the problem, so the bug is definitely in Windows, most likely somewhere in bindflt or the UNIX domain sockets driver. Unfortunately, whilst de-virtualizing %TEMP% does fix the issue, it then causes the Microsoft Store to throw a fit and demand explanations about why it's being done, which seems to then trigger extended reviews and pushback.
So for App Isolation to work, bugs like this need to be fixed. Also please note: bugs need to be fixed in Win10 too, because the decision to ship an app as MSIX can't really be isolated to just Win11 users. But at the moment MS is not backporting fixes to Win10 and this makes MSIX harder to use. My company makes a product that packages apps for the desktop and this is one of the bugs we automatically work around.
The text was updated successfully, but these errors were encountered: