🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
12 messages
12 total messages Started by Anand Gupta Fri, 23 Feb 2001 15:30
Format for date in Article
#50773
Author: Anand Gupta
Date: Fri, 23 Feb 2001 15:30
10 lines
980 bytes
I would like to pick the Date header from the article body.
There are two headers that I see NNTP-posting-date: and Date: 
I would like to use the header which has a consistent format.
All my posts are coming from a single server. Which of the two headers
can I use to have a consistent format for the date ?

Thanks,


Re: Format for date in Article
#50768
Author: Terrance Richard Boyes
Date: Fri, 23 Feb 2001 19:27
31 lines
2847 bytes
Anand Gupta <prence@aclindia.net> wrote:
> I would like to pick the Date header from the article body.
> There are two headers that I see NNTP-posting-date: and Date: 
> I would like to use the header which has a consistent format.
> All my posts are coming from a single server. Which of the two headers
> can I use to have a consistent format for the date ?

Date: may be added by the newsreader or the first server it is
posted to, so you may get some slight inconsistencies even if
all articles were originally posted to the same server.

NNTP-Posting-Date: may be added by the first server it is
posted to, OTOH it may not be added at all as it is not a
mandatory header. It is unlikely to be added by newsreader
software, though it could be...

So iff all articles are originally posted to the same server,
and it always rewrites any date that's already there can you
be certain that the date will be consistent.

Last time I had to deal with dates in multiple formats
I was using Oracle, so rather than spend lots of effort
trying to parse the string I instead just threw the string
at the date() function with the most likely format, if
that failed I tried the next most likely format, and so on.

-- 
<URL:http://www.pierrot.co.uk/>                                  Team AMIGA
Visit beautiful Wisconsin Dells.

Re: Format for date in Article
#50769
Author: J.B. Moreno
Date: Fri, 23 Feb 2001 19:29
15 lines
1388 bytes
In article <3a967c7e.37419301@news.alt.net>, Anand Gupta
<prence@aclindia.net> wrote:

> I would like to pick the Date header from the article body.
> There are two headers that I see NNTP-posting-date: and Date: 
> I would like to use the header which has a consistent format.
> All my posts are coming from a single server. Which of the two headers
> can I use to have a consistent format for the date ?

Neither.  There can be some minor difference's in both depending where
and with what the article was created.

-- 
J.B. Moreno
Re: Format for date in Article
#50777
Author: Russ Allbery
Date: Fri, 23 Feb 2001 20:55
21 lines
1906 bytes
J B Moreno <planb@newsreaders.com> writes:
> Anand Gupta <prence@aclindia.net> wrote:

>> I would like to pick the Date header from the article body.  There are
>> two headers that I see NNTP-posting-date: and Date: I would like to use
>> the header which has a consistent format.  All my posts are coming from
>> a single server. Which of the two headers can I use to have a
>> consistent format for the date ?

> Neither.  There can be some minor difference's in both depending where
> and with what the article was created.

If all the articles are coming from a single server, NNTP-Posting-Date
should be consistent provided that that server generates it.

