Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the default location for certificates created using "dotnet dev-certs https"

Following dot net core CLI command allows one to create a certificate.

dotnet dev-certs https

This command has an optional parameter for specifying an export path. Does anyone know where the certificate goes if this path is not specified?

It seems like the help output of the command: dotnet dev-certs --help does not seem to contain this information and I have not been able to locate much details on this at other sources either.

like image 347
shivesh suman Avatar asked Oct 02 '18 18:10

shivesh suman


People also ask

What does dotnet dev certs HTTPS do?

The dotnet dev-certs command manages a self-signed certificate to enable HTTPS use in local web app development. Its main functions are: Generating a certificate for use with HTTPS endpoints during development. Trusting the generated certificate on the local machine.

What is configure for HTTPS Visual Studio?

It allows the web server to communicate with the client over secure HTTPS connections, never on insecure HTTP protocol. It helps to reject insecure connections in the first place. public void Configure(IApplicationBuilder app,, IHostingEnvironment env)

How can I create a self-signed certificate using C #?

2 you can create self-signed certs using System. Security. Cryptography. X509Certificates.

How do I disable HTTPS in .NET core?

If we want to disable HTTP for the asp.net code, we just need to remove lines 11 to 13 and the same for HTTPS, if we want to disable HTTPS, just remove lines 14 to 16 and comment out app. UseHttpsRedirection(); in Program. cs. If we want to change the port number, we just change in the Http and Https there according.


2 Answers

Looks like by default it goes into the current user's (logged on user's) personal certificate store:

Screenshot

like image 58
shivesh suman Avatar answered Sep 18 '22 05:09

shivesh suman


On linux it defaults to ~/.dotnet/corefx/cryptography/x509stores/my/ (using dotnet 5)

like image 30
quasar Avatar answered Sep 19 '22 05:09

quasar