Skip to content

Potential directory traversal in OC\Files\Node\Folder::getFullPath

Moderate
miaulalala published GHSA-273v-9h7x-p68v Feb 22, 2023

Package

Server (Nextcloud)

Affected versions

<25.0.2, < 24.0.8, < 23.0.12

Patched versions

25.0.2, 24.0.8, 23.0.12
Server (Enterprise) (Nextcloud)
<25.0.2, < 24.0.8, < 23.0.12, < 22.2.10, < 21.0.9, < 20.0.14
25.0.2, 24.0.8, 23.0.12, 22.2.10.10, 21.0.9.10, 20.0.14.12

Description

Impact

OC\Files\Node\Folder::getFullPath() is validating and normalizing the string in the wrong order.

The function seems to be used in newFile() and newFolder() items, allowing to create paths outside of ones own space and overwriting data from other users.

Patches

It is recommended that the Nextcloud Server is upgraded to 25.0.2, 24.0.8, 23.0.12,
It is recommended that the Nextcloud Enterprise Server is upgraded to 25.0.2, 24.0.8, 23.0.12, 22.2.10.10, 21.0.9.10, 20.0.14.12

Workarounds

No workaround available

References

For more information

If you have any questions or comments about this advisory:

Severity

Moderate
5.5
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
High
Privileges required
Low
User interaction
Required
Scope
Changed
Confidentiality
Low
Integrity
Low
Availability
Low
CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:L/I:L/A:L

CVE ID

CVE-2023-25579

Weaknesses

Credits