{"api_version":"1","generated_at":"2026-07-24T00:13:54+00:00","cve":"CVE-2023-31128","urls":{"html":"https://cve.report/CVE-2023-31128","api":"https://cve.report/api/cve/CVE-2023-31128.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2023-31128","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2023-31128"},"summary":{"title":"CVE-2023-31128","description":"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.","state":"PUBLIC","assigner":"security-advisories@github.com","published_at":"2023-05-26 22:15:00","updated_at":"2023-06-05 14:15:00"},"problem_types":["CWE-78"],"metrics":[],"references":[{"url":"https://github.com/nextcloud/cookbook/blob/a14d6ffc4d45e1447556f68606129dfd6c1505cf/.github/workflows/pull-checks.yml#L67","name":"https://github.com/nextcloud/cookbook/blob/a14d6ffc4d45e1447556f68606129dfd6c1505cf/.github/workflows/pull-checks.yml#L67","refsource":"MISC","tags":[],"title":"cookbook/pull-checks.yml at a14d6ffc4d45e1447556f68606129dfd6c1505cf · nextcloud/cookbook · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://github.com/nextcloud/cookbook/commit/489bb744","name":"https://github.com/nextcloud/cookbook/commit/489bb744","refsource":"MISC","tags":[],"title":"Fix typo in workflow file · nextcloud/cookbook@489bb74 · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://github.com/nextcloud/cookbook/security/advisories/GHSA-c5pc-mf2f-xq8h","name":"https://github.com/nextcloud/cookbook/security/advisories/GHSA-c5pc-mf2f-xq8h","refsource":"MISC","tags":[],"title":"pull-checks.yml workflow is vulnerable · Advisory · nextcloud/cookbook · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://securitylab.github.com/research/github-actions-untrusted-input/","name":"https://securitylab.github.com/research/github-actions-untrusted-input/","refsource":"MISC","tags":[],"title":"","mime":"","httpstatus":"200","archivestatus":"200"},{"url":"https://github.com/nextcloud/cookbook/commit/a46d98559e2c64292da9ffb06138cccc2e50ae1b","name":"https://github.com/nextcloud/cookbook/commit/a46d98559e2c64292da9ffb06138cccc2e50ae1b","refsource":"MISC","tags":[],"title":"Fix typo in workflow file · nextcloud/cookbook@a46d985 · GitHub","mime":"text/html","httpstatus":"200","archivestatus":"404"},{"url":"https://www.cve.org/CVERecord?id=CVE-2023-31128","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2023-31128","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[{"cve_year":"2023","cve_id":"31128","vulnerable":"1","versionEndIncluding":"","cpe1":"cpe","cpe2":"2.3","cpe3":"a","cpe4":"nextcloud","cpe5":"cookbook","cpe6":"*","cpe7":"*","cpe8":"*","cpe9":"*","cpe10":"*","cpe11":"*","cpe12":"*","cpe13":"*"}],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[]},"source_records":{"cve_program":{"data_version":"4.0","data_type":"CVE","data_format":"MITRE","CVE_data_meta":{"ID":"CVE-2023-31128","ASSIGNER":"security-advisories@github.com","STATE":"PUBLIC"},"description":{"description_data":[{"lang":"eng","value":"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."}]},"problemtype":{"problemtype_data":[{"description":[{"lang":"eng","value":"CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')","cweId":"CWE-78"}]}]},"affects":{"vendor":{"vendor_data":[{"vendor_name":"nextcloud","product":{"product_data":[{"product_name":"cookbook","version":{"version_data":[{"version_affected":"=","version_value":"master < a46d9855"},{"version_affected":"=","version_value":"main-0.9.x < 489bb744"}]}}]}}]}},"references":{"reference_data":[{"url":"https://github.com/nextcloud/cookbook/security/advisories/GHSA-c5pc-mf2f-xq8h","refsource":"MISC","name":"https://github.com/nextcloud/cookbook/security/advisories/GHSA-c5pc-mf2f-xq8h"},{"url":"https://github.com/nextcloud/cookbook/commit/489bb744","refsource":"MISC","name":"https://github.com/nextcloud/cookbook/commit/489bb744"},{"url":"https://github.com/nextcloud/cookbook/commit/a46d98559e2c64292da9ffb06138cccc2e50ae1b","refsource":"MISC","name":"https://github.com/nextcloud/cookbook/commit/a46d98559e2c64292da9ffb06138cccc2e50ae1b"},{"url":"https://github.com/nextcloud/cookbook/blob/a14d6ffc4d45e1447556f68606129dfd6c1505cf/.github/workflows/pull-checks.yml#L67","refsource":"MISC","name":"https://github.com/nextcloud/cookbook/blob/a14d6ffc4d45e1447556f68606129dfd6c1505cf/.github/workflows/pull-checks.yml#L67"},{"url":"https://securitylab.github.com/research/github-actions-untrusted-input/","refsource":"MISC","name":"https://securitylab.github.com/research/github-actions-untrusted-input/"}]},"source":{"advisory":"GHSA-c5pc-mf2f-xq8h","discovery":"UNKNOWN"},"impact":{"cvss":[{"attackComplexity":"LOW","attackVector":"NETWORK","availabilityImpact":"HIGH","baseScore":8.1,"baseSeverity":"HIGH","confidentialityImpact":"NONE","integrityImpact":"HIGH","privilegesRequired":"LOW","scope":"UNCHANGED","userInteraction":"NONE","vectorString":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H","version":"3.1"}]}},"nvd":{"publishedDate":"2023-05-26 22:15:00","lastModifiedDate":"2023-06-05 14:15:00","problem_types":["CWE-78"],"metrics":{"baseMetricV3":{"cvssV3":{"version":"3.1","vectorString":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","attackVector":"NETWORK","attackComplexity":"LOW","privilegesRequired":"LOW","userInteraction":"NONE","scope":"UNCHANGED","confidentialityImpact":"HIGH","integrityImpact":"HIGH","availabilityImpact":"HIGH","baseScore":8.8,"baseSeverity":"HIGH"},"exploitabilityScore":2.8,"impactScore":5.9}},"configurations":{"CVE_data_version":"4.0","nodes":[{"operator":"OR","children":[],"cpe_match":[{"vulnerable":true,"cpe23Uri":"cpe:2.3:a:nextcloud:cookbook:*:*:*:*:*:*:*:*","versionStartIncluding":"0.9.0","versionEndExcluding":"0.9.19","cpe_name":[]}]}]}},"legacy_mitre":{"record":null,"notes":[]}}}