Bug 136292 - Additions: Bad JSON crashes LibreOffice
Summary: Additions: Bad JSON crashes LibreOffice
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: UI (show other bugs)
Version:
(earliest affected)
7.1.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Muhammet Kara
URL:
Whiteboard: target:7.2.0 target:7.1.5 target:7.1.4
Keywords:
Depends on:
Blocks: Extension-Tight-Integration
  Show dependency treegraph
 
Reported: 2020-08-30 15:00 UTC by Muhammet Kara
Modified: 2021-08-19 09:13 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 Muhammet Kara 2020-08-30 15:00:11 UTC
When there is an error in the downloaded list of extensions as JSON, it might cause a crash of LibreOffice.

An example error seen on terminal on such a crash:

terminate called after throwing an instance of 'orcus::json::parse_error'
  what():  string: illegal escape character 'u'. (offset=204406)

Seems like we need some try-catches, and extra checks.
Comment 1 Xisco Faulí 2021-02-09 14:14:49 UTC
Dear Yusuf Keten,
This bug has been in ASSIGNED status for more than 3 months without any
activity. Resetting it to NEW.
Please assign it back to yourself if you're still working on this.
Comment 2 Commit Notification 2021-05-30 05:12:03 UTC
Muhammet Kara committed a patch related to this issue.
It has been pushed to "master":

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

tdf#136292: Fix crash on invalid JSON from the extensions API

It will be available in 7.2.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 2021-05-31 07:18:48 UTC
Muhammet Kara committed a patch related to this issue.
It has been pushed to "libreoffice-7-1":

https://git.libreoffice.org/core/commit/9a9089d0f7c205ed6428e55fb86062c715483a4b

tdf#136292: Fix crash on invalid JSON from the extensions API

It will be available in 7.1.5.

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 Commit Notification 2021-06-01 07:50:14 UTC
Muhammet Kara committed a patch related to this issue.
It has been pushed to "libreoffice-7-1-4":

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

tdf#136292: Fix crash on invalid JSON from the extensions API

It will be available in 7.1.4.

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 5 Rober James 2021-07-30 03:56:32 UTC Comment hidden (spam)
Comment 6 Madison Wilson 2021-08-18 05:50:51 UTC Comment hidden (spam)