-- 
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: Format for date in Article
#50802
Author: Black Dragon
Date: Sat, 24 Feb 2001 03:41
54 lines
3323 bytes
On Fri, 23 Feb 2001 19:27:00 +0000 (GMT) in news.software.nntp,
<tez@pierrot.co.uk> `Terrance Richard Boyes' said:

: Date: may be added by the newsreader or the first server it is
: posted to, so you may get some slight inconsistencies even if
: all articles were originally posted to the same server.
: 
: NNTP-Posting-Date: may be added by the first server it is
: posted to, OTOH it may not be added at all as it is not a
: mandatory header. It is unlikely to be added by newsreader
: software, though it could be...
: 
: So iff all articles are originally posted to the same server,
: and it always rewrites any date that's already there can you
: be certain that the date will be consistent.
: 
: Last time I had to deal with dates in multiple formats
: I was using Oracle, so rather than spend lots of effort
: trying to parse the string I instead just threw the string
: at the date() function with the most likely format, if
: that failed I tried the next most likely format, and so on.

I too have a question about dates. I just finished setting up my 
first news server (personal use -- INN / suck / rpost) and would
like to know if there's any way to filter out posts dated in the 
future with INN.

The reason is, I have a colleague who generates weekly statistics 
for a news group using my machine and isp's news feed. (perl/cron)
During the past couple of months, a few posts dated in the future, 
apparently because it was set that way on the senders boxen, munged 
up the stats. (which of course gave a few critics something to talk 
about, it is Usenet after all :-)

http://www.kdg-engineering.homeip.net/amc-stats/2001-01-15.amc.stats
http://www.kdg-engineering.homeip.net/amc-stats/2001-01-22.amc.stats

(Note the Beginning & Ending dates)

At first, he thought a fix would be to use the NNTP-Posting-Date: 
header, but that proved futile for the reason stated above. That led
me to the idea of setting up my own news server with the hopes of 
being able to filter out future dated posts. So I guess my question 
really is, are there any filters already written that can take care 
of this, or, any place I can find some documentation that will steer 
me in the right direction?

Thanks in advance,
Robert Heininger

-- 
Black Dragon
Re: Format for date in Article
#50806
Author: Russ Allbery
Date: Sat, 24 Feb 2001 06:11
16 lines
1742 bytes
Black Dragon <blkdragn@rochester.rr.com.spam.sux> writes:

> I too have a question about dates. I just finished setting up my first
> news server (personal use -- INN / suck / rpost) and would like to know
> if there's any way to filter out posts dated in the future with INN.

INN by default rejects any post dated more than a day in the future; you
can decrease the allowed fuzz by editing the DATE_FUZZ macro in
include/config.h and then recompiling.

-- 
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: Format for date in Article
#50805
Author: Anand Gupta
Date: Sat, 24 Feb 2001 06:12
34 lines
2009 bytes
The million dollar question then is :

How do Newsreaders extract/parse the date from the headers and show it
in a consistent format ?

Is there someplace I can get a format of top 10 (?) formats normalls
used for dates ?

Thanks.

On 23 Feb 2001 12:55:19 -0800, Russ Allbery <rra@stanford.edu> wrote:

>J B Moreno <planb@newsreaders.com> writes:
>> Anand Gupta <prence@aclindia.net> wrote:
>
>>> I would like to pick the Date header from the article body.  There are
>>> two headers that I see NNTP-posting-date: and Date: I would like to use
>>> the header which has a consistent format.  All my posts are coming from
>>> a single server. Which of the two headers can I use to have a
>>> consistent format for the date ?
>
>> Neither.  There can be some minor difference's in both depending where
>> and with what the article was created.
>
>If all the articles are coming from a single server, NNTP-Posting-Date
>should be consistent provided that that server generates it.
>
>-- 
>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: Format for date in Article
#50807
Author: Andrew Gierth
Date: Sat, 24 Feb 2001 06:22
14 lines
1691 bytes
>>>>> "Black" == Black Dragon <blkdragn@rochester.rr.com.spam.sux> writes:

 Black> I too have a question about dates. I just finished setting up
 Black> my first news server (personal use -- INN / suck / rpost) and
 Black> would like to know if there's any way to filter out posts
 Black> dated in the future with INN.

INN will reject anything more than DATE_FUZZ (defined as 1 day) in the
future. (This is to avoid rejecting articles where the poster's
timezone is set wrong, or the poster's clock is a little off.)

-- 
Andrew.
Re: Format for date in Article
#50808
Author: Russ Allbery
Date: Sat, 24 Feb 2001 06:33
29 lines
2174 bytes
Anand Gupta <prence@aclindia.net> writes:

> How do Newsreaders extract/parse the date from the headers and show it
> in a consistent format ?

They parse the Date header.  Many of them use code derived from
getdate.y/parsedate.y, which has been around for many years and which you
can find in INN as well as many other software products.  Others have
rolled their own parser.

> Is there someplace I can get a format of top 10 (?) formats normalls
> used for dates ?

These days, there's pretty much only one format that you have to worry
about, and that's the one described in:

  <http://www.ietf.org/internet-drafts/draft-ietf-drums-msg-fmt-09.txt>

in section 3.3.  See also the obs-* syntax elements for styles that used
to be used but shouldn't be generated any more; the primary variations
that you'll encounter are two digit years or one of the US time zones
given instead of a numeric offset.

-- 
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: Format for date in Article
#50809
Author: Black Dragon
Date: Sat, 24 Feb 2001 07:56
24 lines
2006 bytes
On 23 Feb 2001 22:11:25 -0800 in news.software.nntp,
<rra@stanford.edu> `Russ Allbery' said:

: Black Dragon <blkdragn@rochester.rr.com.spam.sux> writes:
: 
: > I too have a question about dates. I just finished setting up my first
: > news server (personal use -- INN / suck / rpost) and would like to know
: > if there's any way to filter out posts dated in the future with INN.
: 
: INN by default rejects any post dated more than a day in the future; you
: can decrease the allowed fuzz by editing the DATE_FUZZ macro in
: include/config.h and then recompiling.

Thank you very much Russ, and Andrew. I was just looking over my logs
and seen that 4 future dated articles got rejected. I just subscribed
to this group yesterday and read every post -- I'm in awe, you guys
know your stuff!

Thanks again. :-)

-- 
Black Dragon
Re: Format for date in Article
#50908
Author: Barry Bouwsma is a Certified Eng...
Date: Thu, 01 Mar 2001 15:22
52 lines
4588 bytes
*** post for free via your newsreader at post.newsfeeds.com ***

