Thread View: news.software.nntp
6 messages
6 total messages
Started by Jan Krumsiek
Mon, 19 Feb 2001 21:40
ARPANET date?
Author: Jan Krumsiek
Date: Mon, 19 Feb 2001 21:40
Date: Mon, 19 Feb 2001 21:40
10 lines
1347 bytes
1347 bytes
i'm writing a function that converts the "Date" line in a usenet-article header into "real" dates (vb-dates or something like this). the rfc says that the date-header line contains a ARPANET date?! what is this? is there a definition for this somewhere?? are all time-zones allowed in this date and does anybody know where to find definitions for all time-zones?? Jan Krumsiek
Re: ARPANET date?
Author: Russ Allbery
Date: Tue, 20 Feb 2001 00:26
Date: Tue, 20 Feb 2001 00:26
20 lines
1798 bytes
1798 bytes
Jan Krumsiek <Jan.Krumsiek.Nospam@gmx.de> writes:
> i'm writing a function that converts the "Date" line in a usenet-article
> header into "real" dates (vb-dates or something like this).
> the rfc says that the date-header line contains a ARPANET date?! what is
> this? is there a definition for this somewhere?? are all time-zones
> allowed in this date and does anybody know where to find definitions for
> all time-zones??
See RFC 822. Thankfully, you don't have to parse *all* time zones, just
the US ones (and possibly the military ones, although no one uses them any
more).
--
Russ Allbery (rra@stanford.edu) <http://www.eyrie.org/~eagle/>
Please post questions rather than mailing me directly.
<http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Re: ARPANET date?
Author: 101 Meowbots
Date: Tue, 20 Feb 2001 03:30
Date: Tue, 20 Feb 2001 03:30
35 lines
2732 bytes
2732 bytes
Jan Krumsiek <Jan.Krumsiek.Nospam@gmx.de> wrote: > i'm writing a function that converts the "Date" line in a usenet-article > header into "real" dates (vb-dates or something like this). You are wandering into murky waters here. If you want to sort/search/compare dates, you are going to have to parse the things, and that's that. If, however, you only want to display dates, you can save yourself much aggravation by simply displaying the unmodified header contents. > the rfc says that the date-header line contains a ARPANET date?! what is > this? is there a definition for this somewhere?? ARPANET was the original project for which the Internet protocols were devised. > are all time-zones allowed in this date and does anybody know where to > find definitions for all time-zones?? You want two documents, RFC 822 (the mail message format on which news articles are based) and RFC 1123, containing important corrections to RFC 822. The most important correction is in the year field. It was originally specified as two digits but changed to four. You will need to expect both forms of the year, and should expect to see some lingering Y2K problems. The current year may appear as 2001, 101, 01, 19101, and possibly other interesting variations, so your parser will need to be flexible. If you can find an existing mail/date library to use, try it before writing your own. This problem has a habit of spawning years-long debugging cycles, so advantage of k0dez that have already been through that ordeal.
Re: ARPANET date?
Author: uhlar
Date: Tue, 20 Feb 2001 08:08
Date: Tue, 20 Feb 2001 08:08
12 lines
1567 bytes
1567 bytes
Russ Allbery <rra@stanford.edu> wrote: -> See RFC 822. Thankfully, you don't have to parse *all* time zones, just -> the US ones (and possibly the military ones, although no one uses them any -> more). why? -- Matus "fantomas" Uhlar, sysadmin at NEXTRA, Slovakia; IRCNET admin of *.sk uhlar@fantomas.sk ; http://www.fantomas.sk/ ; http://www.nextra.sk/ I just got lost in thought. It was unfamiliar territory.
Re: ARPANET date?
Author: Meridian Meowbot
Date: Tue, 20 Feb 2001 13:30
Date: Tue, 20 Feb 2001 13:30
23 lines
2129 bytes
2129 bytes
uhlar <uhlar@fantomas.sk> wrote:
> Russ Allbery <rra@stanford.edu> wrote:
> -> See RFC 822. Thankfully, you don't have to parse *all* time zones, just
> -> the US ones (and possibly the military ones, although no one uses them any
> -> more).
> why?
This and more is explained in RFC 1123:
[...]
There is a strong trend towards the use of numeric timezone
indicators, and implementations SHOULD use numeric timezones
instead of timezone names. However, all implementations MUST
accept either notation. If timezone names are used, they MUST
be exactly as defined in RFC-822.
The military time zones are specified incorrectly in RFC-822:
they count the wrong way from UT (the signs are reversed). As
a result, military time zones in RFC-822 headers carry no
information.
Re: ARPANET date?
Author: Frank Slootweg
Date: Tue, 20 Feb 2001 15:28
Date: Tue, 20 Feb 2001 15:28
12 lines
1479 bytes
1479 bytes
101 Meowbots <meowbot@meowing.net> wrote: [deleted] > If you can find an existing mail/date library to use, try it before > writing your own. This problem has a habit of spawning years-long > debugging cycles, so advantage of k0dez that have already been through > that ordeal. Indeed. AFAIK, also most newsreaders do this, so you may want to see if you can 'borrow' code from those. I use tin, which (AFAIK) is sort-of open source, so you may want to contact it's maintainer about this code. (http://www.tin.org)
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads