blob: 1001ed98e264f4f350435d3c489090b2699ddcee (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
#!/usr/local/bin/perl
#
# A small script to strip out any "illegal" PGP code to make sure it is
# safe for International export.
#
#
# $Id$
#
$word = shift;
$illegal = 0;
$count = 0;
while (<>)
{
if (/^#if/)
{
if (!/^\#ifn/ && /${word}/) { $illegal = 1; }
if ($illegal) { $count++; }
}
elsif ($illegal && /^#endif/)
{
$count--;
if ($count == 0)
{
$illegal = 0;
next;
}
}
print if (! $illegal);
}
|