Commit Graph

5667 Commits

Author SHA1 Message Date
Sebastian Haas dca0dd224f Fix typo in MultiselectInterceptor javadoc 2019-08-29 11:40:06 +02:00
Yasser Zamani 570f8c3e67 fix compilation error of WW-4999 cherry picks 2019-06-03 12:28:57 +04:30
Yasser Zamani 704e41c6e8 test false for logMissingProperties (WW-4999)
(cherry picked from commit a50af87)
2019-06-03 12:17:15 +04:30
Yasser Zamani eca9c34645 decouple logMissingProperties from devMode (WW-4999)
(cherry picked from commit 9e01fbd)
2019-06-03 12:17:02 +04:30
Yasser Zamani a16cd4fca6 test not throw exception on top missing property (WW-4999)
instead continue to next objects in stack

Also tests not skip returned null values by user method

(cherry picked from commit d4dd338)
2019-06-03 12:16:52 +04:30
Yasser Zamani 382124cfd2 not log user exceptions as missing properties (WW-4999)
Also reaks loop on user method exceptions - but continue to next objects in stack on NoSuchMethodException.

(cherry picked from commit 0999fba)
2019-06-03 12:16:37 +04:30
Yasser Zamani b657a272d1 fix logMissingProperties (WW-4999)
Moves checking OgnlValueStack.THROW_EXCEPTION_ON_FAILURE outside loop because it shouldn't throw exception on first failure while is trying all root objects.

Returns on first successful call because it's not rational and is confusing user to skip when user method successfully returns null as an actual result.

Fixes WW-4999 via honoring (devMode && logMissingProperties) for OgnlValueStack.THROW_EXCEPTION_ON_FAILURE and REPORT_ERRORS_ON_NO_PROP.

(cherry picked from commit 3ac6835)
2019-06-03 12:16:25 +04:30
Lukasz Lenart b8ce02b159 Merge pull request #360 from JCgH4164838Gh792C124B5/localS2_26x_TextProviderFix
[WW-5034] Forward port - Minor enhancement/fix to AbstractLocalizedTextProvider:
2019-06-03 07:40:22 +02:00
JCgH4164838Gh792C124B5 5c30e0d5c6 [WW-5034] Forward port Minor enhancement/fix to
AbstractLocalizedTextProvider:
- Forward port of equivalent change from 2.5.x.
- Made "constant" RELOADED static to save an initialization every time.
- Made ineffective clearBundle(final String bundleName) method a "no-op"
  with a debug log indicating the same.  Marked method as deprecated.
- Introduced protected clearBundle(final String bundleName, Locale locale)
  method for use by descendants, with debug log output when called.
- Introduced protected clearMissingBundlesCache() method for use by
  descendants, with debug log when called.
