Using the Avast free version on a Mac.
I'm having a very similar problem with the Postbox client, complaining about the certificate for gmail.
Both Avast and Postbox have a supposed fix for this:
https://support.avast.com/en-my/article/91/But, both require access to settings/etc. that don't apparently exist in the free version - esp. the Search field, that allows one to get to the Avast Geek section. So, I'm unable to fix this.
The problem occurs repeatedly, making email completely unusable. Often, if I restart the email client, the problem goes away - for a while. So, I'm able to work for now. But, if it persists, I'll have to uninstall Avast and switch to some other antivirus.
I don't mind that I don't get some of the functionality of Avast in the free version, but breaking something as fundamental as this (a problem they know about), without the means to fix it is really unacceptable.