You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Tilman Hausherr (Jira)" <ji...@apache.org> on 2020/11/25 18:57:00 UTC

[jira] [Commented] (PDFBOX-5027) Protect/Encrypt PDF with multiple certificates on command line

    [ https://issues.apache.org/jira/browse/PDFBOX-5027?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17238870#comment-17238870 ] 

Tilman Hausherr commented on PDFBOX-5027:
-----------------------------------------

Or we could repeat {{-certFile <path to cert>}}

However I remember that it doesn't work at all. So I tried, and got this: "JCE cannot authenticate the provider BC".
https://stackoverflow.com/questions/13721579/

> Protect/Encrypt PDF with multiple certificates on command line
> --------------------------------------------------------------
>
>                 Key: PDFBOX-5027
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-5027
>             Project: PDFBox
>          Issue Type: Improvement
>          Components: Crypto
>    Affects Versions: 3.0.3 JBIG2
>            Reporter: jakatal
>            Priority: Trivial
>   Original Estimate: 6h
>  Remaining Estimate: 6h
>
> Hi,
> PDFBox has (obviously) the ability to protect a file with several certificates by adding teh recipient's certificates one after another:
>  
>  
> {code:java}
> //Class PublicKeyProtectionPolicy has 
> public void addRecipient(PublicKeyRecipient recipient)
>     {        recipients.add(recipient);    }
> {code}
> For the commandline tool functionality, it just offers "-cert" with the option to add a SINGLE certificate. I expect that in most serious use cases actually two certificates are used to protect the document (the actual recipient and the creator who wants to be able still to open the document as well).
>  
> I propose to extend the command line functionality (Encrypt.java) by having an iteration through several cert files, e.g. separated by special character.
>  
> Thanks.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: dev-help@pdfbox.apache.org