Skip to content
Heist/ feed
Back to feed
HighFix available

grub — security advisory

Type: advisorySources: OSVAdvisory ID: ALPINE-CVE-2021-20233

A flaw was found in grub2 in versions prior to 2.06. Setparam_prefix() in the menu rendering code performs a length calculation on the assumption that expressing a quoted single quote will require 3 characters, while it actually requires 4 characters which allows an attacker to corrupt memory by one byte for each quote in the input. The highest threat from this vulnerability is to data confidentiality and integrity as well as system availability.

Products
grub
Affected versions
Not specified
Fixed versions
2.06-r0
CVEs
CVE-2021-20233
Confirmed fixed CVEs
Not specified
Updated in this feed
31 Oct 2026, 22:02 UTC · Revision 1

Source evidence

ALPINE-CVE-2021-20233

core-osv · Original source

Published 3 Mar 2021, 17:15 UTC

A flaw was found in grub2 in versions prior to 2.06. Setparam_prefix() in the menu rendering code performs a length calculation on the assumption that expressing a quoted single quote will require 3 characters, while it actually requires 4 characters which allows an attacker to corrupt memory by one byte for each quote in the input. The highest threat from this vulnerability is to data confidentiality and integrity as well as system availability.

osv:ALPINE-CVE-2021-20233

grub

Fixed versions: 2.06-r0

grub

Fixed versions: 2.06-r0

grub

Fixed versions: 2.06-r0

grub

Fixed versions: 2.06-r0

grub

Fixed versions: 2.06-r0

grub

Fixed versions: 2.06-r0

grub

Fixed versions: 2.06-r0

grub

Fixed versions: 2.06-r0

Complete source record
{
  "id": "e3a14704768174d16a35ea9d43a34d768bae09fcd60af7e9bab1bc24c468376a",
  "url": "https://osv.dev/vulnerability/ALPINE-CVE-2021-20233",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "ALPINE-CVE-2021-20233",
    "summary": "A flaw was found in grub2 in versions prior to 2.06. Setparam_prefix() in the menu rendering code performs a length calculation on the assumption that expressing a quoted single quote will require 3 characters, while it actually requires 4 characters which allows an attacker to corrupt memory by one byte for each quote in the input. The highest threat from this vulnerability is to data confidentiality and integrity as well as system availability.",
    "evidence": "osv:ALPINE-CVE-2021-20233",
    "products": [
      {
        "name": {
          "value": "grub",
          "evidence": "/affected/0/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.06-r0",
            "evidence": "/affected/0/ranges"
          }
        ],
        "affected_versions": []
      },
      {
        "name": {
          "value": "grub",
          "evidence": "/affected/1/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.06-r0",
            "evidence": "/affected/1/ranges"
          }
        ],
        "affected_versions": []
      },
      {
        "name": {
          "value": "grub",
          "evidence": "/affected/2/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.06-r0",
            "evidence": "/affected/2/ranges"
          }
        ],
        "affected_versions": []
      },
      {
        "name": {
          "value": "grub",
          "evidence": "/affected/3/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.06-r0",
            "evidence": "/affected/3/ranges"
          }
        ],
        "affected_versions": []
      },
      {
        "name": {
          "value": "grub",
          "evidence": "/affected/4/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.06-r0",
            "evidence": "/affected/4/ranges"
          }
        ],
        "affected_versions": []
      },
      {
        "name": {
          "value": "grub",
          "evidence": "/affected/5/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.06-r0",
            "evidence": "/affected/5/ranges"
          }
        ],
        "affected_versions": []
      },
      {
        "name": {
          "value": "grub",
          "evidence": "/affected/6/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.06-r0",
            "evidence": "/affected/6/ranges"
          }
        ],
        "affected_versions": []
      },
      {
        "name": {
          "value": "grub",
          "evidence": "/affected/7/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.06-r0",
            "evidence": "/affected/7/ranges"
          }
        ],
        "affected_versions": []
      }
    ],
    "severity": "high",
    "structured": {
      "id": "ALPINE-CVE-2021-20233",
      "aliases": [
        "ALPINE-CVE-2021-20233"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:H"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "2.06-r0"
                }
              ]
            }
          ],
          "package": {
            "name": "grub",
            "purl": "pkg:apk/alpine/grub?arch=source",
            "ecosystem": "Alpine:v3.17"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2021-20233.json"
          },
          "ecosystem_specific": {}
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "2.06-r0"
                }
              ]
            }
          ],
          "package": {
            "name": "grub",
            "purl": "pkg:apk/alpine/grub?arch=source",
            "ecosystem": "Alpine:v3.18"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2021-20233.json"
          },
          "ecosystem_specific": {}
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "2.06-r0"
                }
              ]
            }
          ],
          "package": {
            "name": "grub",
            "purl": "pkg:apk/alpine/grub?arch=source",
            "ecosystem": "Alpine:v3.19"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2021-20233.json"
          },
          "ecosystem_specific": {}
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "2.06-r0"
                }
              ]
            }
          ],
          "package": {
            "name": "grub",
            "purl": "pkg:apk/alpine/grub?arch=source",
            "ecosystem": "Alpine:v3.20"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2021-20233.json"
          },
          "ecosystem_specific": {}
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "2.06-r0"
                }
              ]
            }
          ],
          "package": {
            "name": "grub",
            "purl": "pkg:apk/alpine/grub?arch=source",
            "ecosystem": "Alpine:v3.21"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2021-20233.json"
          },
          "ecosystem_specific": {}
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "2.06-r0"
                }
              ]
            }
          ],
          "package": {
            "name": "grub",
            "purl": "pkg:apk/alpine/grub?arch=source",
            "ecosystem": "Alpine:v3.22"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2021-20233.json"
          },
          "ecosystem_specific": {}
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "2.06-r0"
                }
              ]
            }
          ],
          "package": {
            "name": "grub",
            "purl": "pkg:apk/alpine/grub?arch=source",
            "ecosystem": "Alpine:v3.23"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2021-20233.json"
          },
          "ecosystem_specific": {}
        },
        {
          "ranges": [
            {
              "type": "ECOSYSTEM",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "2.06-r0"
                }
              ]
            }
          ],
          "package": {
            "name": "grub",
            "purl": "pkg:apk/alpine/grub?arch=source",
            "ecosystem": "Alpine:v3.24"
          },
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2021-20233.json"
          },
          "ecosystem_specific": {}
        }
      ],
      "modified": "2026-10-23T17:17:56.142296050Z",
      "provider": "osv",
      "upstream": [
        "CVE-2021-20233"
      ],
      "references": [
        "https://security.alpinelinux.org/vuln/CVE-2021-20233"
      ]
    },
    "related_cves": [
      {
        "value": "CVE-2021-20233",
        "evidence": "/upstream"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 415282,
  "published_at": "2021-03-03T17:15:12.037+00:00"
}