Search The ForumSearch   RegisterRegister  LoginLogin

MailBee.NET IMAP

 AfterLogic Forum : MailBee.NET IMAP
Subject Topic: Unable to connect with StartTls Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
groblescompu
Newbie
Newbie
Avatar

Joined: 26 February 2021
Location: France
Online Status: Offline
Posts: 1
Posted: 26 February 2021 at 5:19am | IP Logged Quote groblescompu

Hello Everybody,

I encounter a problem when using StartTls () for the Imap component.
We authenticate ourselves using authentication cards and it sometimes happens that we have to change the card in order to retrieve mails on another account.
The connection to the first account with the authentication card works fine. By cons when I change card and I try to authenticate with this card for his associated account I have an error and he can not find his information.
I have verified that in the certificate store all were in place.
If I relaunch the application and I authenticate myself with this famous card on the corresponding account all work niquel. The error occurs after a first authentication with another card / account.
we are using version 9 of the components.
If you have an idea, I'm a taker because I don't know what to do anymore!

Sorry for my awfull english
Back to Top View groblescompu's Profile Search for other posts by groblescompu
 
Alex
AfterLogic Support
AfterLogic Support
Avatar

Joined: 19 November 2003
Online Status: Offline
Posts: 2182
Posted: 26 February 2021 at 12:29pm | IP Logged Quote Alex

Hi,

I guess you're using client certificates for authentication. You can check if your code is correct by making some simple test sample.

Code:

Imap imp = new Imap();
imp.Log.Enabled = true;
imp.Log.Filename = @"C:\Temp\log.txt";
imp.Log.Clear();
imp.SslCertificates.Client = new Certificate(@"C:\my1.pfx", CertFileType.Pfx, "secret");
imp.Connect(...);
imp.StartTls();
imp.Disconnect();
imp.SslCertificates.Client = new Certificate(@"C:\my2.pfx", CertFileType.Pfx, "secret");
imp.Connect(...);
imp.StartTls();
imp.Disconnect();


Does it work this way? If not, does it work if you try my2 first and then my1? You'll need to collect as much info as possible, with different scenarios. Also, please note that we support only the current, up-to-date version. So please make sure you tried the latest version.

Regards,
Alex
Back to Top View Alex's Profile Search for other posts by Alex
 
petervolz
Newbie
Newbie


Joined: 20 March 2023
Location: United Kingdom
Online Status: Offline
Posts: 2
Posted: 20 March 2023 at 4:11pm | IP Logged Quote petervolz

Hi - I didn't know that instead of setting authentication options, we can use client certificates, so no username/password is needed to authenticate, but now bunch of questions are in my mind; does pop3 also support this? as well as StartTls for pop3?
CertFileType P7b and cer can't be used for this kind of authentication?
And is this something that server must support?
Anyone got idea?
Back to Top View petervolz's Profile Search for other posts by petervolz
 
petervolz
Newbie
Newbie


Joined: 20 March 2023
Location: United Kingdom
Online Status: Offline
Posts: 2
Posted: 20 March 2023 at 4:16pm | IP Logged Quote petervolz

oh forgot to ask about if client certificate can be set from X509Store \ X509Certificate2?
Back to Top View petervolz's Profile Search for other posts by petervolz
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 5964
Posted: 21 March 2023 at 3:38am | IP Logged Quote Igor

Quote:
does pop3 also support this? as well as StartTls for pop3?


Yes.

Quote:
CertFileType P7b and cer can't be used for this kind of authentication?


They cannot as they don't contain a private key.

Quote:
And is this something that server must support?


Indeed, as that requires advanced configuration you probably won't get with public email services but can be done in case of corporate network servers.

Quote:
if client certificate can be set from X509Store \ X509Certificate2?


Yes, that's actually the only way how it would work.

--
Regards,
Igor, Afterlogic Support
Back to Top View Igor's Profile Search for other posts by Igor
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump

Powered by Web Wiz Forums version 7.9
Copyright ©2001-2004 Web Wiz Guide