[jira] [Closed] (FOP-2844) FOP ignores encryption parameters except when you enter the full set
"Joao Goncalves (Jira)" <[email protected]> Wed, 17 Jun 2026 20:13:00 +0000 (UTC)
| Newsgroups | gmane.text.xml.fop.devel |
|---|---|
| Message-ID | <[email protected]> |
[ https://issues.apache.org/jira/browse/FOP-2844?page=3Dcom.atlassian.=
jira.plugin.system.issuetabpanels:all-tabpanel ]
Joao Goncalves closed FOP-2844.
-------------------------------
Resolution: Not A Problem
> FOP ignores encryption parameters except when you enter the full set
> --------------------------------------------------------------------
>
> Key: FOP-2844
> URL: https://issues.apache.org/jira/browse/FOP-2844
> Project: FOP
> Issue Type: Bug
> Affects Versions: 2.3
> Environment: MacOS 10.14.2, not tested on other systems=20
> Reporter: Patricia Piolon
> Assignee: Joao Goncalves
> Priority: Major
> Attachments: image-2026-05-26-17-12-47-095.png
>
>
> It looks like FOPs encryption parameters don't work as one would expect.
> (I am providing configuration options below, but *the same is true for co=
mmand line options*)
> They only work when providing the full set of options:
> <encryption-params>
> =C2=A0=C2=A0=C2=A0=C2=A0 <encryption-length>128</encryption-length>
> =C2=A0=C2=A0=C2=A0=C2=A0 <user-password>testuserpass</user-password>
> =C2=A0=C2=A0=C2=A0=C2=A0 <owner-password>testownerpass</owner-password>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noprint/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <nocopy/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noedit/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noannotations/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <nofillinforms/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noaccesscontent/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noassembledoc/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noprinthq/>
> =C2=A0 </encryption-params>
> the above gives a fully restricted pdf, but this:
> <encryption-params>
> =C2=A0=C2=A0=C2=A0=C2=A0 <encryption-length>128</encryption-length>
> =C2=A0=C2=A0=C2=A0=C2=A0 <user-password>testuserpass</user-password>
> =C2=A0=C2=A0=C2=A0=C2=A0 <owner-password>testownerpass</owner-password>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noprint/>
> =C2=A0 </encryption-params>
> does *not* result in a pdf where printing is disallowed but e.g. annotati=
ng is. The no-printing option is not set in this case.
> The only elements/options that can be left out are the user and owner pas=
swords.
> So this works:
> <encryption-params>
> =C2=A0=C2=A0=C2=A0=C2=A0 <encryption-length>128</encryption-length>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noprint/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <nocopy/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noedit/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noannotations/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <nofillinforms/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noaccesscontent/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noassembledoc/>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noprinthq/>
> =C2=A0 </encryption-params>
> But this does not:
> <encryption-params>
> =C2=A0=C2=A0=C2=A0=C2=A0 <encryption-length>128</encryption-length>
> =C2=A0=C2=A0=C2=A0=C2=A0 <noprint/>
> =C2=A0 </encryption-params>
> =C2=A0
> Additionally it is not possible to only set the list of <no*/> encryption=
options in the configuration and then set the user and/or owner password a=
t runtime - in this case the passwords are ignored.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)