-
-
Notifications
You must be signed in to change notification settings - Fork 373
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GnuPGContext won't find my public certificate (Mac OS X, GPGTools) #194
Comments
I wonder if GPGTools puts the keyrings in a different place than gpg does when installing it via homebrew. |
Looks like it's stored in the same place, so that's not the problem. Does the email address you are trying to encrypt to exist in your keyring? |
BTW, which target framework are you using? Are you using the PCL? Or .NET 4.5? If you are using nuget, you can check your packages.config to be sure. |
Hi Jeff, and thanx for blistering fast answers, as usual :) The email I am sending to, and also using to encrypt my message, is the same, and it exist in my GPG Keychain, when I look in the GUI for GPG Keychain. I am using .NET 4.5 package id="MailKit" version="1.2.15" targetFramework="net45" (from my packages.config file) |
BTW, it's a web app, running (I presume) in xsp4 (Xamarin) ... |
Okay... and I assume that the key has not been revoked. Does it have an expiration date? In GPGTools' Keyring app, you can right-click on a key and show details. On the "Key" tab (the main tab), what are the values of Validity and Capabilities? On the "Subkeys" tab, what is the value of Capabilities? I'm not entirely sure how to read these values, but I think the subkey Capability value should be "e" (for "supports encryption"). |
(I ask about the expiration date because I am wondering if my logic to calculate expiration is wrong) |
Expires; 8 December 2019 at 12:19 PS, |
Thanks, I'm thinking the expiration date calculation might be the culprit. Everything else matches what my keys look like. |
Darn >= instead of <= ;-) |
Norway use "15 February 2015" for user displayed dates where US use "February 15, 2015", etc ... PS! Let me know if you need anymore to go on :) |
Hahahahahahaha :D ROFLMAO ...!! Well, glad to please :) Thx, when will this be out in nuget? |
https://www.nuget.org/packages/MimeKit/1.2.17.3 I normally don't post to nuget this fast, but I wanted to release a stable (non-prerelease) nuget with the fixes I had done recently anyway :-) |
Thx, you're a champion!! :) |
The Eagle has landed Houston!! 💃 |
Fixed in the MimeKit 1.2.18 nuget :) |
Howdy,
I've installed GPGTools on my MacBook Air, and subclassed GnuPGContext, supplying my password in the GetPasswordForKey method, but when I invoke MultipartEncrypted.Encrypt, it throws an exception saying; "MimeKit.Cryptography.PublicKeyNotFoundException
The public key could not be found."
Stack trace is;
at MimeKit.Cryptography.OpenPgpContext.GetPublicKey (MimeKit.MailboxAddress mailbox) [0x000ea] in :0
at MimeKit.Cryptography.OpenPgpContext.GetPublicKeys (IEnumerable
1 mailboxes) [0x00024] in <filename unknown>:0 at MimeKit.Cryptography.OpenPgpContext.Encrypt (IEnumerable
1 recipients, System.IO.Stream content) [0x0001c] in :0at MimeKit.Cryptography.MultipartEncrypted.Encrypt (MimeKit.Cryptography.OpenPgpContext ctx, IEnumerable`1 recipients, MimeKit.MimeEntity entity) [0x0009a] in :0
I have triple checked in GPG Keychain from GPGTools that the email address is correct. I have even tried multiple emails, both that are imported from Keychain server, and locally created, but regardless of what I do, it seems to choke ...
I installed GPGTools with all default settings, and from a Terminal window "gpg" is a recognized command, and starts the gpg process from GnuPG.
Suggestions ...?
PS,
Code is exact replica (more or less) of your sample code of how to encrypt message using PGP in a GnuPG subclassed context from your README.md file ...
The text was updated successfully, but these errors were encountered: