You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When we use below java snippet , it works for recipient as email but does not work for any random string.
BouncyGPG
.encryptToStream()
.withConfig(keyringConfig)
.withStrongAlgorithms()
.toRecipient(recipient)
.andDoNotSign()
.armorAsciiOutput()
.andWriteTo(output)
** System (please complete the following information):**
OS: container as Linux
Java : 17
throws exception :"org.bouncycastle.openpgp.PGPException: No (suitable) public key for encryption to 918A6B32 found\n\tat name.neuhalfen.projects.crypto.bouncycastle.openpgp.BuildEncryptionOutputStreamAPI$WithAlgorithmSuiteImpl$ToImpl.extractValidKey(BuildEncryptionOutputStreamAPI.java:414)\n\tat name.neuhalfen.projects.crypto.bouncycastle.openpgp.BuildEncryptionOutputStreamAPI$WithAlgorithmSuiteImpl$ToImpl.toRecipient(BuildEncryptionOutputStreamAPI.java:431.
Where as it works for command line :
gpg --output /tmp/outputfile.txt.pgp --reciepient 918A6B32 --encrypt textfilePath
please let me know if it is issue with bouncy gpg issue ?
thanks for your help. looking forward for reply
The text was updated successfully, but these errors were encountered:
When we use below java snippet , it works for recipient as email but does not work for any random string.
BouncyGPG
.encryptToStream()
.withConfig(keyringConfig)
.withStrongAlgorithms()
.toRecipient(recipient)
.andDoNotSign()
.armorAsciiOutput()
.andWriteTo(output)
** System (please complete the following information):**
throws exception :"org.bouncycastle.openpgp.PGPException: No (suitable) public key for encryption to 918A6B32 found\n\tat name.neuhalfen.projects.crypto.bouncycastle.openpgp.BuildEncryptionOutputStreamAPI$WithAlgorithmSuiteImpl$ToImpl.extractValidKey(BuildEncryptionOutputStreamAPI.java:414)\n\tat name.neuhalfen.projects.crypto.bouncycastle.openpgp.BuildEncryptionOutputStreamAPI$WithAlgorithmSuiteImpl$ToImpl.toRecipient(BuildEncryptionOutputStreamAPI.java:431.
Where as it works for command line :
gpg --output /tmp/outputfile.txt.pgp --reciepient 918A6B32 --encrypt textfilePath
please let me know if it is issue with bouncy gpg issue ?
thanks for your help. looking forward for reply
The text was updated successfully, but these errors were encountered: