Openbravo Issue Tracking System - Openbravo ERP |
View Issue Details |
|
ID | Project | Category | View Status | Date Submitted | Last Update |
0045086 | Openbravo ERP | A. Platform | public | 2020-09-17 18:23 | 2020-11-09 08:11 |
|
Reporter | cberner | |
Assigned To | cberner | |
Priority | normal | Severity | major | Reproducibility | have not tried |
Status | closed | Resolution | fixed | |
Platform | | OS | 5 | OS Version | |
Product Version | | |
Target Version | | Fixed in Version | PR21Q1 | |
Merge Request Status | |
Review Assigned To | |
OBNetwork customer | |
Web browser | |
Modules | Core |
Support ticket | |
Regression level | |
Regression date | |
Regression introduced in release | |
Regression introduced by commit | |
Triggers an Emergency Pack | No |
|
Summary | 0045086: Remove Apache Tika library with already existing Java 7+ functionality |
Description | Apache tika-core 0.9 library is not needed, as Java 7+ alternative already exists in the jdk. It is currently used to handle MIME detection based on file/byte content for images and attachments.
Java 7, introduced a functionality that, although a bit more limited, allows to do the same MIME detection. As such, tika-core library should be removed and usage of it should change to the Java 7 "URLConnection.guessContentTypeFromStream" functionality. |
Steps To Reproduce | In description |
Proposed Solution | Remove tika-core library and change all usage to URLConnection.guessContentTypeFromStream. |
Additional Information | |
Tags | No tags attached. |
Relationships | related to | defect | 0012057 | 2.50MP14 | closed | iperdomo | ShowImage servlet should include mime types in the header | causes | defect | 0045388 | | closed | cberner | API Change: Remove a couple of methods from MimeTypeUtil class | causes | defect | 0049062 | | closed | cberner | JIRA 2879 - Backoffice - can't import a bmp file |
|
Attached Files | |
|
Issue History |
Date Modified | Username | Field | Change |
2020-09-17 18:23 | cberner | New Issue | |
2020-09-17 18:23 | cberner | Assigned To | => cberner |
2020-09-17 18:23 | cberner | Modules | => Core |
2020-09-17 18:23 | cberner | Triggers an Emergency Pack | => No |
2020-09-17 18:31 | hgbot | Note Added: 0123193 | |
2020-09-18 10:18 | hgbot | Note Added: 0123200 | |
2020-09-18 10:25 | cberner | Summary | Remove Apache Tika library because of critical vulnerability => Remove Apache Tika library with already existing Java 7+ functionality |
2020-09-18 10:25 | cberner | Description Updated | bug_revision_view_page.php?rev_id=21706#r21706 |
2020-11-06 07:42 | alostale | Relationship added | related to 0012057 |
2020-11-06 09:34 | cberner | Relationship added | causes 0045388 |
2020-11-06 10:25 | hgbot | Resolution | open => fixed |
2020-11-06 10:25 | hgbot | Status | new => closed |
2020-11-06 10:25 | hgbot | Fixed in Version | => PR21Q1 |
2020-11-06 10:25 | hgbot | Note Added: 0124209 | |
2020-11-06 10:25 | hgbot | Note Added: 0124210 | |
2020-11-06 10:25 | hgbot | Note Added: 0124213 | |
2020-11-06 10:25 | hgbot | Note Added: 0124214 | |
2020-11-06 11:30 | hgbot | Note Added: 0124216 | |
2020-11-06 14:51 | hgbot | Note Added: 0124221 | |
2020-11-09 08:11 | hgbot | Note Added: 0124236 | |
2020-11-09 08:11 | hgbot | Note Added: 0124237 | |
2022-04-20 15:56 | alostale | Relationship added | causes 0049062 |
Notes |
|
(0123193)
|
hgbot
|
2020-09-17 18:31
|
|
|
|
(0123200)
|
hgbot
|
2020-09-18 10:18
|
|
|
|
(0124209)
|
hgbot
|
2020-11-06 10:25
|
|
Directly closing issue as related merge request is already approved.
Repository: https://gitlab.com/openbravo/product/openbravo [^]
Changeset: 2d1e219013bf482f68d4c6809f367dcad8f28e7d
Author: Cristian Berner <cristian.berner@openbravo.com>
Date: 2020-11-06T09:25:33+00:00
URL: https://gitlab.com/openbravo/product/openbravo/-/commit/2d1e219013bf482f68d4c6809f367dcad8f28e7d [^]
Fixes ISSUE-45086: Remove tika-core library and use Java7 functionality instead
tika-core 0.9 has some critical vulnerabilities, it is removed and
substituted by Java 7 guessContentTypeFromStream functionality, that
has the same behaviour, althought is a bit more limited in the list of
MIME types available.
svg files were not detectable using URLConnection.guessContentType API,
as an alternative xml is extracted from the File being checked and if
the root element is svg, then it is assumed that the xml is an SVG.
---
M legal/Licensing.txt
M modules/org.openbravo.client.application/src/org/openbravo/client/application/attachment/AttachImplementationManager.java
M src-test/src/org/openbravo/test/mimetypes/MimeTypeTest.java
M src-util/modulescript/build/classes/org/openbravo/modulescript/ConvertImages.class
M src-util/modulescript/src/org/openbravo/modulescript/ConvertImages.java
M src/org/openbravo/dal/xml/XMLUtil.java
M src/org/openbravo/erpCommon/info/ImageInfoBLOB.java
M src/org/openbravo/erpCommon/utility/MimeTypeUtil.java
R lib/runtime/tika-core-0.9.jar
---
|
|
|
(0124210)
|
hgbot
|
2020-11-06 10:25
|
|
|
|
(0124213)
|
hgbot
|
2020-11-06 10:25
|
|
|
|
(0124214)
|
hgbot
|
2020-11-06 10:25
|
|
|
|
(0124216)
|
hgbot
|
2020-11-06 11:30
|
|
|
|
(0124221)
|
hgbot
|
2020-11-06 14:51
|
|
|
|
(0124236)
|
hgbot
|
2020-11-09 08:11
|
|
|
|
(0124237)
|
hgbot
|
2020-11-09 08:11
|
|
|