From peter.jeremy@auss2.alcatel.com.au  Thu Jan 14 21:26:30 1999
Received: from alcanet.com.au (border.alcanet.com.au [203.62.196.10])
          by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id VAA19213
          for <FreeBSD-gnats-submit@FreeBSD.ORG>; Thu, 14 Jan 1999 21:26:29 -0800 (PST)
          (envelope-from peter.jeremy@auss2.alcatel.com.au)
Received: by border.alcanet.com.au id <40342>; Fri, 15 Jan 1999 16:24:32 +1100
Message-Id: <99Jan15.162432est.40342@border.alcanet.com.au>
Date: Fri, 15 Jan 1999 16:25:12 +1100
From: Peter Jeremy <peter.jeremy@auss2.alcatel.com.au>
Reply-To: peter.jeremy@alcatel.com.au
To: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: fetch(1) is not Y2K compliant
X-Send-Pr-Version: 3.2

>Number:         9504
>Category:       bin
>Synopsis:       fetch(1) is not Y2K compliant
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Jan 14 21:30:02 PST 1999
>Closed-Date:    Fri Jan 15 10:50:00 PST 1999
>Last-Modified:  Fri Jan 15 10:50:39 PST 1999
>Originator:     Peter Jeremy
>Release:        FreeBSD 3.0-CURRENT i386
>Organization:
Alcatel Australia
>Environment:

	

>Description:

Fetch(1) assumes that the http data read is the number of years since
1900.

>How-To-Repeat:

Code inspection

>Fix:
	
--- /3.0/src/usr.bin/fetch/http.c	Wed Dec  9 00:00:49 1998
+++ ./http.c	Fri Jan 15 14:46:37 1999
@@ -1408,6 +1408,12 @@
 			   mname, mname + 1, mname + 2, &tm.tm_year,
 			   &tm.tm_hour, &tm.tm_min, &tm.tm_sec) != 8)
 			return -1;
+		/* take years 00 to 69 as 20xx and allow 4-digit years */
+		if (ym.ym_year < 70)
+			ym.ym_year += 100;
+		else if (ym.ym_year > 1899)
+			ym.ym_year -= 1900;
+
 		for (i = 0; i < 12; i++) {
 			if (strcasecmp(months[i], mname))
 				break;
>Release-Note:
>Audit-Trail:

From: Garrett Wollman <wollman@khavrinen.lcs.mit.edu>
To: peter.jeremy@alcatel.com.au
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: bin/9504: fetch(1) is not Y2K compliant
Date: Fri, 15 Jan 1999 09:13:54 -0500 (EST)

 <<On Fri, 15 Jan 1999 16:25:12 +1100, Peter Jeremy <peter.jeremy@auss2.alcatel.com.au> said:
 
 > Fetch(1) assumes that the http data read is the number of years since
 > 1900.
 
 The date format in question is deprecated, and I'd be happy enough to
 name the servers which generates it (NCSA and perhaps CERN) as being
 the non-compliant ones.
 
 -GAWollman
 
 --
 Garrett A. Wollman   | O Siem / We are all family / O Siem / We're all the same
 wollman@lcs.mit.edu  | O Siem / The fires of freedom 
 Opinions not those of| Dance in the burning flame
 MIT, LCS, CRS, or NSA|                     - Susan Aglukark and Chad Irschick
State-Changed-From-To: open->closed 
State-Changed-By: wollman 
State-Changed-When: Fri Jan 15 10:50:00 PST 1999 
State-Changed-Why:  
Fixed in rev. 1.24 of http.c, following recommendation of RFC 2068. 
>Unformatted:
