You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@struts.apache.org by ku...@apache.org on 2024/07/08 17:56:28 UTC
(struts) branch WW-5428-stop-excessive-logging created (now 87853d4f6)
This is an automated email from the ASF dual-hosted git repository.
kusal pushed a change to branch WW-5428-stop-excessive-logging
in repository https://gitbox.apache.org/repos/asf/struts.git
at 87853d4f6 WW-5428 Stop excessive logging in DevMode
This branch includes the following new commits:
new 87853d4f6 WW-5428 Stop excessive logging in DevMode
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(struts) 01/01: WW-5428 Stop excessive logging in DevMode
Posted by ku...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
kusal pushed a commit to branch WW-5428-stop-excessive-logging
in repository https://gitbox.apache.org/repos/asf/struts.git
commit 87853d4f6b2de759c312325ddce9344acff909ca
Author: Kusal Kithul-Godage <gi...@kusal.io>
AuthorDate: Tue Jul 9 03:56:17 2024 +1000
WW-5428 Stop excessive logging in DevMode
---
.../main/java/com/opensymphony/xwork2/ognl/SecurityMemberAccess.java | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/core/src/main/java/com/opensymphony/xwork2/ognl/SecurityMemberAccess.java b/core/src/main/java/com/opensymphony/xwork2/ognl/SecurityMemberAccess.java
index f225b3c89..1d88df099 100644
--- a/core/src/main/java/com/opensymphony/xwork2/ognl/SecurityMemberAccess.java
+++ b/core/src/main/java/com/opensymphony/xwork2/ognl/SecurityMemberAccess.java
@@ -224,7 +224,6 @@ public class SecurityMemberAccess implements MemberAccess {
*/
protected boolean checkAllowlist(Object target, Member member) {
if (!enforceAllowlistEnabled) {
- logAllowlistDisabled();
return true;
}
@@ -495,6 +494,9 @@ public class SecurityMemberAccess implements MemberAccess {
@Inject(value = StrutsConstants.STRUTS_ALLOWLIST_ENABLE, required = false)
public void useEnforceAllowlistEnabled(String enforceAllowlistEnabled) {
this.enforceAllowlistEnabled = BooleanUtils.toBoolean(enforceAllowlistEnabled);
+ if (!this.enforceAllowlistEnabled) {
+ logAllowlistDisabled();
+ }
}
@Inject(value = STRUTS_ALLOWLIST_CLASSES, required = false)