#491 new
Christian

S/MIME encryption not working

Reported by Christian | November 18th, 2013 @ 11:37 AM

I'm having problem with the S/MIME encryption. Signing works fine (except that it's not recognised on iOS devices but might be a problem with the iOS mail app), but encryption doesn't work at all.

It says:
Failed to find certificate to encrypt for ************.
One or more parameters passed to a function were not valid. Error code: -50

I have GPGtools installed as well. S/MIME works fine in Apple Mail so not a problem with the certificate etc.

Comments and changes to this ticket

  • Christian

    Christian November 22nd, 2013 @ 10:54 AM

    I would be grateful if someone would try to help me sorting this out. Perhaps I should give some more details on the problem/my setup?

    I'm running Snow Leopard. As mentioned above, signing seems to work but not encryption. In Apple Mail both signing and encryption works so I guess that means the certificate is installed correctly.

  • benny

    benny November 22nd, 2013 @ 11:12 AM

    The error message you get says that MailMate is providing an invalid parameter, so let's try finding out what that is.

    First enabled debug output in the Terminal:

    defaults write com.freron.MailMate MmDebugSecurity -bool YES
    

    Then launch MailMate from the Terminal:

    /Applications/MailMate.app/Contents/MacOS/MailMate
    

    Try encrypting and provide the output in the Terminal. By email if you like (“Help ▸ Send Feedback”).

    Thanks in advance.

  • Christian

    Christian November 22nd, 2013 @ 11:21 AM

    Thanks for your quick reply.

    Here is the output:

    Searching for certificate for ********  
     Result: Failure
     Detail: Failed to find certificate to encrypt for **********.
     Detail: One or more parameters passed to a function were not valid. Error code: -50
    2013-11-22 12:16:02.207 MailMate[24211:903] Warning: Unknown security problem (S/MIME): unknown  
    2013-11-22 12:16:02.276 MailMate[24211:903] Warning: Unknown security problem (S/MIME): unknown  
    2013-11-22 12:16:02.420 MailMate[24211:903] Warning: Unknown security problem (S/MIME): unknown
    

    I do have a certificate for the email address in keychain and it works in Apple Mail. I did however have an issue with MailMate trying to use an old expired certificate instead of a new one which I solved by deleting the old certificate (which isn't ideal obviously but it was a certificate that I hadn't used anyway so not an issue). Could it be that MailMate is still trying to use the deleted certificate instead of the new one.

    The odd thing is that signing works fine...

  • Christian

    Christian November 22nd, 2013 @ 11:33 AM

    Actually just tried with another email address for which I have not had the problems above with an old certificate and same issue.

  • benny

    benny November 22nd, 2013 @ 11:33 AM

    No, signing works fine which means your certificate is fine. When encrypting, you need the certificate of the recipient. This is what fails to work correctly. There is some indication that the problem is not really that it's missing: “One or more parameters passed to a function were not valid.”

    It seems the only parameter is ********. Anything special about that? Can you send the address to me by private email? Are you sure you have a certificate for that address?

  • Christian

    Christian November 22nd, 2013 @ 11:45 AM

    Just sent you an email from the address in question. Nothing special with the address as far as I know. Also signed the email so I guess you could try to encrypt an email on your side with that certificate.

    Have tried with two different recipient addresses. Same problem. Both certificates work fine in Apple Mail.

    I realise that I need the recipient's certificate for encrypting and my own for signing and I think I'm doing that part of it correctly, so don't think the problem lies there.

  • benny

    benny November 22nd, 2013 @ 11:53 AM

    Which version of OS X are you using?

  • Christian

    Christian November 22nd, 2013 @ 12:00 PM

    Using 10.6.

    Added your certificate and tried to encrypt. Same problem.

  • benny

    benny November 22nd, 2013 @ 12:02 PM

    10.6 is not officially supported, but I'm not sure the problem is related to 10.6. Do you have any way to check if you have the same problem on 10.7+?

  • Christian

    Christian November 22nd, 2013 @ 12:28 PM

    Ah, didn't even realise. :) It works perfectly on 10.6 apart from this issue.

    No, unfortunately not now. But if that's the cause, it's not a big deal. Upgrading in a couple of weeks. Could follow up on it then.

  • benny

    benny November 22nd, 2013 @ 12:29 PM

    • State changed from “new” to “cantreproduce”

    Ok, thanks. I'll leave the ticket in a cantreproduce state, but you are welcome to add new comments when you have upgraded.

  • Christian

    Christian December 9th, 2013 @ 04:38 PM

    Updated to Mavericks and it seems to be working fine now so guess it was due to Snow Leopard.

  • benny

    benny December 9th, 2013 @ 10:49 PM

    • State changed from “cantreproduce” to “closed”

    Thanks for the update. I'll close the ticket.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Mac OS X email client.

Shared Ticket Bins

People watching this ticket

Pages