Skip to content

When the dev-certs rotate, the exported PEM files for the SPA templates are not #46134

Open
@Tragetaschen

Description

@Tragetaschen

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

After a year, my dev-certs were rotated automatically - great.

However, the PEM files exported by aspnetcore-https.js for the SPA proxy are not updated. The script only checks whether the files exist, not if they actually contain the valid/current dev-cert. This resulted in an "untrusted connection" message in the Browser and it was rather annoying to figure out what went wrong.

Expected Behavior

The SPA template infrastructure should pick up that the dev-certs rotated and rerun the export

Steps To Reproduce

  • Rotate the dev-certs
  • Notice that the exported *.pem and *.key files are not updated

Exceptions (if any)

No response

.NET Version

7.0.102

Anything else?

To fix this, I manually removed the pem and the key files from the …appdata/Roaming/ASP.NET/https/ folder, which were then regenerated with the new certificate on the next startup.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-ui-renderingIncludes: MVC Views/Pages, Razor Views/PagesbugThis issue describes a behavior which is not expected - a bug.feature-spagood first issueGood for newcomers.help candidateIndicates that the issues may be a good fit for community to help with. Requires work from eng. team

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions