+11Feb25======================================================================
+1. Remove duplicates from $DXProt::senderverify debug messages if this
+ variable is set to warn of or dump suspicious spots from spotters that
+ are not in the routing table for the node that they are claiming to
+ be spotting from.
+2. Add this node's ip address to the PC92 K record on output.
04Feb25======================================================================
1. Improve badspotter/node handling to handle more cases, more easily.
Hopefully this won't cause problems greater than we already have.
# $self->send_last_pc92_config($main::routeroot);
# $self->send(pc92a($main::routeroot, $node)) unless $main::routeroot->last_PC92C =~ /$self->{call}/;
$self->send(pc92a($main::routeroot, $node));
- $self->send(pc92k($main::routeroot));
+ $self->send(pc92k($main::routeroot, DXCommandmode::alias_localhost($main::me->{hostname} || '127.0.0.1')));
} else {
# create a list of all the nodes that are not connected to this connection
# and are not themselves isolated, this to make sure that isolated nodes
my $uref = DXUser::get_current($pc->[7]);
my $s = '';
my $ip = $pcno == 61 ? $pc->[8] : '';
+ my ($hops) = $pc->[$pcno == 61 ? 9 : 8] =~ /H(\d+)/;
if ($nroute && ($nroute->last_PC92C || ($local && !$local->do_pc9x))) {
# $s .= "User $pc->[6] not logged in, " unless $uroute;
if ($s) {
my $action = $sv > 1 ? ", DUMPED" : '';
$s =~ s/, $//;
- dbg("PCPROT: Bad Spot $pc->[2] on $pc->[1] by $pc->[6]($ip)\@$pc->[7] $s$action");
+ $hops ||= '0';
+ dbg("PCPROT: Bad Spot $pc->[2] on $pc->[1] by $pc->[6]($ip)\@$pc->[7] $s$action via $self->{call} $hops hops");
return unless $sv < 2;
}
}
my $oldversion = $parent->version || 0;
my $user = check_add_user($parent->call, 'S');
my $oldsort = $user->sort // '';
+ my $ipaddr = @ent > 10 ? $ent[9] : '';
dbg("PCPROT: PC92 K v: $version ov: $oldversion b: $build ob: $oldbuild pk: " . ($parent->K || '0') . " uk: " . ($user->K || 0)) if isdbg('pc92k');
sub pc92k
{
my $nref = shift;
+ my $ipaddr = shift;
+
my $s = "PC92^$main::mycall^" . gen_pc9x_t() . "^K";
$s .= "^" . _encode_pc92_call($nref, 1) . ":$main::me->{build}";
$s .= "^" . scalar $nref->nodes;
$s .= "^" . scalar $nref->users;
+ $s .= "^$ipaddr" if $ipaddr;
return $s . '^H99^';
}