From: Dirk Koopman Date: Mon, 3 Jan 2022 13:17:16 +0000 (+0000) Subject: prevent PC92 A/C changing our $my(alias|call) X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=a24cc09d8262093df92c767d3010c0a5fd6e42d7;p=spider.git prevent PC92 A/C changing our $my(alias|call) It appears that some nodes are getting knickers in a twist in their routing tables and causing routes and thus $my(alias|call) file types to change. Prevent this from happening. --- diff --git a/Changes b/Changes index ca654a6b..2441b64c 100644 --- a/Changes +++ b/Changes @@ -3,6 +3,8 @@ $clusterport. This is really only of use for people trying to run more than one instance of DXSpider on the same machine. 2. Fix who command to make RBN connections as RBN and not USER. +3. Prevent other nodes claiming that $myalias or $mycall is a different type + (user or node) from changing our route table and thence the user type. 02Jan22======================================================================= 1. Fix dx bug introduced to handle dx by ip for webclusters. 2. Remove _add_thingy dbg message from general view. diff --git a/cmd/dx.pl b/cmd/dx.pl index ea76aab5..7cf460cc 100644 --- a/cmd/dx.pl +++ b/cmd/dx.pl @@ -45,7 +45,7 @@ if ($f[0] =~ /^by$/i) { return (1, $self->msg('e5')) unless $main::allowdxby || $self->priv > 1; $spotter = uc $f[1]; $line =~ s/^\s*$f[0]\s+$f[1]\s+//; - @f = split /\s+/, $line, 3; + @f = split /\s+/, $line, 3; return (1, $self->msg('dx2')) unless @f >= 2; } diff --git a/cmd/set/rbn.pl b/cmd/set/rbn.pl index 2f1ff07a..c0b90c66 100644 --- a/cmd/set/rbn.pl +++ b/cmd/set/rbn.pl @@ -19,7 +19,7 @@ return (1, $self->msg('e5')) if $self->priv < 5; foreach $call (@args) { $call = uc $call; - if ($call eq $main::myalias) { + if ($call eq $main::mycall) { push @out, $self->msg('e11', $call); next; } diff --git a/cmd/set/spider.pl b/cmd/set/spider.pl index a0e519b6..28a91a12 100644 --- a/cmd/set/spider.pl +++ b/cmd/set/spider.pl @@ -19,7 +19,7 @@ return (1, $self->msg('e5')) if $self->priv < 5; foreach $call (@args) { $call = uc $call; - if ($call eq $main::myalias) { + if ($call eq $main::mycall) { push @out, $self->msg('e11', $call); next; } diff --git a/perl/DXProtHandle.pm b/perl/DXProtHandle.pm index c39b52e1..79b9b8ba 100644 --- a/perl/DXProtHandle.pm +++ b/perl/DXProtHandle.pm @@ -2016,6 +2016,11 @@ sub handle_92 dbg("PCPROT: $_->[0] refers to me, ignored") if isdbg('chanerr'); next; } + if ($_->[0] eq $main::myalias && $_->[1] || $_->[0] eq $main::mycall && $_->[1] == 0) { + dbg("PCPROT: $_->[0] changing type to " . $_->[1]?"Node":"User" . ", ignored") if isdbg('chanerr'); + next; + } + push @nent, $_; }