mattosaurus / PgpCore

.NET Core class library for using PGP
MIT License
244 stars 98 forks source link

unknown packet type encountered: 20 #196

Closed ChrisK91 closed 1 year ago

ChrisK91 commented 1 year ago

Hello,

I'm working on a project where I try to decrypt incoming files using a separately provided key file. Using the command line, I can decrypt these files using the gpg command line utility. From my research so far it seems that the key uses AEAD, is there any steps I can take to work around these issues?

Thanks!

mattosaurus commented 1 year ago

Hi, sorry, AEAD isn't supported yet by Bouncy Castle which is the underlying library used by PgpCore.

It looks like there's a PR in progress to add this though it seems to have stalled.

https://github.com/bcgit/bc-csharp/pull/380

patagonaa commented 1 year ago

This PR does not implement AEAD, it only changes how the MAC is calculated when AEAD ciphers are used in TLS connections.

So for TLS, AEAD seems to be supported, I can't tell you if it is supported for PGP decryption though. So if it's actually not implemented for PGP and you need this feature, you could try opening an issue in https://github.com/bcgit/bc-csharp or asking on their mailing list.