Allow passing an external authentication token override instead of using the builtin authentication handler
Les mainteneurs répondent en général sous 2 jours
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Accessibilité débutants
- 52/100
- Type d'issue
- Fonctionnalité
- Clarté
- Plutôt claire
- Activité
- Active
- Stack technique
- cpp
- Domaine
- api, authentication, cli
Piste de recherche
Commencez par AuthenticationAccount dans src/Microsoft.Management.Deployment/PackageManager.idl, puis suivez les options de la CLI analogues à --authentication-mode et --authentication-account. Suivez AuthenticationArguments jusqu’à AppInstaller::Authenticator et Authentication::AuthenticateForToken. Le travail est terminé lorsque le token externe peut être fourni via la CLI et la COM API, et qu’il est renvoyé par AuthenticateForToken lorsqu’il est présent.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
Relevant area(s)
COM API, WinGet CLI, PowerShell Module
Description of the new feature / enhancement
Summary
Add a command line argument as well as COM API support to supply an external authentication token, overriding the default authentication flow.
Background
The builtin authentication support (AppInstaller::Authentication) currently either supports no authentication or the use of Entra ID authentication via WebAuthenticationCoreManager. This has some shortcomings with unattended deployments:
WebAuthenticationCoreManagerhas bugs involving running programs as different users (#6186). This can be worked around when usingWebAuthenticationCoreManagerdirectly by delegating the user authentication flow to a helper process, but this is not possible when using WinGet, as its API does not allow passing in an external token but requires using the builtinWebAuthenticationCoreManagerflow.- There is no way to make system-wide unattended installations work without user interaction, as WinGet does not support requesting a machine token. This would also require the device to have a corresponding Entra ID principal via a device attach / join.
--authentication-mode silentis not useful for unattended deployments as it does not guarantee success - after all, the user must have authenticated themselves at some point. It also requires WinGet to run as the user, not as LocalSystem, which isn't possible with users not having administrator access and the installer requiring elevation.
In our case, a user should be able to order software and have it installed without further interaction via our client management solution, where the software resides in a private WinGet repository protected from unauthorized access via Entra ID authentication - we don't need to authenticate as the user, we need to authenticate as an Entra ID principal we can grant access to, but WinGet doesn't allow for external authentication flows.
Proposed technical implementation details
- Extend
AuthenticationAccountwithString AuthenticationToken;. - Extend the CLI interface with
--authentication-tokenakin to--authentication-modeand--authentication-account. - Pass both values to
AppInstaller::Authenticatoras part of theAuthenticationArguments. - Adjust
AppInstaller::Authentication::AuthenticateForTokento return the token from the authentication arguments, if present.
- Langage dominant
- C++
- Étoiles
- 26.6k
- Forks
- 1.8k
- Merge moyen
- 3 j 10 h
- PR mergées (30 j)
- 41
Préparer son environnement
- Aucun Dockerfile ni fichier Docker Compose
- Propose un modèle de pull request
- Lire le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de microsoft/winget-cli
-
Issue-Docs Needs-Triage
Difficulté 2/5 1-3 heures Accessibilité débutants 70/100
microsoft/winget-cli#6692 ·
Les mainteneurs répondent en général sous 2 jours
-
Issue-Docs Possible-Duplicate
Difficulté 2/5 1-3 heures Accessibilité débutants 76/100
microsoft/winget-cli#6493 · 1 commentaire ·
Les mainteneurs répondent en général sous 2 jours
-
WinGetSourceCreator: PackWithMappingFile should verify makeappx.exe exists before invoking itOuverteIssue-Feature
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
microsoft/winget-cli#6427 ·
Les mainteneurs répondent en général sous 2 jours
-
Issue-Docs msstore
Difficulté 2/5 1-3 heures Accessibilité débutants 64/100
microsoft/winget-cli#6331 · 1 commentaire ·
Les mainteneurs répondent en général sous 2 jours
-
Command-Source Issue-Bug
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
microsoft/winget-cli#6148 ·
Les mainteneurs répondent en général sous 2 jours
Toutes les issues de microsoft/winget-cli
Issues similaires
-
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
stratum-mining/sv2-tp#167 ·
Les mainteneurs répondent en général sous 1 jour
-
Sign up button opens the Sign in page instead of the Sign up page for Enterprise edition serversOuverteauth bug ui/ux
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
MerginMaps/mobile#4795 ·
Les mainteneurs répondent en général sous 2 jours
-
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
HarperFast/rocksdb-js#1118 ·
Les mainteneurs répondent en général sous 1 jour
-
bug triage
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
Les mainteneurs répondent en général sous 1 jour
-
26.04 bug dark-mode Easy Hack impress symptom: visual
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
CollaboraOnline/online#16421 · 1 commentaire ·