1124 Commits
Author SHA1 Message Date
Jacques Le Roux df98889c7b Improved: Data of tenant specific component gets loaded in all instances (OFBIZ-6065)
Improves the information provided about importing and loadAll Gradle task
loadTenant Gradle task should be used when necessary
2022-07-28 09:40:28 +02:00
Jacques Le Roux 9351b641e8 Improved: Data of tenant specific component gets loaded in all instances (OFBIZ-6065)
The tenant relevant Gradle tasks are:

OFBiz Server tasks
------------------
createTenant - Create a new tenant in your environment
loadAdminUserLogin - Create admin user with temporary password equal to ofbiz.
You must provide userLoginId
loadAll - Load default data; meant for OFBiz development, testing, and demo
purposes
loadTenant - Load data using tenantId

loadAll is the new "ant load-data" and should clearly only used for
"OFBiz development, testing, and demo purposes".

Remains the import functionalities. We don't want to get to far with that,
a warning is enough.

Thanks: Pierre Smits for report
2022-07-27 16:20:55 +02:00
Michael Brohl 20ccb4dcfd Improved: Make loading of data containing urls configurable
(OFBIZ-12670)

Introduces a SystemProperty security#security.datafile.loadurls.enable
which can be set to true to allow loading of urls in the XML import.
2022-07-21 15:14:58 +02:00
Jacques Le Roux b94b6aecaf Fixed: Webtools Service Logs ‘Service Name’ column always empty (OFBIZ-12625)
rs.getModelService().getName() should be used
instead of
rs.getModelService().name

The rest of changes is only non functional formatting and such

Thanks: Emad Radwan for reporting
2022-05-26 11:27:55 +02:00
Jacques Le Roux 6cb9b12df1 Fixed: Trivial change in ProgramExport.groovy, uses the SecuredUpload import
No Functional change
2022-02-23 11:59:41 +01:00
Benjamin Jugl f3a9f05a30 Improved: Remove Whitespaces before checkboxes (OFBIZ-10461) 2022-02-22 18:58:23 +01:00
Jacques Le Roux 887515beef Improved: no functional change, adds a logerror in ProgramExport.groovy
For a reason I did not find, this morning I did not receive any error message in
UI when the Groovy Program content was rejected for security reason.
So I added a logerror  message to be sure something will be reported in case
this issue popup again.

BTW I switched to 22.01 branch and it was OK, then back to trunk it was OK again,
weird :/
2022-02-15 14:11:33 +01:00
Jacques Le Roux f2cf262cf5 Fixed: Remote Code Execution (File Upload) Vulnerability (OFBIZ-11948)
This fixes and improves file upload.

Refactor a bit SecuredUpload class and fixes:
Prevent double extensions
Check extensions
Improves getMimeTypeFromFileName() by checking is file exists
In isValidImageFile() finally use isValidText() bypassing encoding

Completely refactor deniedWebShellTokens in security.properties by re-adding
removed tokens in last commit and adding several new ones. I have still to check
encoded, encrypted and obfuscated webshells)
Modifies SecurityUtilTest::webShellTokensTesting accordingly
While at it better format commonsImagingSupportedFormats, deniedFileExtensions
and imagejSupportedFormats properties for legibility.

Check if createAnonFile service is used in GroovyBaseScript.groovy and if a
complete file name is used (file exist) check, using SecuredUpload, extensions
and prevent double extensions, actually check all the file and stop there.

Adds some "Check if a webshell is not uploaded" comments in
ContentManagementServices.java
DataServices.java
ScaleImage.java
FrameImage.java
ImageManagementServices.java
ProductServices.java
HttpRequestFileUpload.java
ProgramExport.groovy

Trivial comments fixes in catalog.properties

