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

[Feature Request] Support reading certificate from Windows certificate store #685

Open
jiasli opened this issue Apr 8, 2024 · 1 comment

Comments

@jiasli
Copy link
Contributor

jiasli commented Apr 8, 2024

MSAL client type

Confidential

Problem Statement

Currently, authenticating a service principal with certificate only supports plain-text certificate string as private_key:

:param client_credential:
For :class:`PublicClientApplication`, you use `None` here.
For :class:`ConfidentialClientApplication`,
it can be a string containing client secret,
or an X509 certificate container in this form::
{
"private_key": "...-----BEGIN PRIVATE KEY-----... in PEM format",
"thumbprint": "A1B2C3D4E5F6...",
"public_certificate": "...-----BEGIN CERTIFICATE-----... (Optional. See below.)",
"passphrase": "Passphrase if the private_key is encrypted (Optional. Added in version 1.6.0)",
}

Proposed solution

It would be helpful to allow reading certificate from Windows certificate store.

@rayluo
Copy link
Collaborator

rayluo commented Apr 8, 2024

We would need to investigate how, and what kind of extra dependency it would bring (pywin32?).

FWIW, the managed identity support is coming. And I believe the path forward would be stay away from secret and even cert, and use federated by managed identity instead. See the last paragraph of the client_credential parameter for details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants