Page 2 of 2

Re: Problem with Custom HTTP

Posted: Fri 24 Mar 2023 2:47 pm
by freddie
Yes, that's correct. It shows two things: (a) There is a permanent redirect operating on your website to ensure all requests use https. (b) Making an https request from your Pi works, so there isn't an issue with your SSL certificates.

You mentioned that you experienced an error when setting your customHTTPseconds URL to use https. What was that error? I couldn't see it in the comments in this topic.

Re: Problem with Custom HTTP

Posted: Fri 24 Mar 2023 7:08 pm
by Shamy
freddie wrote: Fri 24 Mar 2023 2:47 pm You mentioned that you experienced an error when setting your customHTTPseconds URL to use https. What was that error? I couldn't see it in the comments in this topic.
Maybe I wrote it wrong - my English is not very good - which you can probably see ;)
The thing was that when I typed http or https it didn't change anything, it still didn't work properly. I saw information about SSL in the logs, so I changed from https to http, but that didn't work either. I hope I've made it clear now :)

Re: Problem with Custom HTTP

Posted: Fri 24 Mar 2023 7:37 pm
by freddie
I think it didn't change because of the redirect to https if you try to use http. I'm a bit puzzled now. @mcrossley I'm assuming mono uses system certs and doesn't have its own?

Re: Problem with Custom HTTP

Posted: Fri 24 Mar 2023 9:22 pm
by mcrossley
If like to see a log file with the custom URL set to use https and the resulting error.

Afaik mono uses the system certs - that's why the old root cert fix for windy works. The error we have seen was an SSL error rather than certificate.

I checked the site out and it accepts all encryption protocols from the obsolete SSL (they really should be disabled on the server!) through to TLS1.3 so there should be no issue there.

Re: Problem with Custom HTTP

Posted: Fri 24 Mar 2023 11:29 pm
by ConligWX
what version of mono are you running? just curious.

Re: Problem with Custom HTTP

Posted: Sat 25 Mar 2023 5:43 am
by freddie
ConligWX wrote: Fri 24 Mar 2023 11:29 pm what version of mono are you running? just curious.
From the supplied log file:

Code: Select all

2023-03-23 13:27:17.447 Mono version: 6.12.0.182 (tarball Tue Jun 14 22:42:26 UTC 2022)

Re: Problem with Custom HTTP

Posted: Sat 25 Mar 2023 1:32 pm
by Shamy
Okay, I changed from http to https. No changes, here is the log:

Code: Select all

2023-03-25 14:29:32.491 ApplyData: Complete
2023-03-25 14:29:32.491 ProcessData: Complete
2023-03-25 14:29:43.520 CustomHttpSeconds[0]: Querying - https://www.pogodakrotoszyn.pl/ecowitt-mysql.php
2023-03-25 14:29:43.599 Realtime[201]: Start cycle
2023-03-25 14:29:43.600 Realtime[201]: Creating realtime.txt
2023-03-25 14:29:43.601 Realtime[201]: Creating realtime file - realtimegauges.txt
2023-03-25 14:29:43.665 CustomHttpSeconds: The SSL connection could not be established, see inner exception.
2023-03-25 14:29:46.696 Realtime[201]: End cycle

Re: Problem with Custom HTTP

Posted: Sat 25 Mar 2023 11:41 pm
by ConligWX
mcrossley wrote: Fri 24 Mar 2023 9:22 pm
Afaik mono uses the system certs - that's why the old root cert fix for windy works. The error we have seen was an SSL error rather than certificate.
from mono it states:
Starting with Mono 3.12.0 a new tool called cert-sync is included which syncs Mono’s certificate store with the system certificate store. It should run automatically when you install the official Mono packages. Make sure the ca-certificates-mono package is installed.
perhaps Shamy's OS is missing the ca-certificates-mono package?

Re: Problem with Custom HTTP

Posted: Mon 27 Mar 2023 2:37 pm
by freddie
Shamy wrote: Sat 25 Mar 2023 1:32 pm Okay, I changed from http to https. No changes, here is the log:

Code: Select all

2023-03-25 14:29:32.491 ApplyData: Complete
2023-03-25 14:29:32.491 ProcessData: Complete
2023-03-25 14:29:43.520 CustomHttpSeconds[0]: Querying - https://www.pogodakrotoszyn.pl/ecowitt-mysql.php
2023-03-25 14:29:43.599 Realtime[201]: Start cycle
2023-03-25 14:29:43.600 Realtime[201]: Creating realtime.txt
2023-03-25 14:29:43.601 Realtime[201]: Creating realtime file - realtimegauges.txt
2023-03-25 14:29:43.665 CustomHttpSeconds: The SSL connection could not be established, see inner exception.
2023-03-25 14:29:46.696 Realtime[201]: End cycle
Do you have debug logging and data logging switched on?