Some content on this page is not encrypted - after setting up SSL

Friday, April 26, 2024 3:43:03 PM
  • Posted: Thursday, November 29, 2018 2:04 PM
  • 55
I fixed this problem before on a previous install, but forgot what I did.  Trying to replicate the old setup I have been unable to solve this issue.
Occurs on the homepage.  If I recall it was an nginx configuration.  


Ubuntu 18.04 setup with nginx and dotnet core 2.1
- latest pull on GrandNode

0
  • Posted: Thursday, November 29, 2018 2:09 PM
  • 55

$ grep -r "Forwarded" .

./App_Data/appsettings.json:    "UseHttpXForwardedProto": true,
./App_Data/appsettings.json:    "ForwardedHttpHeader": "",
./App_Data/appsettings.json:    "UseForwardedHeaders": true   <--- recently set this for testing purposed


----------------
sites-available Location directive:

    proxy_pass http://localhost:5000;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection keep-alive;
    proxy_set_header Host $host;
    proxy_set_header X-Forwarded-Proto $scheme;
    proxy_cache_bypass $http_upgrade;

-------------------

Admin > Configuration > Store
* SSL enabled with the address set to the https://mydomain.com
0
  • Posted: Thursday, November 29, 2018 2:39 PM
  • 55
Will run through:
https://docs.microsoft.com/en-us/aspnet/core/host-and-deploy/linux-nginx?view=aspnetcore-2.1&tabs=aspnetcore2x

and report back if anything changes.
0
  • Posted: Friday, November 30, 2018 6:59 AM
  • 953
Hello,

Just set the "UseHttpXForwardedProto" to false. From the GrandNode 4.30 it's enough to leave enabled only UseForwardedHeaders. And it should work.

In the default.conf file did you configure the SSL?
Best regards,
Patryk

GrandNode Team
0
  • Posted: Friday, November 30, 2018 12:42 PM
  • 55
Appreciate the reply.  Appears to be working by setting the Proto forwarding in appsettings.json to false and ForwardedHeaders to true.  
- To answer your question.  Yes, all of the SSL settings are configured.

Aside: I would move this topic to the Installing and Configuring subsection, if I could.
0
  • Posted: Wednesday, April 1, 2020 12:41 PM
  • 137
With HA PROXY, the good config for app settings.json is :

{
  "Hosting": {
    //Set to "true" the settings below if your hosting uses a load balancer. It'll be used to determine whether the current request is HTTPS
    "UseHttpClusterHttps": false,
    "UseHttpXForwardedProto": true,

    //Use the setting below if your hosting doesn't use "X-FORWARDED-FOR" header to determine IP address.
    //In some cases server use other HTTP header. You can specify a custom HTTP header here. For example, CF-Connecting-IP, X-FORWARDED-PROTO, etc
    "ForwardedHttpHeader": "",

    //Use a reverse proxy server - more information you can find at: https://docs.microsoft.com/en-US/aspnet/core/host-and-deploy/linux-nginx?view=aspnetcore-2.1
    "UseForwardedHeaders": true
  },

Without this, I have bug in checkout and cannot pass to payment step. GrandNode return to cart page.
0
  • Posted: Wednesday, April 1, 2020 5:04 PM
  • Team
  • 151
Hi,
Please go to the Admin -> System -> System information and check value for "Http scheme is https" - is it True?

Regards
Krzysztof
0
back to top
Filters