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

Won't start on an offline PC #25

Open
llvs opened this issue Aug 2, 2024 · 2 comments
Open

Won't start on an offline PC #25

llvs opened this issue Aug 2, 2024 · 2 comments
Assignees
Labels
enhancement New feature or request under investigation May address in future based on results of investigation

Comments

@llvs
Copy link

llvs commented Aug 2, 2024

barcodrod.io installed properly on an offline Win11 machine from the github-downloaded install file but after clicking to start the app (no matter if immediately after installation or via Start menu) nothing happens. Only when the machine is connected to the internet (having provided the credentials in some other way), barcodrod.io opens up.
Does it need to fetch dependencies first?

The use case is to connect an offline laptop via webcam with a wifi network where the credentials come from a printed QR code. The built-in Win11 camera app can decode the QR code but needs a store app to handle it further and doesn't allow to copy the string (and therefore is totally useless).

I think this use case is important for barcodrod.io to shine as Win11 (with its camera app) doesn't help and your app could be the savior here.

@MarkHopper24
Copy link
Owner

Hi @llvs, thanks for the request. The GitHub hosted installer .msix is actually scraped from the MSFT Store. The main reason I went this route is because the Store package has the benefit of using the MSFT Store's code signing certificate, which I believe should be trusted on just about all Windows 10/11 machines. From a security perspective, I'm hesitant to publish an offline installer because it would be unsigned. Windows doesn't allow MSIX installations unless they're code-signed (without disabling security controls, using PowerShell, and enabling Developer Mode).

Since I don't plan on purchasing one for this project since it's FOSS, it would be difficult to offer a .MSI or .EXE setup installer available securely since it would be unsigned.

To your issue- I suspect that since this is the Store version of the app, it's failing to launch for one of two reasons:
Either it may need to contact Microsoft Store to acquire a license, or it's failing to install the Windows App Runtime which may need to be pulled from the Store. If you're able to either install the WinAppRuntime manually and/or launch the store while connected online once, I think it should work offline after that. FWIW, app usage can work completely offline. It's the install process that's a bit tricky.

I will investigate ways to package the .MSIX differently so it contains all relevant dependency packages for offline installer scenarios. In the meantime, the code is available so feel free to try those workarounds or build/modify locally for offline scenarios if you'd like.

@MarkHopper24 MarkHopper24 self-assigned this Aug 3, 2024
@MarkHopper24 MarkHopper24 added enhancement New feature or request under investigation May address in future based on results of investigation labels Aug 3, 2024
@MarkHopper24
Copy link
Owner

Hi @llvs

I believe I've found the root cause here, and it's because the .MSIX hosted in GitHub is the exact same as the Store version. Because it's the Microsoft-signed, store version, it requires an internet connection on installation for license acquisition through the Microsoft Store After first installation and launch, it should be able to be used fully offline. There's two options to solve this:

  1. Release an unsigned version that needs to be sideloaded via PowerShell (not ideal- Edge/Defender will likely see it as unsafe). However, I could post checksums for users to self-verify.
  2. I could acquire an offline, volume-licensed version of the Store buil through Winget, and provide that along with the .MSIX here. Only issue is these offline, volume-licensed versions are technically licensed against enterprises (you need to authenticate with Entra ID as an admin to download). I can acquire this just fine using my developer tenant, but I need to make sure that's not breaking any Terms & Conditions in the Microsoft Store.

TLDR; Two potential paths to fix, both with caveats.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request under investigation May address in future based on results of investigation
Projects
None yet
Development

No branches or pull requests

2 participants