2019-06-01 14:58:18 -04:00
Lukasz Lenart daf9bd1b3d Merge pull request #359 from sepe81/update-mvnw
Update maven-wrapper to 0.5.5 and maven to 3.6.1
2019-05-31 07:34:14 +02:00
Sebastian Peters fb45a0b1b6 Update maven-wrapper to 0.5.5 and maven to 3.6.1 2019-05-30 21:26:04 +02:00
Yasser Zamani b7d64f3a01 allow white-space around ";" character in multipart request RegEx
fixes WW-4958
2019-04-23 12:09:58 +04:30
Lukasz Lenart 33137a4919 Merge pull request #352 from yasserzamani/WW-5011
WW-5011 use Tiles already provided URLApplicationResource
2019-04-23 08:22:59 +02:00
Yasser Zamani 517c2d690b use Tiles already provided URLApplicationResource
fixes WW-5011
see also: https://github.com/joshlong/spring-framework/blob/910dd4146721a803cd9d246b91854e77ffe9272a/spring-webmvc-tiles3/src/main/java/org/springframework/web/servlet/view/tiles3/SpringWildcardServletTilesApplicationContext.java#L88
2019-04-20 12:28:07 +04:30
JCgH4164838Gh792C124B5 47a8a21da2 Proposed fix for WW-5029 for the 2.5.x branch (#347)
* Proposed fix for WW-5029 for the 2.5.x branch:
- NOTE: If the PR is accepted please credit Maxime Clement for this change as they found
        the issue, identified the probable cause/related details and opened the JIRA.
- Updated XWorkConfigurationProvider buildAllowedMethods(), loadGlobalAllowedMethods() so that
  they now handle situations when a SAX parser produces multiple elements to represent the tag
  body value.
- No changes to unit tests.

* Update commit to fix weakness identified by Maxime Clement:
- Implementation should now properly concatenate the node children values together (as a single unified string)
  in both buildAllowedMethods(), loadGlobalAllowedMethods() - before generating the method Set to be added.
- Made some eligible variables final.

* Update commit to provide new unit tests:
- Added unit tests to confirm the fixes for buildAllowedMethods(), loadGlobalAllowedMethods()
- Added Mock DOM classes sufficient for these tests.
- Added unit tests to cover buildResults() and loadGlobalResults().

(cherry picked from commit fb38a91)
2019-04-20 10:00:48 +04:30
JCgH4164838Gh792C124B5 f0776aeac6 (Amended commit based on feedback)
Proposed fix for WW-5028 for the 2.5.x branch:
- Disable printing stacktrace on exceptions by the Dispatcher by default.
- Printing stacktrace on exception is only enabled with devMode set to true, as suggested by L. Lenart.
- Now prints stacktrace on exception using LOG, as suggested by A. Mashchenko and the the JIRA reporter.
  Log level set to debug as recommended by Y. Zamani.
- Added two additional unit tests for Dispatcher devMode and handleException states.

(cherry picked from commit 4815744)
2019-04-20 09:11:49 +04:30
Lukasz Lenart d71ff77f82 Merge pull request #351 from sepe81/enhance-gitignore
Add common .gitignore patterns from gitignore.io
2019-04-16 10:47:20 +02:00
Sebastian Peters 84e8eecee7 Add common .gitignore patterns from gitignore.io
Ignore .factorypath b/c it gets generated during maven compile.

Don't need to ignore every single target folder.
Instead use target/ pattern and add more common maven files.

Ignore .sonar folder for local sonar scanning.
2019-04-15 21:07:02 +02:00
Lukasz Lenart 91c6a6f88f Merge pull request #346 from JCgH4164838Gh792C124B5/localS2_26x_B4
Forward port fix for WW-5024 to 2.6:
2019-04-01 09:26:07 +02:00
Lukasz Lenart f251d1c737 Merge pull request #345 from JCgH4164838Gh792C124B5/localS2_26x_B3
Forward-port fix for WW-5026 to 2.6
2019-04-01 08:27:17 +02:00
JCgH4164838Gh792C124B5 3e11e1db47 Forward port fix for WW-5024 to 2.6:
- NOTE: If the PR is accepted please credit Robert Hollencamp (Github @rhollencamp) for this change
        as he found the issue, proposed a solution for 2.6 (master), and opened the JIRA.
- Updated HttpParameters, ActionMappingParametersInterceptor to prevent multi-level Parameter wrapping from occuring.
- Updated HttpParameters create(), build() and buildNoNestedWrapping() to replace redundant type operators with <> based on IDE hint.
- Made HttpParameters parameters member final based on IDE hint.
- Added a new ActionMappingParametersInterceptorTest to verify the fix.
2019-03-31 23:44:40 -04:00
JCgH4164838Gh792C124B5 bb7cf092bc Forward-port fix for WW-5026 to 2.6.
- Equivalent to PR#342 for 2.5.x, fixes double-submit error 500 failure with
- Fixes error 500 processing failures for double-submit results with TokenSessionStoreInterceptor processing
- Fix to InvocationSessionStore, new unit test confirming fix in InvocationSessionStoreTest
- Minor whitespace fix to TokenSessionStoreInterceptor
2019-03-31 22:47:16 -04:00
Aleksandr Mashchenko 6797dd8914 Merge pull request #338 from sepe81/maven-wrapper-3.6.0
Update maven-wrapper to 0.5.3 and maven to 3.6.0
2019-03-26 22:56:25 +02:00
JCgH4164838Gh792C124B5 e82c5a207f Upgrade SLF4J to 1.7.26 (WW-5023) (#337)
* Upgrade SLF4J to 1.7.26 (WW-5023)
2019-03-11 08:48:09 +01:00
JCgH4164838Gh792C124B5 d3eb1fc595 Fix for default (un-configured) allowStaticFieldAccess state, Showcase Application in 2.6.x (#334)
* Fix for default un-configured allowStaticFieldAccess state:
1) Ensure OgnlValueStackFactory returns true for allowStaticFieldAccess when not configured (consistency - same as OgnlUtil does).
2) Add test to OgnlValueStackTest for the no allowStaticXXX flags present.

Minor config fixes for the Showcase Application in 2.6.x:
1) File upload examples.  Multiple file upload missing result page (list and array), added missing JSP.  Added missing input results in configuration.
2) File upload examples.  Fixed NPE for multiple file upload (array version) when no files selected.
3) Add manual test for public constant access via expression (to If tag JSP).

* Added missed logic elements from PR#320 (identified by Y. Zamani):
1) Added ognlAllowStaticFieldAccess field and getter/setter to ConstantConfig.
2) Added allowStaticFieldAccess (set to true) to default.properties.

* Follow-up commit:
- Fixed wrong package reference in testNullMethod(), as well as in new tets.
- Added additional tests to cover the full set of static access flag combinations.

* Follow-up commit:
- Fixed createValueStack() not setting allowStaticFieldAccess parameter.
- Removed 3 unused import statement.
- Refactored OgnlValueStackFactory creation logic into two utility methods: getValueStackFactory(), reloadValueStackFactory()
- Added one additional test with a raw OgnlValueStackFactory generated OgnlValueStack (staticMethodAccess false, staticFieldAccess true).
  Test confirms same result as with a default OgnlValueStackFactory.
