Vulnerability Details : CVE-2023-31128
NextCloud Cookbook is a recipe library app. Prior to commit a46d9855 on the `master` branch and commit 489bb744 on the `main-0.9.x` branch, the `pull-checks.yml` workflow is vulnerable to command injection attacks because of using an untrusted `github.head_ref` field. The `github.head_ref` value is an attacker-controlled value. Assigning the value to `zzz";echo${IFS}"hello";#` can lead to command injection. Since the permission is not restricted, the attacker has a write-access to the repository. This issue is fixed in commit a46d9855 on the `master` branch and commit 489bb744 on the `main-0.9.x` branch. There is no risk for the user of the app within the NextCloud server. This only affects the main repository and possible forks of it. Those who have forked the NextCloud Cookbook repository should make sure their forks are on the latest version to prevent code injection attacks and similar.
Products affected by CVE-2023-31128
- cpe:2.3:a:nextcloud:cookbook:*:*:*:*:*:*:*:*
Exploit prediction scoring system (EPSS) score for CVE-2023-31128
0.69%
Probability of exploitation activity in the next 30 days
EPSS Score History
~ 80 %
Percentile, the proportion of vulnerabilities that are scored at or less
CVSS scores for CVE-2023-31128
Base Score | Base Severity | CVSS Vector | Exploitability Score | Impact Score | Score Source | First Seen |
---|---|---|---|---|---|---|
8.8
|
HIGH | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
2.8
|
5.9
|
NIST | |
8.1
|
HIGH | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H |
2.8
|
5.2
|
GitHub, Inc. |
CWE ids for CVE-2023-31128
-
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.Assigned by:
- nvd@nist.gov (Primary)
- security-advisories@github.com (Secondary)
References for CVE-2023-31128
-
https://github.com/nextcloud/cookbook/blob/a14d6ffc4d45e1447556f68606129dfd6c1505cf/.github/workflows/pull-checks.yml#L67
cookbook/pull-checks.yml at a14d6ffc4d45e1447556f68606129dfd6c1505cf · nextcloud/cookbook · GitHubProduct
-
https://securitylab.github.com/research/github-actions-untrusted-input/
Keeping your GitHub Actions and workflows secure Part 2: Untrusted input | GitHub Security LabExploit;Third Party Advisory
-
https://github.com/nextcloud/cookbook/commit/a46d98559e2c64292da9ffb06138cccc2e50ae1b
Fix typo in workflow file · nextcloud/cookbook@a46d985 · GitHubPatch
-
https://github.com/nextcloud/cookbook/security/advisories/GHSA-c5pc-mf2f-xq8h
pull-checks.yml workflow is vulnerable · Advisory · nextcloud/cookbook · GitHubVendor Advisory
-
https://github.com/nextcloud/cookbook/commit/489bb744
Fix typo in workflow file · nextcloud/cookbook@489bb74 · GitHubPatch
Jump to