# Storefront Installation Error

**URL:** <https://www.virtocommerce.org/t/storefront-installation-error/585>\
**Category:** installation\
**Tags:** storefront\
**Created:** [May 22, 2023, 5:37am UTC](https://www.virtocommerce.org/t/storefront-installation-error/585 "2023-05-22T05:37:37Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![mark](https://yyz2.discourse-cdn.com/flex032/user_avatar/www.virtocommerce.org/mark/32/1378_2.png) [@mark](https://www.virtocommerce.org/u/mark)\
**Post date:** [May 22, 2023, 5:37am UTC](https://www.virtocommerce.org/t/storefront-installation-error/585/1 "2023-05-22T05:37:37Z")

</div>

Hi,

I’m trying to install Virtocommerce & Storefront on my Ubuntu machine. I followed the quick start guide provided at QuickStart guide and was able to successfully install the backend.

Next, I installed the storefront by following the guide at getting-started/connect-storefront-to-platform-v3/.  
I launched the frontend using the command “dotnet VirtoCommerce.Storefront.dll --urls=[http://localhost:5002](http://localhost:5002)”. However, when I tried to access the storefront in my browser at [http://localhost:5002](http://localhost:5002), I received an HTTP ERROR 500 message that said  
“This page isn’t working.  
localhost is currently unable to handle this request.”

Please advise how to fix the error.

_Here are some errors:-_  
**fail:** Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware[3]  
An exception was thrown attempting to execute the error handler.  
System.NullReferenceException: Object reference not set to an instance of an object.

**fail:** Microsoft.AspNetCore.Server.Kestrel[13]  
Connection id “0HMQPRA7MITJ1”, Request id “0HMQPRA7MITJ1:00000002”: An unhandled exception was thrown by the application.  
System.Net.Http.HttpRequestException: Connection refused (localhost:10645)  
—\> System.Net.Sockets.SocketException (111): Connection refused

---

<div class="post-metadata">

**Author:** ![OlegoO](https://yyz2.discourse-cdn.com/flex032/user_avatar/www.virtocommerce.org/olegoo/32/27_2.png) [@OlegoO](https://www.virtocommerce.org/u/OlegoO)\
**Post date:** [May 22, 2023, 7:29am UTC](https://www.virtocommerce.org/t/storefront-installation-error/585/2 "2023-05-22T07:29:54Z")

</div>

> [@mark](#):
>
> ystem.Net.Http.HttpRequestException: Connection refused (localhost:10645)  
> —\> System.Net.Sockets.SocketException (111): Connection refused

Could you check what’s **localhost:10645**? Is it accessible? Is it the admin backend?

---

<div class="post-metadata">

**Author:** ![mark](https://yyz2.discourse-cdn.com/flex032/user_avatar/www.virtocommerce.org/mark/32/1378_2.png) [@mark](https://www.virtocommerce.org/u/mark)\
**Post date:** [May 23, 2023, 5:54am UTC](https://www.virtocommerce.org/t/storefront-installation-error/585/4 "2023-05-23T05:54:18Z")

</div>

> [@mark](#):
>
> The backend is running at localhost:5001 so i changed it in storefront appsettings.json Endpoint section.  
> I ran the storefront after port change, still receiving “HTTP ERROR 500” error
> 
> _ **Here is error log** _
> 
> **fail:** Microsoft.AspNetCore.Server.Kestrel[13]  
> Connection id “0HMQQMT5IRD2M”, Request id “0HMQQMT5IRD2M:00000001”: An unhandled exception was thrown by the application.  
> System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.

The backend is running at localhost:5001 so i changed it in storefront appsettings.json Endpoint section.  
I ran the storefront after port change, still receiving “HTTP ERROR 500” error

_ **Here is error log** _

**fail:** Microsoft.AspNetCore.Server.Kestrel[13]  
Connection id “0HMQQMT5IRD2M”, Request id “0HMQQMT5IRD2M:00000001”: An unhandled exception was thrown by the application.  
System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.  
**—\> System.Security.Authentication.AuthenticationException: The remote certificate is invalid because of errors in the certificate chain: PartialChain**  
at System.Net.Security.SslStream.SendAuthResetSignal(ProtocolToken message, ExceptionDispatchInfo exception)  
at System.Net.Security.SslStream.CompleteHandshake(SslAuthenticationOptions sslAuthenticationOptions)

**fail:** Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware[3]  
An exception was thrown attempting to execute the error handler.  
System.NullReferenceException: Object reference not set to an instance of an object.  
at VirtoCommerce.Storefront.Domain.Security.AnonymousUserForStoreAuthorizationHandler.HandleRequirementAsync(AuthorizationHandlerContext context, AnonymousUserForStoreAuthorizationRequirement requirement) in /home/runner/work/vc-storefront/vc-storefront/VirtoCommerce.Storefront/Domain/Security/AnonymousUserForStoreAuthorizationRequirement.cs:line 25

---

<div class="post-metadata">

**Author:** ![OlegoO](https://yyz2.discourse-cdn.com/flex032/user_avatar/www.virtocommerce.org/olegoo/32/27_2.png) [@OlegoO](https://www.virtocommerce.org/u/OlegoO)\
**Post date:** [May 24, 2023, 8:22am UTC](https://www.virtocommerce.org/t/storefront-installation-error/585/5 "2023-05-24T08:22:59Z")

</div>

> [@mark](#):
>
> System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.  
> **—\> System.Security.Authentication.AuthenticationException: The remote certificate is invalid because of errors in the certificate chain: PartialChain**

Please review that dev certificate has been installed and trusted. To trust the certificate, perform the one-time step to run the dotnet dev-certs tool:

```auto
dotnet dev-certs https --trust

```

for more information visit this [link](https://learn.microsoft.com/en-us/aspnet/core/security/enforcing-ssl?view=aspnetcore-6.0&tabs=visual-studio#trust-the-aspnet-core-https-development-certificate-on-windows-and-macos)

---

<div class="post-metadata">

**Author:** ![mark](https://yyz2.discourse-cdn.com/flex032/user_avatar/www.virtocommerce.org/mark/32/1378_2.png) [@mark](https://www.virtocommerce.org/u/mark)\
**Post date:** [May 25, 2023, 10:36am UTC](https://www.virtocommerce.org/t/storefront-installation-error/585/6 "2023-05-25T10:36:59Z")

</div>

Yes i have used following command _dotnet dev-certs https --clean_ & _dotnet dev-certs https --trust_ installed dev certificate

- Confirmed the backend runs fine at [https://localhost:5001](https://localhost:5001)
- I have tested this on both Windows and Ubuntu platforms, following the QuickStart steps, but I’m still receiving the same “HTTP ERROR 500” error.
- Is there a way to temporarily disable SSL certificate authentication for the storefront while I troubleshoot this error?

System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.  
**—\> System.Security.Authentication.AuthenticationException: The remote certificate is invalid because of errors in the certificate chain: PartialChain**

---

<div class="post-metadata">

**Author:** ![OlegoO](https://yyz2.discourse-cdn.com/flex032/user_avatar/www.virtocommerce.org/olegoo/32/27_2.png) [@OlegoO](https://www.virtocommerce.org/u/OlegoO)\
**Post date:** [May 26, 2023, 8:07am UTC](https://www.virtocommerce.org/t/storefront-installation-error/585/7 "2023-05-26T08:07:56Z")

</div>

> [@mark](#):
>
> System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.  
> **—\> System.Security.Authentication.AuthenticationException: The remote certificate is invalid because of errors in the certificate chain: PartialChain**

In deed, you need to resolve certificate error or switch to HTTP mode. Here some links from Google, I hope it helps you:  
[Solved: Re: Errors in the certificate chain (PostgreSQL) - Google Cloud Community](https://www.googlecloudcommunity.com/gc/Databases/Errors-in-the-certificate-chain-PostgreSQL/m-p/483290)  
[c# - The SSL connection could not be established - Stack Overflow](https://stackoverflow.com/questions/52939211/the-ssl-connection-could-not-be-established)  
[The SSL connection could not be established, see inner exception - Microsoft Q&A](https://learn.microsoft.com/en-us/answers/questions/708185/the-ssl-connection-could-not-be-established-see-in)
