While the ';' requires escaping on the command-line, the
presence of ";AUTH=ANONYMOUS" communicates clearly that
anonymous access is supported in accordance to RFC 4505.
$ctx->{ibx}->can('nntp_url') or return; # TODO extindex can have IMAP
my $urls = $ctx->{ibx}->imap_url($ctx);
if (@$urls) {
- $$txt .= "\nIMAP subfolder(s) are available under:";
- $$txt .= "\n " . join("\n ", @$urls);
+ $urls = join("\n ", @$urls);
+ $urls =~ s!://([^/@]+)/!://;AUTH=ANONYMOUS\@$1/!sg;
$$txt .= <<EOM
+IMAP subfolder(s) are available under:
+ $urls
# each subfolder (starting with `0') holds 50K messages at most
EOM
}