java - Fail to gpg-decrypt BouncyCastlePGP-encrypted message -
when try decrypt message using gnupg encrypted bouncycastle 2 gpg: [don't know]: invalid packet (ctb=xx) messages , decryption fails. i using bouncycastle 1.54 , gpg (gnupg) 2.0.30 on osx details 1) pgp key generated using gpg follows: $ gpg --gen-key gpg (gnupg) 2.0.30; copyright (c) 2015 free software foundation, inc. free software: free change , redistribute it. there no warranty, extent permitted law. please select kind of key want: (1) rsa , rsa (default) (2) dsa , elgamal (3) dsa (sign only) (4) rsa (sign only) selection? 1 rsa keys may between 1024 , 4096 bits long. keysize want? (2048) requested keysize 2048 bits please specify how long key should valid. 0 = key not expire <n> = key expires in n days <n>w = key expires in n weeks <n>m = key expires in n months <n>y = key expires in n years key valid for? (0) 0 key not expire @ correct? (y/n) y gnupg needs construct user id identify key. ...