I just ran into this odd issue with my personal email account today. It is hosted by Bluehost and they use a generic wildcard certificate for TLS security with POP/IMAP. With the recent update, the GMail apparently blocks any existing accounts from syncing if they have a cert with a server name mismatch. There is no longer a way to change the security settings for existing accounts.
Ok, one suggested solution was to delete the account and to recreate it. In the end this did not work, because Gmail would not even let me add this account. I got the same certificate warning right away. But this post is about another issue that I had to overcome before I got there:
How do you delete an IMAP account from your Android phone? This simple question took an amazing amount of research, and I found no answer.
There is indeed no delete option for accounts. The menu underneath the three dots in the top right corner only has one entry – Sync Now. In the end, I was led into the right direction by one of the many flawed answers – someone had said that the “Remove account” option would appear only if Syncing was disabled for the account. This by itself was bogus, because I did not have it turned on to begin with, but I tapped on the “Sync is off” line on the above. This is very confusing, because it takes you to the Sync settings for the account, and the earlier page isn’t actually an account settings page, but rather controls all IMAP accounts.
Either way, tapping on the account takes you to the “Sync” page, and now there is a “Remove account” link. Account gone. Unfortunately,
I wasn’t able to add the account back in because this certificate error now appears right away during validation of the inbound server settings. There is no opportunity to change port numbers or security settings anymore. Thanks, Google! Outlook for Android now looks very attractive again.
PS: I was able to recreate the account by using the server name and hosting provider domain (for which the certificate is issued) instead of my domain name. I.e. I used boxXXX.bluehost.com instead of mydomain.com.