microsoft / microsoft/winget-cli

WinGet upgrade fails with 0x80070005 / 0x80073CF6 due to broken ACL inheritance on HKCU\Software\Classes\ActivatableClasses\Package

Open
#6,367 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Issue-Bug
Dominant language
C++
Stars
26.4k
Forks
1.8k
Avg merge
1d 11h
Merged PRs (30d)
15

Description

Hello,

I investigated a WinGet upgrade failure on Windows where WinGet failed during AppX package registration.

Symptoms:

  • winget upgrade failed with:
    • HRESULT 0x80070005 (ACCESS_DENIED)
    • HRESULT 0x80073CF6 (Package could not be registered)

The failure occurred only when running WinGet as the normal user.
Running elevated worked.

Investigation:

ProcMon showed failed registry operations under:

HKCU\Software\Classes\ActivatableClasses\Package\

with access denied during AppX registration.

The problem was not caused by WinGet itself, but by an incorrect ACL on:

HKCU\Software\Classes\ActivatableClasses\Package

Broken ACL:

The key had explicit ACE entries and inheritance was disabled.

Example:

D:PAI(A;CI;KR;;;WD)...

A clean test user profile had:

User: FullControl (inherited)
SYSTEM: FullControl (inherited)
Administrators: FullControl (inherited)
Restricted: ReadKey (inherited)
ALL APPLICATION PACKAGES: ReadKey (inherited)
Capability SID: ReadKey (inherited)

Fix:

Restored inheritance on:

HKCU\Software\Classes\ActivatableClasses\Package

Removed the incorrect explicit ACE:

(A;CI;KR;;;AC)

After restoring the ACL to the inherited structure, WinGet immediately started working again.

Verification:

Before fix:

winget upgrade
-> AppX registration failures

After fix:

winget upgrade

Successfully enumerates available upgrades.

Final working SDDL:

O:S-1-5-21-...-1001
G:S-1-5-21-...-513
D:AI
(A;OICIID;KA;;;USER)
(A;OICIID;KA;;;SY)
(A;OICIID;KA;;;BA)
(A;OICIID;KR;;;RC)
(A;OICIID;KR;;;AC)
(A;OICIID;KR;;;CapabilitySID)

This may affect users where the HKCU\Software\Classes\ActivatableClasses\Package ACL was modified incorrectly.

Possible improvement:
WinGet/AppX registration errors could detect this ACL condition and provide a more meaningful diagnostic message.

I hope this helps with investigation.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the failure with winget upgrade under a normal user and compare it with elevated execution. Review the AppX registration error path and the reported ACL condition under HKCU\Software\Classes\ActivatableClasses\Package; done would be a meaningful diagnostic when this condition causes registration failure.

Written by the indexing model from the issue text.

Assessment

Domain
cli, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.