Version 1.3. Skip minor pgp signature headers like "charset:" after

"version:" header and until the empty line that starts the base64
signature block.
This commit is contained in:
David Lawrence 1997-08-08 01:04:22 +00:00
parent 31a0b89189
commit c27413448f

View file

@ -1,6 +1,10 @@
#!/usr/local/bin/perl5 -w
# written April 1996, tale@uunet.uu.net (David C Lawrence)
# Version 1.2.1
# written April 1996, tale@isc.org (David C Lawrence)
# Version 1.3
#
# Changes from 1.2.3 to 1.3:
# -- skip minor pgp signature headers like "charset:" after "version:" header
# and until the empty line that starts the base64 signature block
# CONFIGURATION
@ -25,9 +29,9 @@ $pgpheader = "X-PGP-Sig";
$force{'Path'} = 'bounce-back';
$force{'From'} = 'YOUR_ADDRESS_AND_NAME';
$force{'Approved'} = 'ADDRESS_FOR_Approved_HEADER';
$force{'X-Info'}='ftp://ftp.uu.net/networking/news/misc/pgpcontrol/README.html'
$force{'X-Info'}='ftp://ftp.isc.org/pub/pgpcontrol/README.html'
. "\n\t"
. 'ftp://ftp.uu.net/networking/news/misc/pgpcontrol/README';
. 'ftp://ftp.isc.org/pub/pgpcontrol/README';
# host for message-id; this could be determined automatically based on where
# it is run, but consistency is the goal here
@ -183,9 +187,9 @@ readhead
}
}
chop($date = `$get_date`);
$header{'Date'} = $date;
$header{'Message-ID'} = '<' . time . ".$$\@$id_host>";
$header{'Date'} = `$get_date`;
chop($header{'Date'}) if $header{'Date'};
for (@ignoreheaders) {
$die .= "ignored header $_ also has forced value set\n" if $force{$_};
@ -324,8 +328,9 @@ signit
unless /^Version: (\S+)$/;
$header{$pgpheader} = "$1 $signheaders";
chomp($_ = <FH>);
die "$0: didn't find an empty line after PGP Version\n" unless /^$/;
do { # skip other pgp headers like "charset:" until empty line
$_ = <FH>; # ... is charset significant to this application?
} while ! /^$/;
while (<FH>) {
chomp;