Page 2 of 4

Re: Website "now safe"

Posted: Fri 19 Apr 2024 10:50 pm
by PaulMy
With a huge Thank You to forum member KarlS I am now in the https world for www.komokaweather.com using Certbot
From my Edge and Google it shows as secure but Firefox does not.

Anyone not able to load https://www.komokaweather.com ?

Enjoy,
Paul

Re: Website "Not safe"

Posted: Fri 19 Apr 2024 11:19 pm
by ConligWX
only issue I have is your Saratoga Template not fully loading for me.

https://www.komokaweather.com/komokawea ... /index.php

the main dashboard isn't loading at all. just the menu on the left hand side and the header.


Screenshot 2024-04-20 002050.png

Re: Website "now safe"

Posted: Sat 20 Apr 2024 1:28 am
by HansR
PaulMy wrote: Fri 19 Apr 2024 10:50 pm Anyone not able to load https://www.komokaweather.com ?
Hi Paul,

I am sorry, but still can't see your site, it says:
This site can't give a secure connection
www.komokaweather.com has sent an illegal reaction
Carry out windows network inspection
ERR_SSL_PROTOCOL_ERROR
When carrying out the network inspection it says it will be stopping the MSDT support.
Sorry the error is in Dutch, maybe I should change the interface language to English...

