USA and Canada: 866.253.7568   International: +1-501-313-0397
DidiSoft Ltd.

Archive for the 'Java PGP' Category

premature end of stream in PartialInputStream

June 9th, 2014

The latest release of DidiSoft OpenPGP Library for .NET (1.7.9.14) and OpenPGP Library for Java (2.6.6.3) ship with bug fix for the error “premature end of stream in PartialInputStream“. The error “premature end of stream in PartialInputStream” may be observed when trying to decrypt .pgp data with wrong internal length indicators , usually when the encrypted content […]

Using OpenPGP without unlimited JCE policy files

February 4th, 2014

NOTE: This article is Obsolete As of version 3.0 DidiSoft OpenPGP Library for Java doesn’t need the Unlimited JCE policy files in order to provide full OpenPGP cryptography support! The default setup of the Java virtual machine (either JDK or JRE) limits some of the ciphers to a certain key strength. The main reason for […]

What’s the difference between Elliptic Curve OpenPGP keys and AES-256

June 27th, 2013

With the new extension of the OpenPGP Standard that provides support for Elliptic Curve OpenPGP keys we have received a question from one of our customers asking what is the difference between AES-256 and the new ECC OpenPGP keys? Short answer The short answer is that the Elliptic Curve cryptography (ECC) OpenPGP keys are asymmetric keys […]

InvocationTargetException in WebMethods

February 19th, 2013

If you are using DidiSoft OpenPGP Library for Java in a  Software AG WebMethods project you may encounter strange exceptions like: java.lang.reflect.InvocationTargetException:org.bouncycastle.util.Arrays.constantTimeAreEqual The reason for such exceptions is that WebMethods ships with an older version of the BouncyCastle jar files and a class loading mismatch occurs. The resolution is to remove the default BouncyCastle jar files […]

Migration guide from version 2.5.x to version 2.6

October 9th, 2012

As of version 2.6.0 the plain encrypt methods (PGPLib.encrypt…) throw java.io.IOException in addition to com.didisoft.pgp.PGPException. In order to migrate from version 2.5 you will also have to catch java.io.IOException into an additional catch clause. Methods affected: PGPLib.encryptStream PGPLib.encryptFile PGPLib.encryptStreamPBE PGPLib.encryptFilePBE

Unknown KeySpec type ElGamalPrivateKeySpec

October 21st, 2011

Some customers that have deployed DidiSoft OpenPGP Library for Java as part of a web application, have noticed that the exception below is thrown when they perform a hot deploy on the application server: org.bouncycastle.openpgp.PGPException: Exception constructing key    at org.bouncycastle.openpgp.PGPSecretKey.extractPrivateKey(Unknown Source)    at org.bouncycastle.openpgp.PGPSecretKey.extractPrivateKey(Unknown Source) … Caused by: java.security.spec.InvalidKeySpecException: Unknown KeySpec type: org.bouncycastle.jce.spec.ElGamalPrivateKeySpec    […]

unknown object in stream 9

September 26th, 2011

This exception is equivalent to unknown object in stream SymmetricKeyEncrypted. Usually occurs when we try to decrypt a conventionally OpenPGP encrypted file (also known as password encrypted or PBE) that was created with PGP 2.x or McAfee E-Business Server 7.x. This issue has been addressed in OpenPGP Library for Java version 2.5.6 and upper and […]

McAfee EBusiness Server 7.1 error -11391

August 15th, 2011

If you encrypt data for recipients that use McAfee EBusiness Server 7.1 you may receive complaints that they cannot decrypt the file. Below is a common log if the other party uses info level VERBOSE (with command line parameter –info VERBOSE or in the pgp.cfg file): Enter pass phrase: event 23: Decryption symmetric cipher used: […]

Deploy OpenPGP Library for Java executable JAR

July 29th, 2011

If you wish to deploy a single executable JAR application that embeds DidiSoft OpenPGP Library for Java (and the BouncyCastle jars as well) the only solution is to embed (package) the three jars of the library within the final executable JAR application. The reason for this is that the BouncyCastle java security provider must be […]

unknown object in stream SymmetricKeyEncrypted

July 26th, 2011

Sometimes if you try to decrypt an OpenPGP encrypted file you may encounter an IO exception with message ” unknown object in stream SymmetricKeyEncrypted“. After an investigation, we found that such an exception is thrown when we try to decrypt a password based encrypted file (also known as conventional encrypted or PBE) created with PGP version […]