Jump to content
Changes to the Jaspersoft community edition download ×

pdf permission


Recommended Posts



I'm using jasperreports for generate pdf files and I want to secure them.

I try this code :


pdfExporter.setParameter(JRPdfExporterParameter.IS_ENCRYPTED, Boolean.TRUE);
pdfExporter.setParameter(JRPdfExporterParameter.IS_128_BIT_KEY, Boolean.TRUE);
pdfExporter.setParameter(JRPdfExporterParameter.USER_PASSWORD, null);
pdfExporter.setParameter(JRPdfExporterParameter.OWNER_PASSWORD, "reports"«»);
new Integer(PdfWriter.AllowPrinting)


But I want to assign differents permissions for user and owner. The user can only view and print the file and the owner can modify it, and I don't know when and how the owner gives it password.


If someone can help me ...




Post edited by: so007, at: 2007/12/07 13:22

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic



You can get more details about PDF encryption if you ask the iText community. In the JR exporter to PDF we simply rely on what iText offers for encryption and delegate all to it.

If what you want is possible with iText, it is surely possible from JR too.


I hope this helps.


Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...