打开我的页面时,出现403错误:您无权查看此页面。尝试在项目中实施https后发生了这种情况。
当我将其更改为http:// 时,我首先有了一个使用URL(http:// )的自托管网页,我的问题开始了。
我在IIS中制作了一个自签名证书。
使用了以下命令:
netsh http add urlacl url=https://+:443/ user=Everyone
netsh http add sslcert ipport=0.0.0.0:443 certhash=247951f42efcc102cddef79e9f4b2e8830f9b2d0 appid={12346978-db90-4b66-8b01-88f7af2e36bf}
发出以下命令时,我得到以下结果:
certutil -store MY
Serial Number: 5c1b0c44d38e549d4619924cf97868f6
Issuer: CN=DJA110.dejaeger.local
NotBefore: 07/08/2019 14:50
NotAfter: 07/08/2020 02:00
Subject: CN=DJA110.dejaeger.local
Signature matches Public Key
Root Certificate: Subject matches Issuer
Cert Hash(sha1): 247951f42efcc102cddef79e9f4b2e8830f9b2d0
Key Container = 5cc7567c-6f6c-4048-9c13-1f679b4687da
Unique container name: b7e741ae2b19f4ab4f2fab2bf9c5a764_23ebc36b-cd98-47b1-ab6d-9dfe37445a90
Provider = Microsoft RSA SChannel Cryptographic Provider
Encryption test passed
CertUtil: -store command completed successfully.
netsh http show urlacl
Reserved URL : https://+:443/
User: \Everyone
Listen: Yes
Delegate: No
SDDL: D:(A;;GX;;;WD)
netsh http show sslcert
IP:port : 0.0.0.0:443
Certificate Hash : 247951f42efcc102cddef79e9f4b2e8830f9b2d0
Application ID : {12346978-db90-4b66-8b01-88f7af2e36bf}
Certificate Store Name : (null)
Verify Client Certificate Revocation : Enabled
Verify Revocation Using Cached Client Certificate Only : Disabled
Usage Check : Enabled
Revocation Freshness Time : 0
URL Retrieval Timeout : 0
Ctl Identifier : (null)
Ctl Store Name : (null)
DS Mapper Usage : Disabled
Negotiate Client Certificate : Disabled
Reject Connections : Disabled
Disable HTTP2 : Not Set
Disable QUIC : Not Set
Disable TLS1.3 : Not Set
Disable OCSP Stapling : Not Set
这就是我叫我的创业公司的地方。
public void StartWebHost()
{
endpoint = "https://*";
WebApp.Start<Startup>(endpoint);
}
这是创业公司本身
public void Configuration(IAppBuilder app)
{
try
{
app.UseCors(CorsOptions.AllowAll);
app.MapSignalR(new HubConfiguration
{
EnableJavaScriptProxies = true,
EnableJSONP = true,
EnableDetailedErrors = true
});
string proTightWebPath = "E:\\Projecten\\P-DJA-100010R-01-ProTight\\ProGuidance.Web";
app.UseFileServer(new FileServerOptions
{
RequestPath = PathString.Empty,
FileSystem = new PhysicalFileSystem(proTightWebPath)
});
}
catch (Exception ex) {
};
}
那么我有什么想念的吗?