Besides the above, my malware detector (Malwarebytes Browser Guard) still blocks the site which is probably a database detection. I asked their support how to remove the false positive from that system. Maybe they can't as it is an shared server.
    Schermafbeelding 2024-04-20 031354.png

    Re: Website "Not safe"

    Posted: Sat 20 Apr 2024 1:29 am
    by saratogaWX
    Hmmm.. running https://www.komokaweather.com/komokawea ... w=versions shows a few updates are not present.

    Your site is running PHP 8.0.30

    Based on where the index.php blows up (and also wxforecast.php too), the ec-forecast.php is having a fatal error issue.
    Check the error_log for the site to see what is going on. Also, you can add to ec-forecast.php (after the opening <?php line)

    Code: Select all

    error_reporting(E_ALL);
    ini_set('display_errors','1');
    
    so we can observe what's happening remotely

    Re: Website "Now safe"

    Posted: Sat 20 Apr 2024 1:35 am
    by PaulMy
    Yes, it had been working ok after I did some script updates and then it stopped. I haven't found the cause yet.

    Enjoy,
    Paul

    Re: Website "Not safe"

    Posted: Sat 20 Apr 2024 2:07 am
    by saratogaWX
    Do add the change I suggested to ec-forecast.php so the error(s) will be displayed.

    Re: Website "Now safe"

    Posted: Sat 20 Apr 2024 2:46 am
    by PaulMy
    Thanks Ken.
    I've updated the needed scripts, and also added your mentioned code at the top of ec-forecast.php and the error now show on the page load www.komokaweather.com/komokaweather-ca
    and the error on webhost is

    Code: Select all

    [19-Apr-2024 22:39:49 America/Toronto] PHP Warning:  Attempt to read property "currentConditions" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 695
    [19-Apr-2024 22:39:49 America/Toronto] PHP Warning:  Attempt to read property "forecastGroup" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 825
    [19-Apr-2024 22:39:49 America/Toronto] PHP Warning:  Attempt to read property "yesterdayConditions" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 834
    [19-Apr-2024 22:39:49 America/Toronto] PHP Warning:  Attempt to read property "riseSet" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 845
    [19-Apr-2024 22:39:49 America/Toronto] PHP Warning:  Attempt to read property "forecastGroup" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1113
    [19-Apr-2024 22:39:49 America/Toronto] PHP Warning:  Attempt to read property "forecast" on null in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1113
    [19-Apr-2024 22:39:49 America/Toronto] PHP Warning:  foreach() argument must be of type array|object, null given in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1113
    [19-Apr-2024 22:39:49 America/Toronto] PHP Warning:  Undefined variable $forecasttext in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1199
    [19-Apr-2024 22:39:49 America/Toronto] PHP Fatal error:  Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php:1199
    Stack trace:
    #0 /home/psoykkrhjuz3/public_html/komokaweather-ca/index.php(82): include_once()
    #1 {main}
      thrown in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1199
    Unfortunately that is beyond me to understand what needs to be done.

    I found I started to do the updates last month and then didn't finish, and forgot where I left of.

    Enjoy,
    Paul

    Re: Website "Not safe"

    Posted: Sat 20 Apr 2024 3:27 am
    by saratogaWX
    I think the issue is in Settings.php where you have

    Code: Select all

    $SITE['ECforecasts'] = array(
     // Location|forecast-URL  (separated by | character)
    'Komoka (London Area), ON|http://weatheroffice.gc.ca/city/pages/on-137_metric_e.html', // added for local London, ON 
    'Markham, ON|http://weather.gc.ca/city/pages/on-85_metric_e.html', // Markham, ON
    'Toronto, ON|http://weather.gc.ca/city/pages/on-143_metric_e.html', // Toronto, ON
    'Toronto Island, ON|http://weather.gc.ca/city/pages/on-128_metric_e.html', // Toronto, ON
    'Pickering, ON|http://weather.gc.ca/city/pages/on-54_metric_e.html', // Pickering
    'Collingwood, ON|http://weather.gc.ca/city/pages/on-150_metric_e.html', // Collingwood, ON
    'St. Catharines, ON|http://weather.gc.ca/city/pages/on-107_metric_e.html', // St. Catharines, ON
    'Vancouver, BC|http://weather.gc.ca/city/pages/bc-74_metric_e.html',
    'Calgary, AB|http://weather.gc.ca/city/pages/ab-52_metric_e.html',
    'Regina, SK|http://weather.gc.ca/city/pages/sk-32_metric_e.html',
    'Winnipeg, MB|http://weather.gc.ca/city/pages/mb-38_metric_e.html',
    'Ottawa (Kanata - Orl�ans), ON|http://weather.gc.ca/city/pages/on-118_metric_e.html',
    'Montr�al, QC|http://weather.gc.ca/city/pages/qc-147_metric_e.html',
    'Happy Valley-Goose Bay, NL|http://weather.gc.ca/city/pages/nl-23_metric_e.html',
    'St. John\'s, NL|http://weather.gc.ca/city/pages/nl-24_metric_e.html',
    'Fredericton, NB|http://weather.gc.ca/city/pages/nb-29_metric_e.html',
    'Halifax, NS|http://weather.gc.ca/city/pages/ns-19_metric_e.html',
    'Charlottetown, PE|http://weather.gc.ca/city/pages/pe-5_metric_e.html',
    'Whitehorse, YT|http://weather.gc.ca/city/pages/yt-16_metric_e.html',
    'Yellowknife, NT|http://weather.gc.ca/city/pages/nt-24_metric_e.html',
    'Resolute, NU|http://weather.gc.ca/city/pages/nu-27_metric_e.html',
    'Iqaluit, NU|http://weather.gc.ca/city/pages/nu-21_metric_e.html',
    ); 
    
    The first one uses 'weatheroffice.gc.ca' and should use 'weather.gc.ca' in the URL. 'weatheroffice.gc.ca' has no DNS, so the script blows up with a null file returned. Make the change, then run wxforecast.php?cache=no to reload the cache. It should work after that.

    Re: Website "Not safe"

    Posted: Sat 20 Apr 2024 3:42 am
    by saratogaWX
    Also try changing ec-forecast.php from

    Code: Select all

    "https://dd.weather.gc.ca/citypage_weather/xml/$PROV/${Xfile}_$lang.xml",
    to

    Code: Select all

    "https://dd.weather.gc.ca/citypage_weather/xml/$PROV/{$Xfile}_$lang.xml",
    It may be your PHP doesn't like ${variable} notation any more..

    Re: Website "Not safe"

    Posted: Sat 20 Apr 2024 3:50 am
    by saratogaWX
    D'Oh.. I noticed you're running ec-forecast.php V5.03 - 16-Oct-2019 -- the current release is V5.06 - 18-May-2023 which has that last fix in it.

    Get the new script from https://saratoga-weather.org/wxtemplate ... p?sce=view and install it.

    Re: Website "Now safe"

    Posted: Sat 20 Apr 2024 4:18 am
    by PaulMy
    Hi Ken, and thanks for checking and recommendations.
    I made the earlier changes but still the errors. Then now also updated to latest ec-forecast.php and still errors on the site, and on webhost:

    Code: Select all

    [20-Apr-2024 00:05:16 America/Toronto] PHP Warning:  Attempt to read property "currentConditions" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 698
    [20-Apr-2024 00:05:16 America/Toronto] PHP Warning:  Attempt to read property "forecastGroup" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 828
    [20-Apr-2024 00:05:16 America/Toronto] PHP Warning:  Attempt to read property "yesterdayConditions" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 837
    [20-Apr-2024 00:05:16 America/Toronto] PHP Warning:  Attempt to read property "riseSet" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 848
    [20-Apr-2024 00:05:16 America/Toronto] PHP Warning:  Attempt to read property "forecastGroup" on bool in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1117
    [20-Apr-2024 00:05:16 America/Toronto] PHP Warning:  Attempt to read property "forecast" on null in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1117
    [20-Apr-2024 00:05:16 America/Toronto] PHP Warning:  foreach() argument must be of type array|object, null given in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1117
    [20-Apr-2024 00:05:16 America/Toronto] PHP Warning:  Undefined variable $forecasttext in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1203
    [20-Apr-2024 00:05:16 America/Toronto] PHP Fatal error:  Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php:1203
    Stack trace:
    #0 /home/psoykkrhjuz3/public_html/komokaweather-ca/index.php(82): include_once()
    #1 {main}
      thrown in /home/psoykkrhjuz3/public_html/komokaweather-ca/ec-forecast.php on line 1203
    
    I've also run /wxforecast.php?cache=no and still the same result.
    I see that /cache has about 259 files with some going back to 2017 and /cache/extremes over 120 files also going back to 2017. Can cache files be removed?

    It is getting late here and maybe I am getting confused with the ec-forecast and wxforecast updates so time to call it a night and look at it with a clear mind in the morning...

    Enjoy,
    Paul

    Re: Website "Not safe"

    Posted: Sat 20 Apr 2024 4:52 am
    by saratogaWX
    Digging deeper.. ran check-fetch-times.php and saw:
    --checking EC Forecast URL --
    Using Settings.php $SITE['fcsturlEC'] entry for test.
    URL: https://weather.gc.ca/city/pages/on-137_metric_e.html
    Cache: ./cache/ec-forecast-en.txt
    curl fetching 'https://weather.gc.ca/city/pages/on-137_metric_e.html'
    curl Error: Failed to connect to weather.gc.ca port 443 after 3001 ms: Couldn't connect to server
    HTTP stats: RC=0 dest= port=0 (from sce=)
    Times: dns=0.000 conn=0.000 pxfer=0.000 get=3.002 total=3.002 secs
    so, the root cause seems to be your webserver can't connect to the EC site.. that's a job for the hoster's tech support to solve.

    BTW.. it's also good that you corrected the Settings.php and updated the ec-forecast.php to the current release. Also, the cache file for your default forecast (https://www.komokaweather.com/komokawea ... 326-en.txt) has contents that haven't been updated since Saturday February 03, 2024 at 10:03 EST -- maybe your website IP is on the EC's 'naughty list' and has a firewall block...

    Re: Website "Not safe"

    Posted: Sat 20 Apr 2024 7:11 am
    by ConligWX
    I've had problems in the past with cache files being zero bytes in size, But went you delete the cache file the script then seems to work again.

    Re: Website "now safe"

    Posted: Sat 20 Apr 2024 11:05 am
    by De Hout
    PaulMy wrote: Fri 19 Apr 2024 10:50 pm
    Anyone not able to load https://www.komokaweather.com ?
    When I stop Malwarebytes I can see your secured page, but when Malwarebytes realtime scanning is on, I see exactly the same as Hans posts.

    Re: Website "Not safe"

    Posted: Sat 20 Apr 2024 12:21 pm
    by griffo42
    Paul

    I am using Windows 11.

    When I type in: https:// komokaweather.com/cumulusmx4/index.htm, it goes to the Bing search results page. It looks to me that it can't find a folder entitled cukulusmx4.

    The Komoka WiFi Logger Weather and Komoka WLL Weather versions seem to show and work correctly here.

    The C1 version shows as:
    Screenshot 2024-04-20 220241.png
    Note the "Not Secure" showing on this one.

    Hope this is of some assistance.