foreach $dxchan (@ch) {
@val = sort {$a->call cmp $b->call} grep { $_->dxchan == $dxchan } @nodes;
- my $call = $dxchan->call;
- $call = "($call)" if $dxchan->here == 0;
@l = ();
+ my $call = $dxchan->call;
+ $call ||= '???';
+ $call = "($call)" unless $dxchan->here;
push @l, $call;
my $i = 0;
- foreach $call (@val) {
+ foreach my $ref (@val) {
if ($i >= 5) {
push @out, sprintf "%-12s %-12s %-12s %-12s %-12s %-12s", @l;
@l = ();
push @l, "";
$i = 0;
}
- my $s = $call->call;
- $s = sprintf "(%s)", $s unless $call->here;
+ my $s = $ref->call;
+ $s ||= '???';
+ $s = sprintf "(%s)", $s unless $ref->here;
push @l, $s;
$i++;
}
+ push @l, "" while ($i++ < 5);
push @out, sprintf "%-12s %-12s %-12s %-12s %-12s %-12s", @l;
}
} else {
foreach $node (@nodes) {
next if scalar @list && !grep $node->call =~ /^$_/, @list;
my $call = $node->call;
- $call = "($call)" unless $node->here;
@l = ();
+ $call ||= '???';
+ $call = "($call)" unless $node->here;
push @l, $call;
@val = sort $node->users;
push @l, $s;
$i++;
}
+ push @l, "" while ($i++ < 5);
push @out, sprintf "%-12s %-12s %-12s %-12s %-12s %-12s", @l;
}
}
prompt => '0,Required Prompt',
version => '1,Node Version',
build => '1,Node Build',
+ verified => '9,Verified?,yesno',
);
use vars qw($VERSION $BRANCH);
return $self->msg('lh1') unless -e "$main::data/hop_table.pl";
do "$main::data/hop_table.pl";
return $@ if $@;
- return 0;
+ return ();
}
my $self = shift;
my @f = split /\^/, $_[3];
- my $inv = Verify->new($f[7]);
- unless ($inv->verify($f[8], $main::me->user->passphrase, $main::mycall, $self->call)) {
- $self->sendnow('D','Sorry...');
- $self->disconnect;
+ if ($self->passphrase && $f[7] && $f[8]) {
+ my $inv = Verify->new($f[7]);
+ unless ($inv->verify($f[8], $main::me->user->passphrase, $main::mycall, $self->call)) {
+ $self->sendnow('D','Sorry...');
+ $self->disconnect;
+ }
+ $self->{verified} = 1;
+ } else {
+ $self->{verified} = 0;
}
if ($self->{outbound}) {
$self->send($self->genI);
sub genI
{
my $self = shift;
- my $inp = Verify->new;
- return frame('I', $self->call, "DXSpider", ($main::version + 53) * 100, $main::build, $inp->challenge, $inp->response($self->user->passphrase, $self->call, $main::mycall));
+ my @out = ('I', $self->call, "DXSpider", ($main::version + 53) * 100, $main::build);
+ if (my $pass = $self->user->passphrase) {
+ my $inp = Verify->new;
+ push @out, $inp->challenge, $inp->response($pass, $self->call, $main::mycall);
+ }
+ return frame(@out);
}
sub handleR