Decrypting A Encrypted PDF

PDDocument source = PDDocument.load(new ByteArrayInputStream(bytes));

try {
if (source.isEncrypted()) {
source.decrypt("");
source.setAllSecurityToBeRemoved(true);
}
} catch (Exception e) {
logger.info("Error During PDF  Decryption ");
}

Comments

Popular posts from this blog

CSM Quiz -2

Enabling WL-Proxy-SSL HTTP header in WebLogic

CSM Quiz -1