CVE-2023-27577: Flarum/core Path Traversal Vulnerability
MODERATECVE-2023-27577 is a MODERATE (CVSS 6.5) path traversal vulnerability (CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')) affecting Flarum/core libraries in the Packagist ecosystem. The issue involves path traversal vulnerability in `less` parser allows reading of sensitive server files. Remediation is available by upgrading affected packages to version 1.7.0.
CVE-2023-27577 at a Glance
Security Impact
CVSS: 6.5
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:N/I:H/A:H).
How to Fix CVE-2023-27577
To remediate this vulnerability, upgrade all affected Flarum/core dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade flarum/core to 1.7.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for flarum/core
How to Check if You Are Affected
To determine whether your application is affected by CVE-2023-27577, inspect your project dependencies for Flarum/core:
inspect dependencies for flarum/core
Analyze the terminal output to locate any version of Flarum/core in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.7.0), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal'), where the product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory. In Flarum/core, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2023-27577 Affected Flarum/core Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
flarum/core
|
Packagist |
< 1.7.0
|
1.7.0
|
References
Frequently Asked Questions
What is CVE-2023-27577?
Which Flarum/core versions are affected?
What version fixes CVE-2023-27577?
Is flarum/core affected?
What is the CVSS score of CVE-2023-27577?
What CWE is associated with CVE-2023-27577?
How can I check Packagist dependencies for CVE-2023-27577?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-vhm8-wwrf-3gcw",
"modified" : "2023-03-13T20:52:11Z",
"published" : "2023-03-13T20:52:11Z",
"aliases" : [ "CVE-2023-27577" ],
"summary" : "Path Traversal Vulnerability in `LESS` Parser allows reading of sensitive server files",
"details" : "### Impact\nIf an admin account has already been compromised by an attacker, the `LESS` parser can be exploited to read sensitive files on the server through the use of path traversal techniques.\n\nAn attacker can achieve this by providing an absolute path to a sensitive file in the custom `LESS` setting, which the `LESS` parser will then read. For example, an attacker could use the following code to read the contents of the `/etc/passwd` file:\n\n```less\n@import (inline) '/etc/passwd';\n\n.test {\n content: data-uri('/etc/passwd');\n}\n```\n\n### Patches\nThe vulnerability has been addressed in version `1.7`. Users should upgrade to this version to mitigate the vulnerability.\n\n### Workarounds\nUsers can mitigate the vulnerability by ensuring that their admin accounts are secured with strong passwords and other best practices for account security. Additionally, users can limit the exposure of sensitive files on the server by implementing appropriate file permissions and access controls.\n",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:N/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Packagist",
"name" : "flarum/core"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "1.7.0"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/flarum/framework/security/advisories/GHSA-vhm8-wwrf-3gcw"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-27577"
}, {
"type" : "WEB",
"url" : "https://github.com/flarum/framework/commit/1761660c98ea5a3e9665fb8e6041d1f2ee62a444"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/flarum/flarum-core"
}, {
"type" : "WEB",
"url" : "https://github.com/flarum/flarum-core/releases/tag/v1.7.0"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-22" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2023-03-13T20:52:11Z",
"nvd_published_at" : "2023-03-10T21:15:00Z"
}
}