CVE-2025-43827
Description
Insecure Direct Object Reference (IDOR) vulnerability with audit events in Liferay Portal 7.4.0 through 7.4.3.117, and older unsupported versions, and Liferay DXP 2024.Q1.1 through 2024.Q1.5, 2023.Q4.0 through 2023.Q4.10, 2023.Q3.1 through 2023.Q3.10, 7.4 GA through update 92, and older unsupported versions allows remote authenticated users to from one virtual instance to view the audit events from a different virtual instance via the _com_liferay_portal_security_audit_web_portlet_AuditPortlet_auditEventId parameter.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
com.liferay:com.liferay.portal.security.audit.webMaven | >= 5.0.1, < 5.0.33 | 5.0.33 |
com.liferay:com.liferay.portal.security.audit.storage.serviceMaven | >= 6.0.4, < 6.0.41 | 6.0.41 |
Affected products
2- Liferay/DXPv5Range: 7.4.13
Patches
3d85c2f24397dLPD-16002 Minor changes
1 file changed · +9 −3
modules/dxp/apps/portal-security-audit/portal-security-audit-web/src/main/java/com/liferay/portal/security/audit/web/internal/portlet/AuditPortlet.java+9 −3 modified@@ -92,9 +92,15 @@ private void _checkCompanyAdmin(PortletRequest portletRequest) AuditEvent auditEvent = AuditEventManagerUtil.fetchAuditEvent( auditEventId); - if (permissionChecker.getCompanyId() != auditEvent.getCompanyId()) { - throw new PortletException( - "This event does not belong to this company"); + if ((auditEvent != null) && + (permissionChecker.getCompanyId() != + auditEvent.getCompanyId())) { + + PrincipalException principalException = + new PrincipalException.MustBeCompanyAdmin( + permissionChecker.getUserId()); + + throw new PortletException(principalException); } }
f99602a23ce1LPD-16002 Prevent users without the right role to access events from another company
1 file changed · +4 −4
modules/apps/portal-security-audit/portal-security-audit-storage-service/src/main/java/com/liferay/portal/security/audit/storage/service/impl/AuditEventServiceImpl.java+4 −4 modified@@ -41,7 +41,7 @@ public List<AuditEvent> getAuditEvents(long companyId, int start, int end) PermissionChecker permissionChecker = getPermissionChecker(); - if (!(permissionChecker.isCompanyAdmin() || + if (!(permissionChecker.isCompanyAdmin(companyId) || _userLocalService.hasRoleUser( companyId, RoleConstants.ANALYTICS_ADMINISTRATOR, permissionChecker.getUserId(), true))) { @@ -60,7 +60,7 @@ public List<AuditEvent> getAuditEvents( PermissionChecker permissionChecker = getPermissionChecker(); - if (!(permissionChecker.isCompanyAdmin() || + if (!(permissionChecker.isCompanyAdmin(companyId) || _userLocalService.hasRoleUser( companyId, RoleConstants.ANALYTICS_ADMINISTRATOR, permissionChecker.getUserId(), true))) { @@ -83,7 +83,7 @@ public List<AuditEvent> getAuditEvents( PermissionChecker permissionChecker = getPermissionChecker(); - if (!(permissionChecker.isCompanyAdmin() || + if (!(permissionChecker.isCompanyAdmin(companyId) || _userLocalService.hasRoleUser( companyId, RoleConstants.ANALYTICS_ADMINISTRATOR, permissionChecker.getUserId(), true))) { @@ -109,7 +109,7 @@ public List<AuditEvent> getAuditEvents( PermissionChecker permissionChecker = getPermissionChecker(); - if (!(permissionChecker.isCompanyAdmin() || + if (!(permissionChecker.isCompanyAdmin(companyId) || _userLocalService.hasRoleUser( companyId, RoleConstants.ANALYTICS_ADMINISTRATOR, permissionChecker.getUserId(), true))) {
a14427e23384LPD-16002 Do not show audit event if it is from the wrong company
1 file changed · +22 −4
modules/dxp/apps/portal-security-audit/portal-security-audit-web/src/main/java/com/liferay/portal/security/audit/web/internal/portlet/AuditPortlet.java+22 −4 modified@@ -9,6 +9,9 @@ import com.liferay.portal.kernel.security.auth.PrincipalException; import com.liferay.portal.kernel.security.permission.PermissionChecker; import com.liferay.portal.kernel.security.permission.PermissionThreadLocal; +import com.liferay.portal.kernel.util.ParamUtil; +import com.liferay.portal.security.audit.AuditEvent; +import com.liferay.portal.security.audit.web.internal.AuditEventManagerUtil; import com.liferay.portal.security.audit.web.internal.constants.AuditPortletKeys; import java.io.IOException; @@ -17,6 +20,7 @@ import javax.portlet.ActionResponse; import javax.portlet.Portlet; import javax.portlet.PortletException; +import javax.portlet.PortletRequest; import javax.portlet.RenderRequest; import javax.portlet.RenderResponse; import javax.portlet.ResourceRequest; @@ -51,7 +55,7 @@ public void processAction( ActionRequest actionRequest, ActionResponse actionResponse) throws IOException, PortletException { - _checkCompanyAdmin(); + _checkCompanyAdmin(actionRequest); super.processAction(actionRequest, actionResponse); } @@ -61,7 +65,7 @@ public void render( RenderRequest renderRequest, RenderResponse renderResponse) throws IOException, PortletException { - _checkCompanyAdmin(); + _checkCompanyAdmin(renderRequest); super.render(renderRequest, renderResponse); } @@ -71,15 +75,29 @@ public void serveResource( ResourceRequest resourceRequest, ResourceResponse resourceResponse) throws IOException, PortletException { - _checkCompanyAdmin(); + _checkCompanyAdmin(resourceRequest); super.serveResource(resourceRequest, resourceResponse); } - private void _checkCompanyAdmin() throws PortletException { + private void _checkCompanyAdmin(PortletRequest portletRequest) + throws PortletException { + PermissionChecker permissionChecker = PermissionThreadLocal.getPermissionChecker(); + long auditEventId = ParamUtil.getLong(portletRequest, "auditEventId"); + + if (auditEventId > 0) { + AuditEvent auditEvent = AuditEventManagerUtil.fetchAuditEvent( + auditEventId); + + if (permissionChecker.getCompanyId() != auditEvent.getCompanyId()) { + throw new PortletException( + "This event does not belong to this company"); + } + } + if (!permissionChecker.isCompanyAdmin()) { PrincipalException principalException = new PrincipalException.MustBeCompanyAdmin(
Vulnerability mechanics
Generated by null/stub on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
7- github.com/advisories/GHSA-pw86-qvx9-34r7ghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2025-43827ghsaADVISORY
- github.com/liferay/liferay-portal/commit/a14427e2338477001f86a9e65fdddb843c319818ghsaWEB
- github.com/liferay/liferay-portal/commit/d85c2f24397dcb7d9e51e7bd292dd29268efb132ghsaWEB
- github.com/liferay/liferay-portal/commit/f99602a23ce1b3aa12b2625441cfaa17bfbd22b6ghsaWEB
- liferay.atlassian.net/browse/LPE-17938ghsaWEB
- liferay.dev/portal/security/known-vulnerabilities/-/asset_publisher/jekt/content/CVE-2025-43827ghsaWEB
News mentions
0No linked articles in our index yet.