Bug 84121 - PDF import: no images when password protected
Summary: PDF import: no images when password protected
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
4.2.6.2 release
Hardware: Other Linux (All)
: high major
Assignee: Caolán McNamara
URL:
Whiteboard: BSA target:5.3.0 target:5.2.1
Keywords: bibisected, bisected, regression
Depends on:
Blocks: PDF-Import-Draw
  Show dependency treegraph
 
Reported: 2014-09-20 14:14 UTC by James Van Damme
Modified: 2016-08-02 15:20 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Test file, password is "password". Opens fine in evince, can't open (encrypted) in Draw. (231.90 KB, application/pdf)
2014-10-10 01:47 UTC, James Van Damme
Details
PDF permissions from Acrobat Reader XI (29.51 KB, image/png)
2016-05-10 13:04 UTC, Heiko Tietze
Details

Note You need to log in before you can comment on or make changes to this bug.
Description James Van Damme 2014-09-20 14:14:03 UTC
When I import a password protected PDF, the images are not opened but replaced by a frame. Non-passworded file imports with the image. Passworded file opens with the image in Evince. 

              
Operating System: Linux (Other)
Version: 4.2.6.2 release
Comment 1 tommy27 2014-09-29 19:32:23 UTC
please upload a test file
Comment 2 James Van Damme 2014-10-10 01:47:24 UTC
Created attachment 107635 [details]
Test file, password is "password". Opens fine in evince, can't open (encrypted) in Draw.

