Skip to content

Conversation

akoeplinger
Copy link
Member

@akoeplinger akoeplinger commented Jul 11, 2025

#116695

Export the certificate generated by dotnet dev-certs and import it via PowerShell rather than creating our own self-signed cert.

@akoeplinger akoeplinger changed the title Try to fix developer certificate Fix installing developer certificate in wasm Helix runs Jul 11, 2025
@akoeplinger akoeplinger marked this pull request as ready for review July 11, 2025 15:31
@Copilot Copilot AI review requested due to automatic review settings July 11, 2025 15:31
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the Helix helper project to fix developer certificate installation in WASM Helix runs on Windows by exporting and importing a PFX instead of generating a new cert via PowerShell, and refreshes the related comment.

  • Changed WindowsShell branch to use dotnet dev-certs https --export-path and Import-PfxCertificate into LocalMachine\Root.
  • Updated the explanatory comment to mention the --trust behavior.
Comments suppressed due to low confidence (1)

src/libraries/sendtohelixhelp.proj:224

  • Hard-coding a plaintext PLACEHOLDER password and using percent-encoded semicolons can leak secrets and hinder readability. Consider sourcing the password from a secure MSBuild property or environment variable, and use standard semicolons for command separation.
      <HelixCommand Condition="'$(InstallDevCerts)' == 'true' and '$(WindowsShell)' == 'true'">$(HelixCommand) powershell -command &quot;dotnet dev-certs https --export-path devcerts.pfx --password PLACEHOLDER %3B $pw = ConvertTo-SecureString PLACEHOLDER -AsPlainText -Force %3B Import-PfxCertificate -FilePath devcerts.pfx -Password $pw -CertStoreLocation Cert:\LocalMachine\Root &quot; &amp;&amp; </HelixCommand>

@lewing lewing merged commit f1867b7 into dotnet:main Jul 11, 2025
96 of 98 checks passed
@akoeplinger akoeplinger deleted the fix-cert branch July 11, 2025 18:18
@github-actions github-actions bot locked and limited conversation to collaborators Aug 11, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants