Redirecting secondary executable from AppData

Copper Contributor

I'm working on converting a Logitech Webcam Software to MSIX. Everything works as planned except for the auto updater. It prompts with an error message every time it checks in for updates

scb0024_0-1630001793449.png

After looking in process monitor, I can see that it is attempting to launch the update process in a location that doesn't exist:

scb0024_1-1630001852620.png

I need to redirect that call to the LocalAppData under %LocalAppData%\Packages\PackageName\LocalCache\Local. I've attempted to use the FileRedirectionFixUp to solve the issue but I think I'm missing something. Here is the config that I'm using:

{
    "applications": [
        {
            "id": "Launcher",
            "executable": "VFS/ProgramFilesX86/Logitech/LWS/Webcam Software/Launcher_Main.exe",
            "workingDirectory": "VFS/ProgramFilesX86/Logitech/"
        }
    ],
    "processes": [
        {
            "executable": "Launcher",
            "fixups": [
                {
                    "dll": "FileRedirectionFixup.dll",
                    "config": {
                        "redirectedPaths": {
							"knownFolders": [
								{
									"id": "LocalAppData",
									"relativePaths": [
										{
											"base": "Logitech® Webcam Software\\Logishrd\\LU2.0",
											"patterns": [
												"LULnchr\\.exe"
											]
										}
									]
								}
							]
                        }
                    }
                }
            ]
        }
    ]
}

After repackaging the application, it installs fine but it still isn't redirecting the executable. Any tips would be greatly appreciated, thank you!

2 Replies

I've since tested a few other things, I noticed that I had the wrong dll specified in my json and that has been changed. With the following being my main config now:

{
    "applications": [
        {
            "id": "Launcher",
            "executable": "VFS/ProgramFilesX86/Logitech/LWS/Webcam Software/Launcher_Main.exe",
            "workingDirectory": "VFS/ProgramFilesX86/Logitech/"
        }
    ],
    "processes": [
        {
            "executable": "Launcher",
            "fixups": [
                {
                    "dll": "FileRedirectionFixup32.dll",
                    "config": {
                        "redirectedPaths": {
							"knownFolders": [
								{
									"id": "LocalAppData",
									"relativePaths": [
										{
											"base": "Logitech® Webcam Software/Logishrd/LU2.0/",
											"patterns": [
												".*\\.exe"
											]
										}
									]
								}
							]
                        }
                    }
                }
            ]
        }
	]
}

Still the same result unfortunately

@scb0024 

It seems that the issue is that you expect a vendor implemented "auto updater" to work under MSIX.

MSIX is not going to allow that to work.

  • Package files may not be overwritten without the help of the FileRedirectionFixup.
  • Vendor updaters typically download an installer file and try to run it.  That installation has to happen outside of the container and would be natively installed.  You REALLY don't want that.
  • Even if the primary executable components could be changed via FRF copy, the FRF doesn't take action until the primary exe is already running so you'd never be able to run that replaced file.

Thus we routinely disable vendor auto updaters as part of the packaging process.

 

The closest equivalent to what you seek is to package with the vendor auto updater disabled, then create an "AppInstaller.xml" file placed on a server share, which points to the MSIX package also on the share. If you install using this xml file, when an update becomes available you would repackage the update using the same package name and a different version.  Once tested, then you can repackage the new version and update the AppInstaller.XML file on your server to cause the client system OS to update automatically.