2019-03-11 09:35:48 +03:30
Sebastian Peters 1ef598ec2f Update maven-wrapper to 0.5.3 and maven to 3.6.0
./mvnw -N io.takari:maven:0.7.4:wrapper
2019-03-10 22:40:46 +01:00
Yasser Zamani ce4f192676 add properties support to XWorkTestCase.loadButAdd
also includes cleanups for PRs #292 and #320

(cherry picked from commit a15c12a)
2019-02-24 18:51:00 +03:30
Lukasz Lenart 3ee47f19c3 Merge pull request #335 from JCgH4164838Gh792C124B5/localS2_26x_Appfix2
Fix 2.6 Showcase bean-validator Java 11 failures.
2019-02-14 07:21:10 +01:00
JCgH4164838Gh792C124B5 a2ba5a0e62 Fix 2.6 Showcase bean-validator Java 11 failures.
The 2.6 Showcase application is throwing JAXB-classloading-related failures when deployed to a container running Java 11.
The stacktrace indicates the issues relate to the bean-validator and Hibernate-Validator (but no issues with Java 8).
Proposed fix:
1) Upgrade Showcase from 5.1.3.Final to 5.4.3.Final (most recent available).
2) Upgrade bean-validator from 5.4.1-Final to 5.4.3.Final (to match versions).
2019-02-14 01:03:44 -05:00
Lukasz Lenart 9a14323a6a Merge pull request #332 from yasserzamani/delete_sitegraph
WW-5020 delete deprecated sitegraph plugin
2019-02-12 09:34:17 +01:00
Yasser Zamani 28c9411015 delete deprecated sitegraph plugin 2019-02-11 16:53:20 +03:30
Aleksandr Mashchenko 9466b615ab Improve SecurityMemberAccess (#323)
* Improve SecurityMemberAccess

Move public member check to be the first performed
Remove final-s from methods to allow overriding
Split check for statics into two separate methods

* Change log level to warn
2019-02-10 23:17:27 +03:30
Johannes Geppert 2908d746ce Minor code optimization in jasper reports result 2019-02-10 16:15:38 +01:00
Johannes Geppert 9088405b0f Fix compile issue of jasper plugin with latest jasper version 2019-02-09 15:35:12 +01:00
Johannes Geppert bbe46e92f0 Fix compile issue of post order test example with latest http client version 2019-02-09 15:32:02 +01:00
Johannes Geppert 95866c347e Use latest available hibernate-validator version for bean validation test scope 2019-02-09 15:08:06 +01:00
Johannes Geppert 75d252554b Solve some dependency convergence issues reported by maven enforce plugin
https://issues.apache.org/jira/browse/WW-5018
2019-02-09 15:04:22 +01:00
Johannes Geppert 67d40ce12a Add maven enforce plugin with rule to avoid dependency convergence issues
https://issues.apache.org/jira/browse/WW-5018
2019-02-09 15:03:46 +01:00
Lukasz Lenart c58e49223d Merge pull request #330 from aleksandr-m/feature/java8_date
WW-5016 Support java8 date/time in date tag
2019-02-07 08:12:02 +01:00
Lukasz Lenart 2a92b71aaf Merge pull request #331 from aleksandr-m/feature/jenkins_badge
Update jenkins badge
2019-02-07 08:05:59 +01:00
Aleksandr Mashchenko 1a5653ad9b Update jenkins badge 2019-02-06 23:14:58 +02:00
Aleksandr Mashchenko aacac5b9fc WW-5016 Support java8 date/time in date tag 2019-02-06 23:06:09 +02:00
Yasser Zamani f3fb36b834 Merge pull request #329 from aleksandr-m/feature/WW-5009_master
WW-5009 EmptyStackException in JSON plugin due to concurrency
2019-02-05 14:38:24 +03:30
Aleksandr Mashchenko f6e0cdeb67 WW-4991 Not existing property in listValueKey throws exception 2019-02-04 22:06:26 +02:00
Lukasz Lenart 48fe791eef Merge pull request #312 from aleksandr-m/feature/java8
Switch to Java 8
2019-02-04 13:19:28 +01:00
Yasser Zamani 9d4e720922 upgrade to ASM 7
fixes WW-5005

(cherry picked from commit 3eb68be)
2019-02-04 14:28:16 +03:30
Lukasz Lenart a3085373c6 Adds a link to JavaDocs 2019-02-04 10:57:14 +01:00
Aleksandr Mashchenko be457f4241 WW-5009 EmptyStackException in JSON plugin due to concurrency 2019-02-03 21:41:08 +02:00
Yasser Zamani 5d663b3193 Merge pull request #325 from lukaszlenart/upgrade-depdency-check
Upgrades OWASP dependency-check-plugin to version 4.0.2
2019-02-03 13:39:09 +03:30
Lukasz Lenart 4410feb1da Upgrades OWASP dependency-check-plugin to version 4.0.2 2019-02-01 08:15:20 +01:00