X-Git-Url: http://gb7djk.dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXProtHandle.pm;h=fc6e13ef25032a3e9148d529be12dac5ce214ecd;hb=f8de8b2dedec09d040a107af6bb82e31e4667c87;hp=f1972b094af888870e44470c1ca5458762eb4085;hpb=fb14276aab794a877986dbc397ede66ea563c7fb;p=spider.git diff --git a/perl/DXProtHandle.pm b/perl/DXProtHandle.pm index f1972b09..fc6e13ef 100644 --- a/perl/DXProtHandle.pm +++ b/perl/DXProtHandle.pm @@ -107,7 +107,7 @@ sub handle_10 return; } - # if this is a 'bad spotter' user then ignore it + my $nossid = $from; $nossid =~ s/-\d+$//; if ($badspotter->in($nossid)) { @@ -186,16 +186,6 @@ sub handle_11 return; } - # if this is a 'bad spotter' or an unknown user then ignore it. BUT if it's got an IP address then allow it through - my $nossid = $pc->[6]; - $nossid =~ s/-\d+$//; - if ($badspotter->in($nossid)) { - dbg($line) if isdbg('nologchan'); - dbg("PCPROT: Bad Spotter $pc->[6], dropped"); - return; - } - - # convert the date to a unix date my $d = cltounix($pc->[3], $pc->[4]); # bang out (and don't pass on) if date is invalid or the spot is too old (or too young) @@ -221,6 +211,8 @@ sub handle_11 return; } + my $nossid = $pc->[6]; + $nossid =~ s/-\d+$//; my @spot = Spot::prepare($pc->[1], $pc->[2], $d, $pc->[5], $nossid, $pc->[7], $pc->[8]); @@ -238,6 +230,13 @@ sub handle_11 } } + # is this is a 'bad spotter' or an unknown user then ignore it. + if ($badspotter->in($nossid)) { + dbg($line) if isdbg('nologchan'); + dbg("PCPROT: Bad Spotter $pc->[6], dropped"); + return; + } + # global spot filtering on INPUT if ($self->{inspotsfilter}) { my ($filter, $hops) = $self->{inspotsfilter}->it(@spot); @@ -247,6 +246,7 @@ sub handle_11 } } + # this is where we decide to delay PC11s in the hope that a PC61 will be along soon. my $key = join '|', @spot[0..2,4,7]; # not including text