Bug 159612 - Digital signing of Writer documents using X.509 compliant signatures fails silently on macOS
Summary: Digital signing of Writer documents using X.509 compliant signatures fails si...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
24.8.0.0 alpha0+ Master
Hardware: ARM All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 160432 (view as bug list)
Depends on:
Blocks: Digital-Signatures
  Show dependency treegraph
 
Reported: 2024-02-07 07:28 UTC by Alex Thurgood
Modified: 2024-04-03 19:06 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Thurgood 2024-02-07 07:28:21 UTC
Description:
1) Create a new Writer document, type some text in it, and save normally.

2) Now try and digitally sign the document with a X.509 compliant digital signature (I have a number of them provided by different providers for work, e.g. the European Patent Office, CertEurope (eIDAS token), World Intellectual Property Organisation.

3) Call up the Certificate Manager from the digital signatures dialog, and select a certificate. This is supposed to digitally sign the Writer document.

4) The user is returned to the document Digital Signaures dialog in which, in the event of a successful signature, the used signature included in the document is displayed in a list and the validity of that signature is indicated.

In my case, that Digital Signature list window has a blank, selectable entry, i.e. you can see that there is supposed to be something in the digital signature list associated with the document, but the detail of what that signature is does not appear. A mouse hover over the blank entry calls the popup help "Lists the digital signatures for the current document."

The document isn't signed at all. There is no change to the status of the document as evidenced by the Save button in the toolbar, and the dialog still shows an active "Sign" and "Start Certificate Manager" buttons. 

If I click on the "Sign" button in this state, I get a repeatable crash, and the recovery dialog is started. 



Steps to Reproduce:
See description above.

Actual Results:
The digital signing functionality fails to work, the Writer document is never signed. Additionally, a reproducible crash can be made to occur by trying to use the "Sign" button in the pseudo-empty list of digital signatures. 

Expected Results:
The digital signing functionality should work with X.509 certs provided by professional organisations.


Reproducible: Always


User Profile Reset: Yes

Additional Info:
Version: 24.8.0.0.alpha0+ (AARCH64) / LibreOffice Community
Build ID: 467eeda66ee444c846fcd89da1fe064dd06daa9d
CPU threads: 8; OS: macOS 14.2.1; UI render: Skia/Raster; VCL: osx
Locale: fr-FR (fr_FR.UTF-8); UI: en-US
Calc: threaded
Comment 1 Alex Thurgood 2024-02-07 07:34:45 UTC
Added link to bug 94903, as it seems that they relate to the same problem, but Miklos preferred them to be separately identified.
Comment 2 Patrick Luby (volunteer) 2024-03-06 13:33:35 UTC
(In reply to Alex Thurgood from comment #1)
> Added link to bug 94903, as it seems that they relate to the same problem,
> but Miklos preferred them to be separately identified.

Although I don't have any X.509 certificates, can you post a recent crash log? I have fixed a few bugs in the Select Certificate dialog and from what you describe, maybe the crash is a failure to check for a null pointer.
Comment 3 Tohotom 2024-03-25 19:24:46 UTC
I can confirm this on KDE Neon, with LibreOffice 24.2, installed form fresh ppa. I can view and select the certificate, but the document is not signed.

Version: 24.2.1.2 (X86_64) / LibreOffice Community
Build ID: 420(Build:2)
CPU threads: 8; OS: Linux 6.5; UI render: default; VCL: kf5 (cairo+xcb)
Locale: hu-HU (en_US.UTF-8); UI: en-US
Ubuntu package version: 4:24.2.1~rc2-0ubuntu0.22.04.1~lo1
Calc: threaded

Os: KDE Neon, Plasma 6.
Comment 4 Alex Thurgood 2024-04-03 15:59:07 UTC
*** Bug 160432 has been marked as a duplicate of this bug. ***