I notice that Mail.app (version 6.5) sometimes displays the from field of a message in a different case from how it is written in the raw message source. This seems to account for why some digitial certificates are listed as invalid ("Unable to verify message signature") by Mail. If the certificate lists the RFC 822 Name in lowercase, and the raw source of the message lists the email address in lowercase, but Mail is displaying it with initial capitals, then the certificate is listed as invalid.
I've anonymized the particular example I'm working with -- let's say the address is firstname.lastname@example.org.
For example, I have a message in which the from line of the raw source -- and all other references to this email address in the message header and body -- are in lower case (email@example.com), and yet Mail displays the from field with initial capitals (Foo.Goo@blah.com). Not only that, but control-clicking on the from field also yields the capitalized version (Foo.Goo@blah.com).
So my question is: what is causing Mail to capitialize the email address?
I have smart addresses turned off in Mail viewing preferences. My address book only lists the person in question's email address in all lowercase. And I don't have a certificate from the person in my keychain that's not in lowercase.
Clearly Mail is looking somewhere else, but where?.