Article View: news.software.nntp
Article #24929Re: Cleanfeed hashing
From: Kenneth Herron
Date: Tue, 06 Jan 1998 00:00
Date: Tue, 06 Jan 1998 00:00
24 lines
1608 bytes
1608 bytes
In article <68muc9$aun$1@shell.monmouth.com>,
Ken Leland <kwl@shell.monmouth.com> wrote:
|I like MD5, and would favor things to increase
|its reach like space stripping, and lowercasing, prior to taking the
|signature, if thats not already done.
I've been hacking heavily on cleanfeed and have experimented with
perl's built-in CRC generator. CRCs are much faster than MD5, but more
prone to false positives. Nevertheless, I've had good results
generating a key as follows:
$hash = substr($hdr{'__BODY__'}, 0, 8192);
$hash =~ tr/A-Z`~!@#$%^&*()_+=[{]}|;:'",<.>?-/a-z./s;
$hash = join($;,
'crc', length($hdr{'__BODY__'}) >> 5, unpack('%24S*', $hash));
Though come to think of it, it'd probably be good to insert the length of
the translated substring in there too.
--
Kenneth Herron -- kherron@campus.mci.net
No animals were harmed during the production of this message.
Technical Details
Message-ID:
<68ucnc$abl$1@news.campus.mci.net>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mailReferences:
<000034AD3C93.NO_UCE@mauve.demon.co.uk> <68mj3v$igl$1@shell.monmouth.com> <68mjn1$9m$1@news1.exit109.com> <68muc9$aun$1@shell.monmouth.com>Show Full Headers
Complete Article Headers
Message-ID: <68ucnc$abl$1@news.campus.mci.net> Subject: Re: Cleanfeed hashing Date: Tue, 06 Jan 1998 00:00:00 +0000 From: kherron@campus.mci.net (Kenneth Herron) References: <000034AD3C93.NO_UCE@mauve.demon.co.uk> <68mj3v$igl$1@shell.monmouth.com> <68mjn1$9m$1@news1.exit109.com> <68muc9$aun$1@shell.monmouth.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mail X-Deja-AN: 313427286 X-Newsposter: trn 4.0-test54 (18 Feb 97) Distribution: inet Organization: CampusMCI Newsgroups: news.software.nntp