Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

ClientCertificates does not accept an environment variable #14109

Open
stevestock opened this issue Feb 16, 2025 · 1 comment
Open

ClientCertificates does not accept an environment variable #14109

stevestock opened this issue Feb 16, 2025 · 1 comment
Labels
Area:Settings NuGet.Config and related issues Functionality:Signing Priority:3 Issues under consideration. With enough upvotes, will be reconsidered to be added to the backlog. Type:Feature

Comments

@stevestock
Copy link

NuGet Product(s) Involved

NuGet.exe

The Elevator Pitch

This ClientCertificates feature does not take an environment variable

example:

<configuration>
    ...
    <packageSources>
        <add key="Contoso" value="https://contoso.com/packages/" />
    </packageSources>
    ...
    <clientCertificates>	
        <storeCert packageSource="Contoso"
                   storeLocation="currentUser"
                   storeName="my"
                   findBy="thumbprint" 
                   findValue="%THUMBPRINT_VARIABLE%" />
    </clientCertificates>
...
</configuration>

currently the findValue only works if directly set to the thumbprint string

Additional Context and Details

No response

@nkolev92
Copy link
Member

nkolev92 commented Feb 19, 2025

Environment variable transforms are not supported in every setting. https://github.com/NuGet/NuGet.Client/blob/72ab0e05562bc8e19db1ce0c2630a80e0bd3ca28/src/NuGet.Core/NuGet.Configuration/Settings/Settings.cs#L670-L677

They're only supported in add and source items, so this would is a new feature request.
The docs might need to be improved to call that out though.

@jeffkl jeffkl added the Priority:3 Issues under consideration. With enough upvotes, will be reconsidered to be added to the backlog. label Feb 20, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Area:Settings NuGet.Config and related issues Functionality:Signing Priority:3 Issues under consideration. With enough upvotes, will be reconsidered to be added to the backlog. Type:Feature
Projects
None yet
Development

No branches or pull requests

3 participants