关于.NET6后端程序(api)部署ssl证书的问题(https) 解决ing

 

https://blog.csdn.net/weixin_45507349/article/details/132448834

var builder = WebApplication.CreateBuilder(args);

builder.WebHost.UseKestrel(options =>
{
options.Listen(IPAddress.Loopback, 5000);
options.Listen(IPAddress.Loopback, 5001,
listenOptions =>
{
listenOptions.UseHttps("certificate.pfx","topsecret");
});
});

posted @ 2024-12-10 09:27  China Soft  阅读(3)  评论(0编辑  收藏  举报