:: >> I would like to pick the Date header from the article body.  There are
:: >> two headers that I see NNTP-posting-date: and Date: I would like to use
:: >> the header which has a consistent format.  All my posts are coming from
:: 
:: > Neither.  There can be some minor difference's in both depending where
:: > and with what the article was created.
:: 
:: If all the articles are coming from a single server, NNTP-Posting-Date
:: should be consistent provided that that server generates it.

Yahbut, good luck parsing it consistently without knowing something
that I don't know, or else parse these here Highwind-supplied headers
without the hints that I've chosen to leave (cuz they're user-supplied
and not overwritten by the swerver):

NNTP-Posting-Date: Thu, 01 Mar 2001 15:32:02 MET

Date: Thu, 1 Mar 2001 23:10:23 +1100
X-Trace: newsfeeds.bigpond.com 983447942 203.54.212.78 (Thu, 01 Mar 2001 22:59:02 EST)
NNTP-Posting-Date: Thu, 01 Mar 2001 22:59:02 EST

Date: Wed, 28 Feb 2001 18:39:46 -0500
X-Trace: news.total.net 983403785 154.5.40.108 (Wed, 28 Feb 2001 18:43:05 EST)
NNTP-Posting-Date: Wed, 28 Feb 2001 18:43:05 EST


I'm too lazy to dig up some of the other ambiguous examples I've
seen...

  **** Post for FREE via your newsreader at post.newsfeeds.com ****

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
*** Newsfeeds.com - The #1 Usenet Newsgroup Service on The Planet! ***
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  http://www.newsfeeds.com���    |         http://www.newsfeeds.com
                                 |
* Anonymous posting server!      | * Totally Uncensored!
* SUPER Servers!                 | * Over 80,000 Newsgroups!
* BINARIES ONLY Servers!         | * 16 seperate Newsgroup Servers!
* SPAM FILTERED Server!          | * Instant access!
* ADULT ONLY Server!             | * Multiple OC 3's and OC 12's!
* MP3 ONLY Server!               | * 99% Article Completion!
* MULTIMEDIA ONLY Server!        | * Months of Retention!
* 7 UNCENSORED Newsgroup Servers | * Lightning FAST downloads!
                                 |
  http://www.newsfeeds.com       |         http://www.newsfeeds.com
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 �      **** Point your newsreader to post.newsfeeds.com ****
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= 
Re: Format for date in Article
#50911
Author: Barry Bouwsma is a Certified Eng...
Date: Thu, 01 Mar 2001 16:13
58 lines
5014 bytes
*** post for free via your newsreader at post.newsfeeds.com ***

::  Black> would like to know if there's any way to filter out posts
::  Black> dated in the future with INN.
:: 
:: INN will reject anything more than DATE_FUZZ (defined as 1 day) in the
:: future. (This is to avoid rejecting articles where the poster's
:: timezone is set wrong, or the poster's clock is a little off.)

I don't see how a timezone is any different from a clock that is
off.  They parse to the same thing, even if it looks right that
right now is late afternoon in Redmond for a good number of posters.

To that end, I'm willing to tolerate a few minutes of clock drift,
but anything more than that, well, either the reader should allow
the swerver to set the correct and accurate NTP-derived date header
or else they should set their own time.  Also, since a lot of both
transit and reader sites reject posts more than a few days old as
parsed by the Date: header, I see no reason to allow more than a
few days of offline activity before advising the reader to set the
time properly.

To this end, I've added NNRP_DATE_FUZZ that takes the place of the
DATE_FUZZ but still allows INN to accept future-dated posts from
other sites, and only allow local postings to be less than one hour
in the future, regardless of timezone (since we have presence over
several european timezones and in New Jersey), and an additional
define that I've set for a three-day cutoff into the past, that
will help those whose clocks are several days slow fix that problem
so their posts get seen at nearly every site, instead of just those
few with generous two-week or so article cutoffs.

Of course, I could be wrong.  Patches may follow in short order.

Ihr alpine connection
  Kvindeservice

  **** Post for FREE via your newsreader at post.newsfeeds.com ****

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
*** Newsfeeds.com - The #1 Usenet Newsgroup Service on The Planet! ***
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  http://www.newsfeeds.com���    |         http://www.newsfeeds.com
                                 |
* Anonymous posting server!      | * Totally Uncensored!
* SUPER Servers!                 | * Over 80,000 Newsgroups!
* BINARIES ONLY Servers!         | * 16 seperate Newsgroup Servers!
* SPAM FILTERED Server!          | * Instant access!
* ADULT ONLY Server!             | * Multiple OC 3's and OC 12's!
* MP3 ONLY Server!               | * 99% Article Completion!
* MULTIMEDIA ONLY Server!        | * Months of Retention!
* 7 UNCENSORED Newsgroup Servers | * Lightning FAST downloads!
                                 |
  http://www.newsfeeds.com       |         http://www.newsfeeds.com
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 �      **** Point your newsreader to post.newsfeeds.com ****
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= 
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