Looking at IMAP traffic on public-inbox.org, it seems there is a
fair amount of traffic coming from malicious clients assuming
the IMAP server is compromised and searching for private
information. Since AUTH=ANONYMOUS clients are more likely to
be legitimate clients looking for publicly-archived mail,
give them priority.
sub auth_challenge_ok ($) {
my ($self) = @_;
my $tag = delete($self->{-login_tag}) or return;
sub auth_challenge_ok ($) {
my ($self) = @_;
my $tag = delete($self->{-login_tag}) or return;
login_success($self, $tag);
}
login_success($self, $tag);
}
$smsg->{blob} eq $oid or die "BUG: $smsg->{blob} != $oid";
}
my $pre;
$smsg->{blob} eq $oid or die "BUG: $smsg->{blob} != $oid";
}
my $pre;
- if (!$self->{wbuf} && (my $nxt = $msgs->[0])) {
- $pre = ibx_async_prefetch($ibx, $nxt->{blob},
+ ($self->{anon} && !$self->{wbuf} && $msgs->[0]) and
+ $pre = ibx_async_prefetch($ibx, $msgs->[0]->{blob},
\&fetch_blob_cb, $fetch_arg);
\&fetch_blob_cb, $fetch_arg);
fetch_run_ops($self, $smsg, $bref, $ops, $partial);
$pre ? $self->dflush : $self->requeue_once;
}
fetch_run_ops($self, $smsg, $bref, $ops, $partial);
$pre ? $self->dflush : $self->requeue_once;
}