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

Fix for attempted use of capability API before it was introduced #4620

Merged
merged 1 commit into from
Jul 8, 2024

Conversation

JohnMcPMS
Copy link
Member

@JohnMcPMS JohnMcPMS commented Jul 8, 2024

Issue

The Windows::Security::Authorization::AppCapabilityAccess::AppCapability class was not added until the release after the current minimum supported version. This causes a failure when using the COM API on RS5.

Change

Check for the existence of Windows::Security::Authorization::AppCapabilityAccess::AppCapability, and if it is not present, simply force the caller to be at least medium integrity level.

Validation

Successful from both in-proc and OOP cases on an RS5 VM.

Microsoft Reviewers: Open in CodeFlow

@JohnMcPMS JohnMcPMS requested a review from a team as a code owner July 8, 2024 18:28
@mominshaikhdevs
Copy link

mominshaikhdevs commented Jul 8, 2024

Check for the existence of Windows::Security::Authorization::AppCapabilityAccess::AppCapability, and if it is not present, simply force the caller to be medium integrity level.

have you considered running as admin scenarios? (may want to run as admin scenarios)?

@JohnMcPMS
Copy link
Member Author

Check for the existence of Windows::Security::Authorization::AppCapabilityAccess::AppCapability, and if it is not present, simply force the caller to be medium integrity level.

have you considered running as admin scenarios? (may want to run as admin scenarios)?

Updated original PR comment to be "at least medium integrity level".

@JohnMcPMS
Copy link
Member Author

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@JohnMcPMS JohnMcPMS merged commit 43425fe into microsoft:master Jul 8, 2024
7 of 8 checks passed
@JohnMcPMS JohnMcPMS deleted the cap-check-fix branch July 8, 2024 21:53
JohnMcPMS added a commit to JohnMcPMS/winget-cli that referenced this pull request Jul 8, 2024
…rosoft#4620)

## Change
Check for the existence of
`Windows::Security::Authorization::AppCapabilityAccess::AppCapability`,
and if it is not present, simply force the caller to be at least medium
integrity level.
JohnMcPMS added a commit that referenced this pull request Jul 8, 2024
## Change
Check for the existence of
`Windows::Security::Authorization::AppCapabilityAccess::AppCapability`,
and if it is not present, simply force the caller to be at least medium
integrity level.

Cherry-pick of #4620
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants