Bug 415199 - Okular doesn't show digital signatures without visible component
Summary: Okular doesn't show digital signatures without visible component
Status: RESOLVED FIXED
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: 1.9.0
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-12-15 12:47 UTC by Nemanja Hirsl
Modified: 2020-05-13 22:07 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
test file 1 (230.85 KB, application/pdf)
2019-12-15 12:47 UTC, Nemanja Hirsl
Details
test file 2 (788.01 KB, application/pdf)
2019-12-15 12:47 UTC, Nemanja Hirsl
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nemanja Hirsl 2019-12-15 12:47:24 UTC
Created attachment 124504 [details]
test file 1

SUMMARY
Okular doesn't recognize digital signatures without visible component (visible signature)
It is possible to sign PDF without visible signature and Okular can't handle that properly
STEPS TO REPRODUCE
1. Open digitally signed PDF (make sure there are signatures w/o visible component)

OBSERVED RESULT
1. If there's at least one digital signature with visible component Okular will show it and will omit all others
2. If none of digital signatures has visible component Okular won't show notification that PDF is signed


EXPECTED RESULT
1. All digital signatures regardless of visible component should be recognized by Okular

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma:  OpenSuse (Tumbleweed), Manjaro
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: Qt 5.13.1

ADDITIONAL INFORMATION
Two attached documents:
1. Contract.pdf - 3 digital signatures, none of them with visible component
2. The Scrum Guide - 3 digital signatures, 2 with visible component
Comment 1 Nemanja Hirsl 2019-12-15 12:47:51 UTC
Created attachment 124505 [details]
test file 2
Comment 2 Albert Astals Cid 2020-03-16 22:33:30 UTC
This is actually a bug in poppler

Can you please report it here?

https://gitlab.freedesktop.org/poppler/poppler/issues

You can check it by running pdfsig on those file and seeing that it reports the same signatures Okular does.
Comment 3 Nemanja Hirsl 2020-03-22 11:26:51 UTC
Created issue: https://gitlab.freedesktop.org/poppler/poppler/issues/895
Comment 4 Albert Astals Cid 2020-04-23 20:48:17 UTC
Sadly the fix in poppler required new API so that means we also need to change Okular :(
Comment 5 Albert Astals Cid 2020-04-29 22:44:42 UTC
https://invent.kde.org/kde/okular/-/merge_requests/161
Comment 6 Albert Astals Cid 2020-05-13 22:07:28 UTC
Git commit 4b1d85f81bf0df1fdfc86e74ad71e9cf8201092f by Albert Astals Cid.
Committed on 13/05/2020 at 21:21.
Pushed by aacid into branch 'master'.

Show signatures that don't belong to any page in the signature panel

Needs poppler 0.88, we "pretend" the belong to page 0 since in Okular
core there's no concept of having a signature that doesn't belong to any
page

M  +10   -0    generators/poppler/CMakeLists.txt
M  +3    -0    generators/poppler/config-okular-poppler.h.cmake
M  +58   -4    generators/poppler/generator_pdf.cpp
M  +2    -2    generators/poppler/generator_pdf.h

https://invent.kde.org/kde/okular/commit/4b1d85f81bf0df1fdfc86e74ad71e9cf8201092f