Bug 159381

Summary: TimeStamp(RFC3161) create problem by asn1 format error.
Product: LibreOffice Reporter: ishizuka
Component: Printing and PDF exportAssignee: Not Assigned <libreoffice-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: michael.stahl
Priority: medium    
Version: 7.6.4.1 release   
Hardware: All   
OS: All   
Whiteboard: target:24.8.0 target:24.2.1
Crash report or crash signature: Regression By:

Description ishizuka 2024-01-26 09:21:51 UTC
Description:
svl/source/crypto/cryptosign.cxx

boolean: certReq value is not good.(0x01)

TRUE in the ASN1 DER encoded boolean is only 0xff, not 0x01.
Therefore, while it can be recognized by openssl, it may not be available in other implementations.

Please change it to respond 0xff in accordance with the ASN1.

Actual Results:
0x01

Expected Results:
0xff


Reproducible: Always


User Profile Reset: Yes

Additional Info:
There is a similar discussion in golang here. 
https://github.com/golang/go/issues/11091
Comment 1 ishizuka 2024-01-26 10:45:07 UTC
Since openssl 1.1 & openssl3.0 seem to recognize 0x01 as false, 0x00 may have less impact.
Comment 2 Commit Notification 2024-01-27 16:44:47 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/d2d8f8bf82558d9aa548fb9f13bed410e0baf79b

tdf#159381 TimeStamp(RFC3161) create problem by asn1 format error.

It will be available in 24.8.0.

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

Affected users are encouraged to test the fix and report feedback.
Comment 3 Commit Notification 2024-01-27 21:48:16 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "libreoffice-24-2":

https://git.libreoffice.org/core/commit/42e06fb686d4c02fc6efaf0a792319147e3d62bf

tdf#159381 TimeStamp(RFC3161) create problem by asn1 format error.

It will be available in 24.2.1.

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

Affected users are encouraged to test the fix and report feedback.
Comment 4 ishizuka 2024-01-29 07:16:06 UTC
I have verified that the following two versions work properly. Thank you for your prompt correction.

- LibreOfficeDev_24.8.0.0.alpha0_MacOS_x86-64.dmg 2024-Jan-29 01:55
- LibreOfficeDev_24.2.1.0.0_MacOS_x86-64.dmg          2024-Jan-28 03:14