I could open PDFs before but the images were replaced by an empty frame. This one won't open at all. Evince opens it fine after I put in the password.
Comment 3 Robinson Tryon (qubit) 2014-10-10 03:17:21 UTC
(In reply to James Van Damme from comment #2)
> Created attachment 107635 [details]
> Test file, password is "password". Opens fine in evince, can't open
> (encrypted) in Draw.

TESTING on Ubuntu 14.04.

With the password provided, file opens fine in FF 32.0.3 and Evince 3.10.3.

File does NOT open in LibreOffice 4.3.2.2, even after entering correct password. No text or image is visible.

Thanks for the bug report!

Status -> NEW
Comment 4 Robinson Tryon (qubit) 2014-10-10 03:50:13 UTC
File opens fine (Text + Image) with LO 4.1.2.2 + Ubuntu 14.04.

Marking as a regression.
Comment 5 Xisco Faulí 2014-10-23 09:40:08 UTC
bibisected:
 55ecbc9a293276f2506a41e364da2331b22535ab is the first bad commit
commit 55ecbc9a293276f2506a41e364da2331b22535ab
Author: Bjoern Michaelsen <bjoern.michaelsen@canonical.com>
Date:   Thu Oct 17 16:50:06 2013 +0000

    source-hash-b1f7dd66b898b03cb4bd8d434b6370310ea95946
    
    commit b1f7dd66b898b03cb4bd8d434b6370310ea95946
    Author:     Fridrich Štrba <fridrich.strba@bluewin.ch>
    AuthorDate: Mon Jul 8 19:07:55 2013 +0200
    Commit:     Fridrich Štrba <fridrich.strba@bluewin.ch>
    CommitDate: Mon Jul 8 19:08:37 2013 +0200
    
        Use a real name of the library
    
        Change-Id: I5f9ec12b507e332d304b931ddb31103ee3f0766d

:100644 100644 2453a385e152e0cdd1050935445b4d4eb51fd135 e10397005b24d777f96736399a8894d9d86d4b3f M	ccache.log
:100644 100644 9c6fb08ec2569d26e1f9c0d6f8d2f5dbda2494a9 214046467ff20f8f93675ec1617e5695a43b1ef7 M	commitmsg
:100644 100644 bb9b4796ae6e1dc88fa01e55e1d86da1519c30db 731af927fdf5e1ba24689e9fe4f8bd81a650c310 M	dev-install.log
:100644 100644 1c711ff8ed8c46f5350d26cd6d7dcbb3699ded22 a182eaffd84ef341133216dea5d2f402b9a56789 M	make.log
:040000 040000 12e90c21e9922ff3e9f76387f19cc1a287a522db f8d793e97e2d282b48f2d72d2153da46411bea86 M	opt

# bad: [423a84c4f7068853974887d98442bc2a2d0cc91b] source-hash-c15927f20d4727c3b8de68497b6949e72f9e6e9e
# good: [65fd30f5cb4cdd37995a33420ed8273c0a29bf00] source-hash-d6cde02dbce8c28c6af836e2dc1120f8a6ef9932
git bisect start 'latest' 'oldest'
# good: [e02439a3d6297a1f5334fa558ddec5ef4212c574] source-hash-6b8393474974d2af7a2cb3c47b3d5c081b550bdb
git bisect good e02439a3d6297a1f5334fa558ddec5ef4212c574
# bad: [4850941efe43ae800be5c76e1102ab80ac2c085d] source-hash-980a6e552502f02f12c15bfb1c9f8e6269499f4b
git bisect bad 4850941efe43ae800be5c76e1102ab80ac2c085d
# skip: [a043626b542eb8314218d7439534dce2fc325304] source-hash-9379a922c07df3cdb7d567cc88dfaaa39ead3681
git bisect skip a043626b542eb8314218d7439534dce2fc325304
# skip: [aba65c3e4c0df07e4909aeefb758cdb688242bf6] source-hash-827524abfb4b577d08276fde40929a9adfb7ff1a
git bisect skip aba65c3e4c0df07e4909aeefb758cdb688242bf6
# skip: [aba65c3e4c0df07e4909aeefb758cdb688242bf6] source-hash-827524abfb4b577d08276fde40929a9adfb7ff1a
git bisect skip aba65c3e4c0df07e4909aeefb758cdb688242bf6
# bad: [c81a8a0dcfc1ed095a80e4485c89dd0fcaf73f31] source-hash-c69ed33628ec0b7abf6296539cf280d6c4265930
git bisect bad c81a8a0dcfc1ed095a80e4485c89dd0fcaf73f31
# bad: [c81a8a0dcfc1ed095a80e4485c89dd0fcaf73f31] source-hash-c69ed33628ec0b7abf6296539cf280d6c4265930
git bisect bad c81a8a0dcfc1ed095a80e4485c89dd0fcaf73f31
# bad: [1d4980621741d3050a5fe61b247c157d769988f2] source-hash-89d01a7d8028ddb765e02c116d202a2435894217
git bisect bad 1d4980621741d3050a5fe61b247c157d769988f2
# bad: [ba096f438393091574da98fe7b8e6b05182a8971] source-hash-8499e78ca03c792f4fa2650e02b519094ba0baa8
git bisect bad ba096f438393091574da98fe7b8e6b05182a8971
# good: [9daa289e178460daaafa4b3911031df5b8736218] source-hash-704292996a3731a61339b1a4a5c90c9403aa095f
git bisect good 9daa289e178460daaafa4b3911031df5b8736218
# bad: [34eab3946c46bb7273ba4ca395db9c4421dd232f] source-hash-e962805b31074d6b6a2ed0db6452769448337553
git bisect bad 34eab3946c46bb7273ba4ca395db9c4421dd232f
# good: [7f958321368b190c941b23cc219d62d0420415af] source-hash-b3f41543851e9985c6c7ba133c32753c9bc732c1
git bisect good 7f958321368b190c941b23cc219d62d0420415af
# bad: [3bffe99b15f359bb4c6941210623dcd0763987c9] source-hash-6768d2c7f2cf75c507ec2108cbbb5a8a6cf7fae9
git bisect bad 3bffe99b15f359bb4c6941210623dcd0763987c9
# bad: [55ecbc9a293276f2506a41e364da2331b22535ab] source-hash-b1f7dd66b898b03cb4bd8d434b6370310ea95946
git bisect bad 55ecbc9a293276f2506a41e364da2331b22535ab
# first bad commit: [55ecbc9a293276f2506a41e364da2331b22535ab] source-hash-b1f7dd66b898b03cb4bd8d434b6370310ea95946
Comment 6 Matthew Francis 2014-12-29 15:02:25 UTC
The behaviour changed as of the below commit

Adding Cc: to fridrich.strba@bluewin.ch. Could you possibly take a look at this? Thanks


commit eb276d11a652601f743d69ada7a38016bd97d73e
Author: Fridrich Štrba <fridrich.strba@bluewin.ch>
Date:   Mon Jul 8 14:01:17 2013 +0200

    fdo#38878: Upgrading internal xpdf -> poppler
    
    Change-Id: I00aafb3fd275e6be3b5d0eb370320e5325110da5
    Reviewed-on: https://gerrit.libreoffice.org/4770
    Tested-by: Fridrich Strba <fridrich@documentfoundation.org>
    Reviewed-by: Fridrich Strba <fridrich@documentfoundation.org>
Comment 7 Robinson Tryon (qubit) 2015-12-13 11:16:12 UTC Comment hidden (obsolete)
Comment 8 Heiko Tietze 2016-05-10 13:04:10 UTC
confirmed 

The file cannot be opened without password (cancel results in "General Error", wrong pw in "The password is incorrect. The file cannot be opened." and back to the input, see also 49697), and with pw it shows "This PDF file is encrypted and can't be opened." inline. 
BTW, The pw dialog says "Enter pw to open file \n <A123.tmp>"

Version: 5.2.0.0.alpha0+
Build ID: 6b232aeecc55f1715bc111e636e36a8e24827efb
CPU Threads: 4; OS Version: Windows 6.1; UI Render: default; 
TinderBox: Win-x86@39, Branch:master, Time: 2016-01-26_07:40:04
Locale: de-DE (de_DE)
Comment 9 Heiko Tietze 2016-05-10 13:04:58 UTC
Created attachment 124954 [details]
PDF permissions from Acrobat Reader XI
Comment 10 Commit Notification 2016-07-29 09:02:28 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=2a66c02553bbcfbb9e646c39ec291fb2eefbf6bb

Resolves: tdf#84121 wrong password passed to xpdfimport

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 11 Commit Notification 2016-08-02 15:20:29 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=25ebe8a3803d260671dac7225aaecd25be88bc4e&h=libreoffice-5-2

Resolves: tdf#84121 wrong password passed to xpdfimport

It will be available in 5.2.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.