When I run this on the .NET Core 3.1 Ubuntu Bionic image, it works fine:
using System;
using MailKit.Net.Smtp;
namespace app {
class Program {
static void Main(string[] args) {
using(var client = new SmtpClient()) {
client.Connect("dotforward.de", 465, true);
client.NoOp();
client.Disconnect(true);
}
}
}
}
When I run the program, I can also see that the .NET Core runtime is reading from /etc/ssl/certs/ca-certificates.crt. Maybe make sure that file exists and is readable.