Bug 1896868 Comment 2 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

FTR, I used [Procmon](https://learn.microsoft.com/en-us/sysinternals/downloads/procmon) to look at what the installer was doing when it was stuck in the [Windows Sandbox](https://learn.microsoft.com/en-us/windows/security/application-security/application-isolation/windows-sandbox/windows-sandbox-overview). As illustrated by the logs below, it was desperately trying to load `VCRUNTIME140.dll` from either the temporary directory where we have our stub installer EXE and DLLs or `C:\Windows\SysWOW64\VCRUNTIME140.dll` but my system didn't have that DLL and we don't ship it either as per Comment 0...

```
12:40:06.8858207 PM	setup-stub.exe	4868	QueryOpen	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsdDFC2.tmp\InetBgDL.dll	SUCCESS	CreationTime: 5/15/2024 12:40:00 PM, LastAccessTime: 5/15/2024 12:40:06 PM, LastWriteTime: 5/15/2024 12:40:00 PM, ChangeTime: 5/15/2024 12:40:00 PM, AllocationSize: 28,672, EndOfFile: 24,992, FileAttributes: A
12:40:06.8860526 PM	setup-stub.exe	4868	CreateFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsdDFC2.tmp\InetBgDL.dll	SUCCESS	Desired Access: Read Data/List Directory, Execute/Traverse, Synchronize, Disposition: Open, Options: Synchronous IO Non-Alert, Non-Directory File, Attributes: n/a, ShareMode: Read, Delete, AllocationSize: n/a, OpenResult: Opened
12:40:06.8861225 PM	setup-stub.exe	4868	CreateFileMapping	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsdDFC2.tmp\InetBgDL.dll	FILE LOCKED WITH ONLY READERS	SyncType: SyncTypeCreateSection, PageProtection: PAGE_EXECUTE_READWRITE
12:40:06.8862436 PM	setup-stub.exe	4868	CreateFileMapping	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsdDFC2.tmp\InetBgDL.dll	SUCCESS	SyncType: SyncTypeOther
12:40:06.8863814 PM	setup-stub.exe	4868	Load Image	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsdDFC2.tmp\InetBgDL.dll	SUCCESS	Image Base: 0x6f7a0000, Image Size: 0x48000
12:40:06.8865568 PM	setup-stub.exe	4868	CloseFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsdDFC2.tmp\InetBgDL.dll	SUCCESS	
12:40:06.8868100 PM	setup-stub.exe	4868	QueryOpen	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsdDFC2.tmp\VCRUNTIME140.dll	NAME NOT FOUND	
12:40:06.8871871 PM	setup-stub.exe	4868	CreateFile	C:\Windows\SysWOW64\VCRUNTIME140.dll	NAME NOT FOUND	Desired Access: Read Attributes, Disposition: Open, Options: Open Reparse Point, Attributes: n/a, ShareMode: Read, Write, Delete, AllocationSize: n/a

< same lines as above again and again and again... >
```

Copying the DLL to either location did the trick! The stub program was able to download the full build. I'll attach this DLL for reference.
FTR, I used [Procmon](https://learn.microsoft.com/en-us/sysinternals/downloads/procmon) to look at what the installer was doing when it was stuck in the [Windows Sandbox](https://learn.microsoft.com/en-us/windows/security/application-security/application-isolation/windows-sandbox/windows-sandbox-overview). As illustrated by the logs below, it was desperately trying to load `VCRUNTIME140.dll` from either the temporary directory where we have our stub installer EXE and DLLs or `C:\Windows\SysWOW64\VCRUNTIME140.dll` but my system didn't have that DLL and we don't ship it either as per Comment 0...

```
13:01:20.2153602	setup-stub.exe	5068	Load Image	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	Image Base: 0x74680000, Image Size: 0x48000
13:01:20.2155307	setup-stub.exe	5068	CloseFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	
13:01:20.2158063	setup-stub.exe	5068	QueryOpen	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\VCRUNTIME140.dll	NAME NOT FOUND	
13:01:20.2163282	setup-stub.exe	5068	CreateFile	C:\Windows\SysWOW64\VCRUNTIME140.dll	NAME NOT FOUND	Desired Access: Read Attributes, Disposition: Open, Options: Open Reparse Point, Attributes: n/a, ShareMode: Read, Write, Delete, AllocationSize: n/a
13:01:20.4172301	setup-stub.exe	5068	QueryOpen	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	CreationTime: 15-May-24 13:00:58, LastAccessTime: 15-May-24 13:01:20, LastWriteTime: 15-May-24 13:00:58, ChangeTime: 15-May-24 13:00:58, AllocationSize: 28,672, EndOfFile: 24,992, FileAttributes: A
13:01:20.4173443	setup-stub.exe	5068	CreateFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	NAME COLLISION	Desired Access: Generic Write, Read Attributes, Disposition: Create, Options: Synchronous IO Non-Alert, Non-Directory File, Attributes: A, ShareMode: Read, AllocationSize: 0
13:01:20.4175429	setup-stub.exe	5068	QueryOpen	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	CreationTime: 15-May-24 13:00:58, LastAccessTime: 15-May-24 13:01:20, LastWriteTime: 15-May-24 13:00:58, ChangeTime: 15-May-24 13:00:58, AllocationSize: 28,672, EndOfFile: 24,992, FileAttributes: A
13:01:20.4177022	setup-stub.exe	5068	CreateFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	Desired Access: Read Data/List Directory, Synchronize, Disposition: Open, Options: Synchronous IO Non-Alert, Non-Directory File, Attributes: n/a, ShareMode: Read, Delete, AllocationSize: n/a, OpenResult: Opened
13:01:20.4177421	setup-stub.exe	5068	CreateFileMapping	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	FILE LOCKED WITH ONLY READERS	SyncType: SyncTypeCreateSection, PageProtection: PAGE_EXECUTE_READWRITE
13:01:20.4177581	setup-stub.exe	5068	QueryStandardInformationFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	AllocationSize: 28,672, EndOfFile: 24,992, NumberOfLinks: 1, DeletePending: False, Directory: False
13:01:20.4179455	setup-stub.exe	5068	CreateFileMapping	C:	SUCCESS	SyncType: SyncTypeOther
13:01:20.4180625	setup-stub.exe	5068	CloseFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	
13:01:20.4183073	setup-stub.exe	5068	QueryOpen	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	CreationTime: 15-May-24 13:00:58, LastAccessTime: 15-May-24 13:01:20, LastWriteTime: 15-May-24 13:00:58, ChangeTime: 15-May-24 13:00:58, AllocationSize: 28,672, EndOfFile: 24,992, FileAttributes: A
13:01:20.4184748	setup-stub.exe	5068	CreateFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	Desired Access: Read Data/List Directory, Execute/Traverse, Synchronize, Disposition: Open, Options: Synchronous IO Non-Alert, Non-Directory File, Attributes: n/a, ShareMode: Read, Delete, AllocationSize: n/a, OpenResult: Opened
13:01:20.4185466	setup-stub.exe	5068	CreateFileMapping	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	FILE LOCKED WITH ONLY READERS	SyncType: SyncTypeCreateSection, PageProtection: PAGE_EXECUTE_READWRITE
13:01:20.4186510	setup-stub.exe	5068	CreateFileMapping	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	SyncType: SyncTypeOther
13:01:20.4188169	setup-stub.exe	5068	Load Image	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	Image Base: 0x74680000, Image Size: 0x48000

< same lines as above again and again and again... >
```

Copying the DLL to either location did the trick!

```
13:01:28.3417205	setup-stub.exe	5068	Load Image	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	Image Base: 0x74680000, Image Size: 0x48000
13:01:28.3418596	setup-stub.exe	5068	CloseFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\InetBgDL.dll	SUCCESS	
13:01:28.3420866	setup-stub.exe	5068	QueryOpen	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	CreationTime: 15-May-24 13:01:28, LastAccessTime: 15-May-24 13:01:28, LastWriteTime: 10-Jun-22 19:49:56, ChangeTime: 15-May-24 13:00:11, AllocationSize: 81,920, EndOfFile: 80,800, FileAttributes: A
13:01:28.3422469	setup-stub.exe	5068	CreateFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	Desired Access: Read Data/List Directory, Execute/Traverse, Synchronize, Disposition: Open, Options: Synchronous IO Non-Alert, Non-Directory File, Attributes: n/a, ShareMode: Read, Delete, AllocationSize: n/a, OpenResult: Opened
13:01:28.3423228	setup-stub.exe	5068	WriteFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	Offset: 0, Length: 81,920, I/O Flags: Non-cached, Paging I/O, Synchronous Paging I/O, Priority: Normal
13:01:28.3456757	setup-stub.exe	5068	SetEndOfFileInformationFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	EndOfFile: 80,800
13:01:28.3457371	setup-stub.exe	5068	CreateFileMapping	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	SyncType: SyncTypeOther
13:01:28.3458578	setup-stub.exe	5068	CreateFileMapping	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	FILE LOCKED WITH ONLY READERS	SyncType: SyncTypeCreateSection, PageProtection: PAGE_EXECUTE_READWRITE
13:01:28.3458810	setup-stub.exe	5068	QueryStandardInformationFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	AllocationSize: 81,920, EndOfFile: 80,800, NumberOfLinks: 1, DeletePending: False, Directory: False
13:01:28.3462799	setup-stub.exe	5068	CreateFileMapping	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	SyncType: SyncTypeOther
13:01:28.3464161	setup-stub.exe	5068	Load Image	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	Image Base: 0x74660000, Image Size: 0x15000
13:01:28.3466577	setup-stub.exe	5068	CloseFile	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\vcruntime140.dll	SUCCESS	
13:01:28.3470675	setup-stub.exe	5068	QueryOpen	C:\Users\WDAGUtilityAccount\AppData\Local\Temp\nsr4F06.tmp\WebBrowser.dll	SUCCESS	CreationTime: 15-May-24 13:00:57, LastAccessTime: 15-May-24 13:00:57, LastWriteTime: 15-May-24 13:00:57, ChangeTime: 15-May-24 13:00:57, AllocationSize: 106,496, EndOfFile: 105,920, FileAttributes: A
```

When I added the missing DLL next to the stub program, it got unstuck but eventually failed, sigh. Not sure why, but I doubt it's a great idea to force a program to load DLLs on the fly like I did anyway...

OTOH when I copied the missing DLL to `C:\Windows\SysWOW64`, the installer successfully downloaded and installed Firefox \o/

Back to Bug 1896868 Comment 2