Also fixes OFBIZ 12571 (I use here a space because of pending INFRA 22843)
by simply adding processbuilder to deniedWebShellTokens
2022-02-10 14:17:34 +01:00
Pierre Smits f1c9e0ef03 Improved: List and Grid (OFBIZ-11345) (#460)
* Improved: List and Grid (OFBIZ-11345)
According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.
Modified:
EntityForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
EntityScreens.xml: from form ref to grid ref , additional cleanup
EntitySyncForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
EntitySyncScreens.xml: from form ref to grid ref , additional cleanup
GeoManagementForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
GeoManagementScreens.xml: from form ref to grid ref , additional cleanup
ServiceForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
ServiceScreens.xml: from form ref to grid ref , additional cleanup
LogScreens.xml: from form ref to grid ref , additional cleanup

modified: ServiceScreens.xml
missed from form ref to grid ref in FindJobManagerLock
2022-01-21 13:36:20 +01:00
Jacques Le Roux 4de3a37c54 Improved: Fix some bugs Spotbugs reports (OFBIZ-12386)
In ProposedOrder::calculateStartDate and TimeDuration::TimeDuration better use a
long directly (efficiency)

In ConfigXMLReader, removes unused getViewMap method

In ServiceArtifactInfo, some formatting and in writeServiceCallGraphEoModel
method add missing <<if (calledServiceSet != null) {>>

Adds and documents false positives in exclude.xml.
Remains 14 issues, I'll document them in the Jira and 'll later discuss them
on dev ML (committers attention needed). None of them are security issues :)
C:/projectsASF/Git/ofbiz-framework/plugins/rest-api/src/main/java/org/apache/ofbiz/ws/rs/listener/ApiContextListener.java:38 Ecriture d'un champ statique org.apache.ofbiz.ws.rs.listener.ApiContextListener.servletContext depuis la méthode d'une instance org.apache.ofbiz.ws.rs.listener.ApiContextListener.contextInitialized(ServletContextEvent) [Of Concern(15), High confidence]
C:/projectsASF/Git/ofbiz-framework/framework/base/src/main/java/org/apache/ofbiz/base/util/collections/GenericMapValues.java:49 org.apache.ofbiz.base.util.collections.GenericMapValues.equals(Object) checks for operand being a java.util.List  [Troubling(14), High confidence]
C:/projectsASF/Git/ofbiz-framework/plugins/ldap/src/main/java/org/apache/ofbiz/ldap/cas/OFBizCasAuthenticationHandler.java:91 Déréférencement immédiat du résultat d'un readLine() dans org.apache.ofbiz.ldap.cas.OFBizCasAuthenticationHandler.login(HttpServletRequest, HttpServletResponse, Element) [Of Concern(15), Normal confidence]
C:/projectsASF/Git/ofbiz-framework/framework/base/src/main/java/org/apache/ofbiz/base/util/collections/GenericMapValues.java:49 org.apache.ofbiz.base.util.collections.GenericMapValues.equals(Object) checks for operand being a java.util.Set  [Troubling(14), High confidence]
C:/projectsASF/Git/ofbiz-framework/framework/widget/src/test/java/org/apache/ofbiz/widget/renderer/macro/MacroFormRendererTest.java:875 Un appel de méthode dans new org.apache.ofbiz.widget.renderer.macro.MacroFormRendererTest$36(MacroFormRendererTest, ModelForm) passe null à un paramètre déréférencé de façon inconditionnelle dans org.apache.ofbiz.webapp.control.RequestHandler.makeLink(HttpServletRequest, HttpServletResponse, String) [Scary(8), Normal confidence]
C:/projectsASF/Git/ofbiz-framework/framework/widget/src/test/java/org/apache/ofbiz/widget/renderer/macro/MacroFormRendererTest.java:848 Un appel de méthode dans new org.apache.ofbiz.widget.renderer.macro.MacroFormRendererTest$35(MacroFormRendererTest, ModelForm) passe null à un paramètre déréférencé de façon inconditionnelle dans org.apache.ofbiz.webapp.control.RequestHandler.makeLink(HttpServletRequest, HttpServletResponse, String) [Scary(8), Normal confidence]
C:/projectsASF/Git/ofbiz-framework/plugins/ecommerce/src/main/java/org/apache/ofbiz/ecommerce/janrain/JanrainHelper.java:71 Ecriture d'un champ statique org.apache.ofbiz.ecommerce.janrain.JanrainHelper.apiKey depuis la méthode d'une instance new org.apache.ofbiz.ecommerce.janrain.JanrainHelper(String, String) [Of Concern(15), High confidence]
C:/projectsASF/Git/ofbiz-framework/plugins/pricat/src/main/java/org/apache/ofbiz/htmlreport/AbstractReportThread.java:160 Champ jamais écrit : org.apache.ofbiz.htmlreport.AbstractReportThread.report [Troubling(12), Normal confidence]
C:/projectsASF/Git/ofbiz-framework/plugins/ecommerce/src/main/java/org/apache/ofbiz/ecommerce/janrain/JanrainHelper.java:72 Ecriture d'un champ statique org.apache.ofbiz.ecommerce.janrain.JanrainHelper.baseUrl depuis la méthode d'une instance new org.apache.ofbiz.ecommerce.janrain.JanrainHelper(String, String) [Of Concern(15), High confidence]
C:/projectsASF/Git/ofbiz-framework/framework/base/src/main/java/org/apache/ofbiz/base/util/cache/CacheSoftReference.java:29 org.apache.ofbiz.base.util.cache.CacheSoftReference est Serializable mais sa super-classe ne possède pas de constructeur par défaut visible [Troubling(14), High confidence]
C:/projectsASF/Git/ofbiz-framework/plugins/ldap/src/main/java/org/apache/ofbiz/ldap/activedirectory/OFBizActiveDirectoryAuthenticationHandler.java:110 Alimentation à perte d'une variable locale dans la méthode org.apache.ofbiz.ldap.activedirectory.OFBizActiveDirectoryAuthenticationHandler.getLdapSearchResult(String, String, Element, boolean) [Of Concern(15), High confidence]
C:/projectsASF/Git/ofbiz-framework/plugins/ldap/src/main/java/org/apache/ofbiz/ldap/openldap/OFBizLdapAuthenticationHandler.java:95 Alimentation à perte d'une variable locale dans la méthode org.apache.ofbiz.ldap.openldap.OFBizLdapAuthenticationHandler.getLdapSearchResult(String, String, Element, boolean) [Of Concern(15), High confidence]
C:/projectsASF/Git/ofbiz-framework/framework/base/src/main/java/org/apache/ofbiz/base/util/collections/FlexibleServletAccessor.java:193 org.apache.ofbiz.base.util.collections.FlexibleServletAccessor.equals(Object) checks for operand being a String  [Troubling(14), High confidence]
C:/projectsASF/Git/ofbiz-framework/framework/service/src/main/java/org/apache/ofbiz/service/test/XmlRpcTests.java:47 Ecriture d'un champ statique org.apache.ofbiz.service.test.XmlRpcTests.url depuis la méthode d'une instance new org.apache.ofbiz.service.test.XmlRpcTests(String) [Of Concern(15), High confidence]
2021-12-11 16:21:36 +01:00
Jacques Le Roux 8b9fc99d7d Improved: Fix some bugs Spotbugs reports (OFBIZ-12386)
In ProductWorker::getProductFeaturesApplIncludeMarketingPackage fixes a possible
null dereferencement (tested too late)

In FileUtil::unZip uses a try-w-resource w/ ZipFile to close it. I crossed an
issue with automated OOTB formatting (clean-up on save in Eclipse). Fixed with
my external default editor (could not find where to change that in
OFBizJavaFormatter.xml

In ServiceArtifactInfo::calledServiceEcaSet fixes a possible null dereferencement
(tested too late), also minor formatting

In MacroScreenRenderer::renderScreenletSubWidget fixes a possible null
dereferencement (tested too late)

in FileUtil
2021-12-10 16:09:42 +01:00
Jacques Le Roux 69cff24c82 Improved: Fix some bugs Spotbugs reports (OFBIZ-12386)
In WebToolsServices::entityImportDir fixes a possible null dereferencement

Missed in previous commit, not sure why
2021-12-10 09:51:22 +01:00
Jacques Le Roux 5dfdb5095f Fixed: Fix some bugs Spotbugs reports (OFBIZ-12386)
Fixes a Spotbugs worry and clarifies code
2021-11-18 17:09:08 +01:00
Jacques Le Roux 9f822ab337 Improved: removes Java compilation unchecked] and deprecation warnings 2021-10-18 13:33:52 +02:00
Jacques Le Roux 2489381f7f Improved: Handle remaining checkstyle errors (OFBIZ-12169)
Adds unused hashCode method to *ArtifactInfo and PackingSession classes
Makes final CmsEvents, ContactMechWorker and PartyWorker classes

There are no longer any checkstyle issues
2021-10-17 15:59:35 +02:00
Jacques Le Roux 49cae3c73a Improved: Handle remaining checkstyle errors (OFBIZ-12169)
Adds getter and setter to ScreenRenderer class
Adds unused hashCode method to ControllerRequestArtifactInfo class
Makes final UomWorker and ContactHelper classes

Only 10 checkstyle issues now
2021-10-17 15:45:55 +02:00
Jacques Le Roux a5bdcc6f9e Fixed: post-auth Remote Code Execution Vulnerability (OFBIZ-12332)
This definitely solves all issues by introducing a CacheFilter and
RequestWrapper classes inspired by several works found on the Net.
Also moves the change introduced before in ContextFilter to CacheFilter.

The basic problem is that you only can use once
ServletRequest::getInputStream or the ServletRequest::getReader
Also not both, even once, ie they can be seen as same from this POV.

The integration tests all pass.

Also replace the checked String "</serializable>" by "</serializable" as, like
reported by Jie Zhu, the former could be bypassed by using "</serializable >"

Thanks: Jie Zhu for report
2021-10-10 08:00:51 +02:00
Jacques Le Roux 6a7f3cd83e Fixed: Groovy Program sandbox bypass (OFBIZ-12305)
This much increases the current security by creating SecuredUpload::isValidText
and call it from ProgramExport.groovy

This said I agree with thiscodecc that a better solution would be to use a
Groovy sandbox, and not only in ProgramExport.groovy.

I had a quick glance at a such solution. Unfortunately as Cédric Champeau reports
at https://melix.github.io/blog/2015/03/sandboxing.html and unlike thiscodecc
suggest there are no "mature solutions on the market".

Nevertheless I'll have a deeper look at an OFBiz specific Groovy sandbox
solution.

Somehow related: I'll also soon extract the list of words used in
SecuredUpload::isValidText in a deniedWebShellWords property in security.properties

Thanks: thiscodecc for report
2021-09-17 18:50:07 +02:00
Jacques Le Roux 7a22a2bfc9 Fixed: Found a new XXE (XML External Entity Injection) vulnerability in EntityImport (OFBIZ-12304)
The XXE vulnerability can read arbitrary files on the server.

Thanks: thiscodecc for reporting this security issue (post-auth)
2021-09-13 09:28:06 +02:00
Jacques Le Roux 67665d1a9e Fixed: Found a new XXE (XML External Entity Injection) vulnerability in ArtifactInfo (OFBIZ-12306)
The XXE vulnerability can read arbitrary files on the server.

Thanks: thiscodecc for reporting this security issue (post-auth)
2021-09-13 08:10:14 +02:00
Nicolas Malin fa3e3573dc Improved: Improve run test from artefact info (OFBIZ-12312)
From https://localhost:8443/webtools/control/ViewComponents we have te possibility to run each test case or test suite.

We improve it with call with rest schema (like https://localhost:8443/webtools/control/RunTest/product/producttagtests) and display the result below

By this way, we also improve the groovy syntax to slim the code and extend xml form to CommonBasicGrid

Thanks to Gil Portenseigne for is support
2021-09-10 10:17:23 +02:00
Nicolas Malin 4bb54a1d1c Improved: Improve login page for Helveticus Theme (OFBIZ-12313)
Update the login page for Helveticus theme to keep the same spirit.

Thanks to Marine Desmarchelier for her work
2021-09-09 18:33:50 +02:00
Jacques Le Roux 4d3039c5de Improved: Fix issues reported by SonarQube analysis on Github (OFBIZ-12284)
SonarQBE did not detect bug put in in ModelInduceFromDb.jsp by 13d6bc2,
found it by chance

"moz-linear-gradient(bottom" should be better than "moz-linear-gradient(to bottom"
2021-08-06 17:07:58 +02:00
Jacques Le Roux 13d6bc2913 Improved: Fix issues reported by SonarQube analysis on Github (OFBIZ-12284)
Those should be OK, for instance I see no reasons to do something like that:
window.location.href = window.location.href;
2021-08-06 11:45:30 +02:00
Jacques Le Roux 2c421cedfb Fixed: Add http to https redirect rule for ofbiz.apache.org (OFBIZ-10590)
This prevented to run the stable demo, hence the next, weirdly the trunk had
not this problem. Anyway better safe than sorry... Maybe related to Gradle
version or rather libs loaded?

The reason why the stable (and old) demos were not running is because the
EntitySaxReaderTests did not pass
2021-07-20 07:47:32 +02:00
Eugen Stan 293db968c0 Improved: Clean commented code from ofbiz webtools (#313)
(OFBIZ-8043)
2021-07-09 07:30:44 +02:00
Jacques Le Roux 29705efa65 Improved: Add global web.xml to simplify session timeout configuration (OFBIZ-12255)
Currently, session timeout is configured in apps separately, but session is
shared globally, so the smallest one take effects, and it will not take effect
separately for different apps.

Then it is both inconvenient and confusing to increase session timeout value,
as all values in those files need to be updated.

A global web.xml is needed, to simplify session timeout configuration.

Thanks: Xin Wang
2021-06-22 15:51:32 +02:00
Daniel Watford c654d9bbcc Improved: Convert EntitySyncServices.xml mini-lang to groovy
(OFBIZ-11660)

removed: EntitySyncServices.xml
added: EntitySyncServices.groovy
modified: services.xml to reflect the change from minilang to groovy for:
- entitySyncPermissionCheck
- resetEntitySyncStatus
modified: webtools/controller.xml to reflect changed request-map and event type regarding reset of EntitySyncStatus
modified: webtools/widget/EntitySyncForms.xml to reflect changed target regarding reset of EntitySyncStatus

Thanks: Pierre Smits for implementation
2021-05-30 08:13:23 +01:00
Aditya Sharma e97f45c381 Fixed: removed unused asmselect files and unused variable asm_asmListItemPercentOfForm (OFBIZ-10113)
asm select library is already replaced with select2 library, but the library files still exist in code base unused.
asm_asmListItemPercentOfForm varaible was used to set the width of the selected items which were displaced distictly from select fields. With select2, the selected items display inside the input field so it is no more needed

Thanks Jacques Le Roux for reporting it
2021-05-12 11:57:54 +05:30
Jacques Le Roux 45f50c910d Improved: Handle remaining checkstyle errors (OFBIZ-12169)
This handles the "'(' should be on the previous line?" rule of MethodParamPad

Actually not completely, because there are still some cases that can't be
handled by changing code, notably when a casting is necessary. I believe there
is an error in checkstyle code. I'll discuss that in dev ML before sending
checkstyle team a report.
2021-05-04 10:34:52 +02:00
bjugl e786da42e8 Fixed: Induction from DB does not represent relations properly. (#290) (OFBIZ-12178)
As encountered in OFBIZ-6510, the ModelInduceFromDb does currently not include entity relations and foreign key constraints. Since they are an important part of the database model, we should fix that.

I could track down the problem to an incomplete invocation of the ModelEntity through the constructor used in the DatabaseUtil.induceModelFromDb() Methods. This constructor does not initialize the Relations.

Problem is, that the ModelEntity initialized through the "DB Names Constructor" does not cover references in its current state at all.

While working on an implementation I realized, that the API is not very congruent in this regards. I would expect that I could initialize ModelRelations the same way ModelFields are initialized in this context:

The create() Method takes a ModelEntity, DatabaseUtil.ColumnCheckInfo (respectively a DatabaseUtil.ReferenceCheckInfo) and a ModelFieldTypeReader (that could be left out for references) and creates ModelField (ModelRelation) objects that are added to the ModelEntity.

But that is not the case at the moment. On one hand not all fields that would be necessary are covered in the DatabaseUtil.ReferenceCheckInfo Objects (e.g. "type" is missing), on the other the object is missing public getters to make the values available in the first place.

Thanks a bunch Benjamin, nice add !
2021-04-02 11:12:42 +02:00
Jacques Le Roux 643b9c7ea7 Improved: Comment out the SOAP and HTTP engines (OFBIZ-12212)
The SOAP and HTTP engines are open doors to security issues.
At https://markmail.org/message/pgtjyh23bazq4s2w I proposed to comment them out
as we did for RMI in the past.
Of cause it must be clearly documented how to use them if needed.

Here is the email content:

    After the recent fix for the CVE-2021-26295[1] we discussed with the security
    team about the opportunity need to comment out the SOAP and HTTP engines
    like we did in the past for RMI[2], this obviously for security reason.

    [1] OFBIZ-12167 "Adds a blacklist (to be
    renamed soon to denylist) in Java serialisation (CVE-2021-26295)"
    [2] OFBIZ-6942 "Comment out RMI related
    code because of the Java deserialization issue [CVE-2016-2170] "

I just put a small comment in webtools controller, it should be enough.

The tests pass
2021-03-29 13:13:53 +02:00
Suraj Khurana 92c13814b7 Improved: Improve all the service level error messages for missing required field for webtools component.
(OFBIZ-8717)
Thanks Ritesh Kumar for providing the patch.
2021-03-27 10:28:50 +05:30
Jacques Le Roux 75e0247048 Fixed: webtools/control/threadList no longer works on trunk (only) (OFBIZ-12195)
It works if we downgrade Freemarker to 2.3.28 as in R18 and even using 2.3.29,
not 2.3.30.

Handles things at the Groovy level, ie put in context, rather than creating
in Freemarker template.

It's backported, even if it's not a pb but in trunk, because it's a (low)
security issue.
2021-03-12 08:58:14 +01:00
Jacques Le Roux 59a6f46083 Fixed: Cant search ViewEntity InventoryItemDetailForSum (OFBIZ-12193)
Go to Entity Engine - >
search entity InventoryItemDetailForSum (view entity) ->
search for entries -> an error message is shown.

A SQL exception occurred running the service executeFind

Thanks: Sebastian Berg
2021-03-08 09:38:14 +01:00
Michael Brohl 69c62f5f00 Merge changes for PR #267 due to conflicting changes in trunk (OFBIZ-12169) 2021-02-15 17:15:18 +01:00
Jacques Le Roux 3517a54a48 Fixed: webapp position does not really work (OFBIZ-12176)
Remove webtools from secondary menu to get it in right (12) position
2021-02-15 13:57:17 +01:00
Jacques Le Roux a2dac5482c Improved: Default ordering of webapps titles in main menu (OFBIZ-12166)
[...] having more important apps in 1st places would be better [...]
the feature should be easily changed by custom projects [...]
documentation for that would be enough.

This 1st step sorts the applications and webtools. I believe webtools should not
be secondary but that needs to be discussed with other options.
2021-02-14 21:11:58 +01:00
Michael Brohl 29bf0a040a Merge branch 'trunk' into OFBIZ-12169_Handle_remaining_checkstyle_errors 2021-02-13 11:26:01 +01:00
Michael Brohl d251164e06 Improved: simplified ModelInduceFromDb.groovy code to be a one-liner. 2021-02-11 20:54:18 +01:00
Wiebke Pätzold 82a15c70e3 Improved: Removed inner assignments (OFBIZ-12169) 2021-02-10 11:38:04 +01:00
Wiebke Pätzold 2e6399c20c Improved: Simplified expression (OFBIZ-12169) 2021-02-09 14:09:55 +01:00
Michael Brohl bae3628501 Declare classes final as suggested by checkstyle (OFBIZ-12169)
Helper and Worker classes which are likely to be extended by custom
projects where left as is.
2021-02-08 17:09:56 +01:00
Benjamin Jugl 5a0b0a0c0d Fixed: Checkstyle Issues in WebToolsDbEvents and UtilXml (OFBIZ-6510) 2021-02-04 12:29:28 +01:00
Benjamin Jugl 8fac07ad0a Improved: Replaces ModelInduceFromDb with widgets (OFBIZ-6510) 2021-02-03 12:39:15 +01:00
Jacques Le Roux ec2b84341e Reverted: "Improved: Hyperlink target-type attribute is deprecated and should be replaced by url-mode (OFBIZ-12091)"
This reverts commit 17eb2e4cf7.

It does not work when using <<target="javascript:........>>
I could change those cases but it's easier and safer to simply revert back to
target-type!

Thanks: James for report
2020-12-18 11:08:32 +01:00
Jacques Le Roux 17eb2e4cf7 Improved: Hyperlink target-type attribute is deprecated and should be replaced by url-mode (OFBIZ-12091)
Same for sub-hyperlink
2020-12-11 16:52:04 +01:00
Jacques Le Roux f34a0d9ff5 Fixed: Prevent arbitary file write using webtools/control/EntitySQLProcessor. (OFBIZ-12057)
Shuibo Ye <shuiboye@gmail.com> reported a possible arbitary file write using
webtools/control/EntitySQLProcessor.

    In the "SQL Command" part, I create a table and insert some strings and
    export the table to a file one sentence at a time.
    PoC: CREATE TABLE "test" (string VARCHAR(80))
    INSERT INTO "test" (string) VALUES ('<%= system.getProperty("user.dir") %>')
    call SYSCS_UTIL.SYSCS_EXPORT_TABLE(null,'test','.\framework\webtools\webapp\webtools\default.jsp',null,'*',null)

    After executing the three sentences,I successfully write the file and its url
    is https://localhost:8443/webtools/default.jsp.

I fixed it preventing execution on SYSCS_UTIL.SYSCS_EXPORT_TABLE and JSP, more
could be added if necessary
2020-11-16 14:11:13 +01:00
Jacques Le Roux 70d3916d4f Improved: Prevent possible post-auth RCE from webtools/control/ProgramExport (OFBIZ-12055)
This was reported to the security team by Shuibo Ye <shuiboye@gmail.com>.
We did not create a CVE because it's a post-auth "vulnerability"

Thanks: Shuibo Ye
2020-11-13 09:34:49 +01:00
holivier 302bc0eb15 Documented: migration to help system using asciidoc files (OFBIZ-11587)
Remove all related help docbook files
2020-10-26 17:34:03 +01:00