- I downloaded the insider version of Microsoft Edge (Version 79.0.309.25).
- Enabled ClickOnce: edge://flags/#edge-click-once
- Tried to start ClickOnce Application from a browser.
This has worked as expected on 4 computers now, but not my own computer (even though it works with the stable version of Edge 44.18362.449.0).
I can see from the developer tool's network tab that the request is sent, and the request/response headers looks the same as in stable Edge (except user-agent). The console gives me the following warning message which I suspect is (part) of the reason it does not work:
Resource interpreted as Document but transferred with MIME type application/x-ms-application: "_my_clickonce_url_".
UPDATE: Apparently this does show for working computers aswell, I was mistaken.
I do not get this message on the other computers that are working fine.
Searching for this message gives me alot of hits (but for other mime-types), for example:
- Resource interpreted as Document but transferred with MIME type application/zip
- Chrome says: “Resource interpreted as Document but transferred with MIME type application/vnd.openxmlformats-officedocument.wordprocessingml.document”
- Correct headers, but Chrome says “Resource interpreted as Document”
They suggest fixes such as adding a download
attribute to the link (which does not work in my case), or changing the returned content-type (which should be correct in my case). There seems to be some code related changes, but I suspect my issue is environmental since it only fails on one computer out of 5.
One answer also suggested to check the regestry editor for Computer\HKEY_CLASSES_ROOT\
, but this also looks the same as other computer that works (.application
maps to content type application/x-ms-application
).
I suspect this might be more of a Microsoft support ticket than a stack overflow question, but I guess it depends on where the problem is. So I thought I'd start here.
running SystemInfo.exe
in cmd gives following (large chunk redacted):
OS Name: Microsoft Windows 10 Enterprise
OS Version: 10.0.18362 N/A Build 18362
System Manufacturer: Hewlett-Packard
System Model: HP Z230 Tower Workstation
System Type: x64-based PC
Hotfix(s): 6 Hotfix(s) Installed.
[01]: KB4506991
[02]: KB4503308
[03]: KB4506472
[04]: KB4509096
[05]: KB4524569
[06]: KB4524570
Comparison of request headers of a working version:
:authority: _redacted_host_
:method: GET
:path: _path_/_AppName_.application?url=https://_redacted_host_:443/_redacted_endpoint_
:scheme: https
accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
accept-encoding: gzip, deflate, br
accept-language: en-US,en;q=0.9
referer: _redacted_url_
sec-fetch-mode: navigate
sec-fetch-site: same-origin
sec-fetch-user: ?1
upgrade-insecure-requests: 1
user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.36 Safari/537.36 Edg/79.0.309.25
and a my non-working version:
:authority: _redacted_host_
:method: GET
:path: _path_/_AppName_.application?url=https://_redacted_host_:443/_redacted_endpoint_
:scheme: https
accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
accept-encoding: gzip, deflate, br
accept-language: sv,en;q=0.9,en-GB;q=0.8,en-US;q=0.7
referer: _redacted_url_
sec-fetch-mode: navigate
sec-fetch-site: same-origin
sec-fetch-user: ?1
upgrade-insecure-requests: 1
user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.36 Safari/537.36 Edg/79.0.309.25
And as you can see, they are exactly the same except for the accept-language.
Update: Running Process Monitor (procmon.exe) and comparing results between working and non-working machine I find that the ClickOnce Launcher process (dfsvc.exe) never starts on my computer.
msedge.exe goes and checks the following registry key:
HKCR\MIME\Database\Content Type\application/x-ms-application\Extension
=> ".application"
and then continues to find what seems to be the file extension handler:
HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.application
=> "msedge.exe"
The non-working browser never reaches the second step.