Page 1 of 1

New METAR errors

Posted: Fri 08 Jul 2022 4:58 pm
by N0BGS
All:

I'm been unable to download current METAR data for several days now. The NWS sites referenced in the scripts are reachable but obviously something has changed.

Getting the following error:

Code: Select all

PHP Warning:  Undefined array key "RAW-METAR" in /var/www/html/include-metar-display.php on line 243
Lines 242-248 of the script are:

Code: Select all

 print "  <tr>\n";
   print "     <td class=\"data1\" colspan=\"2\"><small>".$mtr['RAW-METAR']."</small></td>\n";
   print "  </tr>\n";
   if(isset($_REQUEST['debug']) and strtolower($_REQUEST['debug']) == 'y') {
     print "  <tr>\n";
     print "     <td class=\"data1\" colspan=\"2\"><small>".$mtr['METAR']."</small></td>\n";
     print "  </tr>\n";
The METAR cache file is also not being created even though the cache folder perms are 777 (RWX) I'm running PHP 8.1.7 on the web host and all my Saratoga scripts are up to date.

Anyone else seeing this?

Thanks,

--Kurt

https://www.kpw3.com

Re: New METAR errors

Posted: Fri 08 Jul 2022 6:17 pm
by saratogaWX
It looks like a problem with the SSL settings on your website hoster. Maybe a 'tightening' of security on their part has disallowed older versions of TLS to be used for HTTPS negotiations, so the connection to tgftp.nws.noaa.gov fails and returns no data.
<!-- curl fetching 'https://tgftp.nws.noaa.gov/data/observa ... s/KBGR.TXT' -->
<!-- curl Error: error:0A000152:SSL routines::unsafe legacy renegotiation disabled -->
<!-- HTTP stats: RC=0 dest=140.172.138.79 port=443 (from sce=192.168.1.7)
Times: dns=0.001 conn=0.001 pxfer=0.000 get=0.154 total=0.154 secs -->
<!-- headers returned:

-->
<!-- mtr_conditions returns RC='' for ICAO/METAR='KBGR' -->
using check-fetch-times.php?show=info shows
Socket transports: ssl, tcp, tls, tlsv1.0, tlsv1.1, tlsv1.2, tlsv1.3, udg, udp, unix
and that you're using OpenSSL/3.0.3 on PHP Version 8.1.7. My site is also running PHP 8.1.7 with NSS/3.53.1 and having no issue so there must be some other global setting controlled by your hoster with OpenSSL/3.0.3 that is causing the connection to fail. I suggest you contact your hoster's tech support about the issue.

Re: New METAR errors

Posted: Fri 08 Jul 2022 6:34 pm
by N0BGS
Thanks, Ken.

I am my own "hoster," but what you've discovered is helpful. I'll check out the TLS settings. I haven't changed them for over a year but maybe a recent Fedora update did that "for" me. (??)

I'll report back when I have more info.

--K