OK I have just experienced the same certificate issue with a gmail account, not a mobileme account. I've been looking for the thread that says - 'OS X Lion - unable to send mail on one gmail account, quick error message flashes and message stays in drafts'
SO as it turns out with Lion we can add an Apple ID to our User Account. Well, when you do this, Lion creates a certificate in your Login keychain identifying you, and if you happen to have an email account using that address it somehow relates to this certificate now. Worse for me, I installed Lion fresh on a new HD and so I had imported a keychain from my previous SL system, which had some useful passwords in it.
WELL, Lion created my 'Apple ID' certificate in this temporary added keychain, so when I removed that keychain from my system, the certificate went with it and mail started complaining. Same error as above, only mine was with a gmail account. Worse AGAIN for me I have like 5 gmail accounts in Mail, all with IDENTICAL settings and THIS one (my primary email, naturally) was the one failing.
THE FIX:
I did all these steps to fix it but you like don't have to do all of them -
1) Quit Mail
2) System Preferences -> Mail, Contacts, Cal --> remove all (gmail) accounts
3) Open Keychain Access from Applications/utilities, browse to login keychain, all items
4) System Preferences -> User Accounts ::: Remove the Apple ID, see if your apple ID cert vanishes
5) ~/Library/Preferences/ ::: move/rename/delete com.apple.Mail.plist and its lock file if present
6) System Preferences -> Mail, Contacts, Cal --> add your problematice email account back, test it out.
That cost me about 48 hours 🙂
Also- for the screenshot I went into System Preferences -> Keyboard -> Keyboard Shortcuts and changed the shortcut for full screenshot to file to Alt+Z so I could quickly snap a full screenshot of the error message that timyu mentions above. Saved a PNG to my desktop, which was what ultimately led me to find this post.
What was dissapointing was the fact that this error wasn't logged in the system log anywhere that I could see in the Console app.