//
// asymmetric
//
PGPObjectFactory pgpF = new PGPObjectFactory(encData);
PGPEncryptedDataList encList = (PGPEncryptedDataList)pgpF.nextObject();
PGPPublicKeyEncryptedData encP = (PGPPublicKeyEncryptedData)encList.get(0);
InputStream clear = encP.getDataStream(pgpPrivKey, "BC");
PGPObjectFactory pgpFact = new PGPObjectFactory(clear);
checkLiteralData((PGPLiteralData)pgpFact.nextObject(), text);
//
// PBE
//
pgpF = new PGPObjectFactory(encData);
encList = (PGPEncryptedDataList)pgpF.nextObject();
PGPPBEEncryptedData encPbe = (PGPPBEEncryptedData)encList.get(1);
clear = encPbe.getDataStream("password".toCharArray(), "BC");
pgpF = new PGPObjectFactory(clear);