CVE-2022-49425 (GCVE-0-2022-49425)

Vulnerability from cvelistv5 – Published: 2025-02-26 02:12 – Updated: 2026-05-11 18:59
VLAI
Title
f2fs: fix dereference of stale list iterator after loop body
Summary
In the Linux kernel, the following vulnerability has been resolved: f2fs: fix dereference of stale list iterator after loop body The list iterator variable will be a bogus pointer if no break was hit. Dereferencing it (cur->page in this case) could load an out-of-bounds/undefined value making it unsafe to use that in the comparision to determine if the specific element was found. Since 'cur->page' *can* be out-ouf-bounds it cannot be guaranteed that by chance (or intention of an attacker) it matches the value of 'page' even though the correct element was not found. This is fixed by using a separate list iterator variable for the loop and only setting the original variable if a suitable element was found. Then determing if the element was found is simply checking if the variable is set.
Assigner
Impacted products
Vendor Product Version
Linux Linux Affected: 8c242db9b8c01b252290e23827163787f07e01d1 , < 385edd3ce5b4b1e9d31f474a5e35a39779ec1110 (git)
Affected: 8c242db9b8c01b252290e23827163787f07e01d1 , < 5e47a7add3dda7f236548c5ec3017776dc2a729f (git)
Affected: 8c242db9b8c01b252290e23827163787f07e01d1 , < 51d584704d18e60fa473823654f35611c777b291 (git)
Affected: 8c242db9b8c01b252290e23827163787f07e01d1 , < 45b2b7d7108ae1e25a5036cab04ab9273e792332 (git)
Affected: 8c242db9b8c01b252290e23827163787f07e01d1 , < b26e1c777890e4b938136deb8ec07a29f33862e4 (git)
Affected: 8c242db9b8c01b252290e23827163787f07e01d1 , < ed7efc472c00986dcd6903ab6ed165c7fa167674 (git)
Affected: 8c242db9b8c01b252290e23827163787f07e01d1 , < 2aaf51dd39afb6d01d13f1e6fe20b684733b37d5 (git)
Create a notification for this product.
Linux Linux Affected: 4.12
Unaffected: 0 , < 4.12 (semver)
Unaffected: 4.19.247 , ≤ 4.19.* (semver)
Unaffected: 5.4.198 , ≤ 5.4.* (semver)
Unaffected: 5.10.121 , ≤ 5.10.* (semver)
Unaffected: 5.15.46 , ≤ 5.15.* (semver)
Unaffected: 5.17.14 , ≤ 5.17.* (semver)
Unaffected: 5.18.3 , ≤ 5.18.* (semver)
Unaffected: 5.19 , ≤ * (original_commit_for_fix)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "fs/f2fs/segment.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "385edd3ce5b4b1e9d31f474a5e35a39779ec1110",
              "status": "affected",
              "version": "8c242db9b8c01b252290e23827163787f07e01d1",
              "versionType": "git"
            },
            {
              "lessThan": "5e47a7add3dda7f236548c5ec3017776dc2a729f",
              "status": "affected",
              "version": "8c242db9b8c01b252290e23827163787f07e01d1",
              "versionType": "git"
            },
            {
              "lessThan": "51d584704d18e60fa473823654f35611c777b291",
              "status": "affected",
              "version": "8c242db9b8c01b252290e23827163787f07e01d1",
              "versionType": "git"
            },
            {
              "lessThan": "45b2b7d7108ae1e25a5036cab04ab9273e792332",
              "status": "affected",
              "version": "8c242db9b8c01b252290e23827163787f07e01d1",
              "versionType": "git"
            },
            {
              "lessThan": "b26e1c777890e4b938136deb8ec07a29f33862e4",
              "status": "affected",
              "version": "8c242db9b8c01b252290e23827163787f07e01d1",
              "versionType": "git"
            },
            {
              "lessThan": "ed7efc472c00986dcd6903ab6ed165c7fa167674",
              "status": "affected",
              "version": "8c242db9b8c01b252290e23827163787f07e01d1",
              "versionType": "git"
            },
            {
              "lessThan": "2aaf51dd39afb6d01d13f1e6fe20b684733b37d5",
              "status": "affected",
              "version": "8c242db9b8c01b252290e23827163787f07e01d1",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "fs/f2fs/segment.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "4.12"
            },
            {
              "lessThan": "4.12",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "4.19.*",
              "status": "unaffected",
              "version": "4.19.247",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.4.*",
              "status": "unaffected",
              "version": "5.4.198",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.10.*",
              "status": "unaffected",
              "version": "5.10.121",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.15.*",
              "status": "unaffected",
              "version": "5.15.46",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.17.*",
              "status": "unaffected",
              "version": "5.17.14",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.18.*",
              "status": "unaffected",
              "version": "5.18.3",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "5.19",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "4.19.247",
                  "versionStartIncluding": "4.12",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.4.198",
                  "versionStartIncluding": "4.12",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.10.121",
                  "versionStartIncluding": "4.12",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.15.46",
                  "versionStartIncluding": "4.12",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.17.14",
                  "versionStartIncluding": "4.12",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.18.3",
                  "versionStartIncluding": "4.12",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.19",
                  "versionStartIncluding": "4.12",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nf2fs: fix dereference of stale list iterator after loop body\n\nThe list iterator variable will be a bogus pointer if no break was hit.\nDereferencing it (cur-\u003epage in this case) could load an out-of-bounds/undefined\nvalue making it unsafe to use that in the comparision to determine if the\nspecific element was found.\n\nSince \u0027cur-\u003epage\u0027 *can* be out-ouf-bounds it cannot be guaranteed that\nby chance (or intention of an attacker) it matches the value of \u0027page\u0027\neven though the correct element was not found.\n\nThis is fixed by using a separate list iterator variable for the loop\nand only setting the original variable if a suitable element was found.\nThen determing if the element was found is simply checking if the\nvariable is set."
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-05-11T18:59:34.274Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/385edd3ce5b4b1e9d31f474a5e35a39779ec1110"
        },
        {
          "url": "https://git.kernel.org/stable/c/5e47a7add3dda7f236548c5ec3017776dc2a729f"
        },
        {
          "url": "https://git.kernel.org/stable/c/51d584704d18e60fa473823654f35611c777b291"
        },
        {
          "url": "https://git.kernel.org/stable/c/45b2b7d7108ae1e25a5036cab04ab9273e792332"
        },
        {
          "url": "https://git.kernel.org/stable/c/b26e1c777890e4b938136deb8ec07a29f33862e4"
        },
        {
          "url": "https://git.kernel.org/stable/c/ed7efc472c00986dcd6903ab6ed165c7fa167674"
        },
        {
          "url": "https://git.kernel.org/stable/c/2aaf51dd39afb6d01d13f1e6fe20b684733b37d5"
        }
      ],
      "title": "f2fs: fix dereference of stale list iterator after loop body",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2022-49425",
    "datePublished": "2025-02-26T02:12:46.702Z",
    "dateReserved": "2025-02-26T02:08:31.569Z",
    "dateUpdated": "2026-05-11T18:59:34.274Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "epss": {
      "cve": "CVE-2022-49425",
      "date": "2026-07-19",
      "epss": "0.00247",
      "percentile": "0.15891"
    },
    "nvd": "{\"cve\":{\"id\":\"CVE-2022-49425\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2025-02-26T07:01:18.977\",\"lastModified\":\"2026-06-17T05:18:00.863\",\"vulnStatus\":\"Analyzed\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nf2fs: fix dereference of stale list iterator after loop body\\n\\nThe list iterator variable will be a bogus pointer if no break was hit.\\nDereferencing it (cur-\u003epage in this case) could load an out-of-bounds/undefined\\nvalue making it unsafe to use that in the comparision to determine if the\\nspecific element was found.\\n\\nSince \u0027cur-\u003epage\u0027 *can* be out-ouf-bounds it cannot be guaranteed that\\nby chance (or intention of an attacker) it matches the value of \u0027page\u0027\\neven though the correct element was not found.\\n\\nThis is fixed by using a separate list iterator variable for the loop\\nand only setting the original variable if a suitable element was found.\\nThen determing if the element was found is simply checking if the\\nvariable is set.\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: f2fs: se corrige la desreferencia del iterador de lista obsoleto despu\u00e9s del cuerpo del bucle La variable del iterador de lista ser\u00e1 un puntero falso si no se alcanz\u00f3 ninguna interrupci\u00f3n. Desreferenciarlo (cur-\u0026gt;page en este caso) podr\u00eda cargar un valor fuera de los l\u00edmites/indefinido, lo que hace que no sea seguro usarlo en la comparaci\u00f3n para determinar si se encontr\u00f3 el elemento espec\u00edfico. Dado que \u0027cur-\u0026gt;page\u0027 *puede* estar fuera de los l\u00edmites, no se puede garantizar que por casualidad (o intenci\u00f3n de un atacante) coincida con el valor de \u0027page\u0027 aunque no se haya encontrado el elemento correcto. Esto se soluciona utilizando una variable de iterador de lista separada para el bucle y solo configurando la variable original si se encontr\u00f3 un elemento adecuado. Luego, determinar si se encontr\u00f3 el elemento es simplemente verificar si la variable est\u00e1 configurada.\"}],\"affected\":[{\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"affectedData\":[{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"unaffected\",\"programFiles\":[\"fs/f2fs/segment.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"8c242db9b8c01b252290e23827163787f07e01d1\",\"lessThan\":\"385edd3ce5b4b1e9d31f474a5e35a39779ec1110\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"8c242db9b8c01b252290e23827163787f07e01d1\",\"lessThan\":\"5e47a7add3dda7f236548c5ec3017776dc2a729f\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"8c242db9b8c01b252290e23827163787f07e01d1\",\"lessThan\":\"51d584704d18e60fa473823654f35611c777b291\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"8c242db9b8c01b252290e23827163787f07e01d1\",\"lessThan\":\"45b2b7d7108ae1e25a5036cab04ab9273e792332\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"8c242db9b8c01b252290e23827163787f07e01d1\",\"lessThan\":\"b26e1c777890e4b938136deb8ec07a29f33862e4\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"8c242db9b8c01b252290e23827163787f07e01d1\",\"lessThan\":\"ed7efc472c00986dcd6903ab6ed165c7fa167674\",\"versionType\":\"git\",\"status\":\"affected\"},{\"version\":\"8c242db9b8c01b252290e23827163787f07e01d1\",\"lessThan\":\"2aaf51dd39afb6d01d13f1e6fe20b684733b37d5\",\"versionType\":\"git\",\"status\":\"affected\"}]},{\"vendor\":\"Linux\",\"product\":\"Linux\",\"defaultStatus\":\"affected\",\"programFiles\":[\"fs/f2fs/segment.c\"],\"repo\":\"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\",\"versions\":[{\"version\":\"4.12\",\"status\":\"affected\"},{\"version\":\"0\",\"lessThan\":\"4.12\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"4.19.247\",\"lessThanOrEqual\":\"4.19.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.4.198\",\"lessThanOrEqual\":\"5.4.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.10.121\",\"lessThanOrEqual\":\"5.10.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.15.46\",\"lessThanOrEqual\":\"5.15.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.17.14\",\"lessThanOrEqual\":\"5.17.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.18.3\",\"lessThanOrEqual\":\"5.18.*\",\"versionType\":\"semver\",\"status\":\"unaffected\"},{\"version\":\"5.19\",\"lessThanOrEqual\":\"*\",\"versionType\":\"original_commit_for_fix\",\"status\":\"unaffected\"}]}]}],\"metrics\":{\"cvssMetricV31\":[{\"source\":\"nvd@nist.gov\",\"type\":\"Primary\",\"cvssData\":{\"version\":\"3.1\",\"vectorString\":\"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H\",\"baseScore\":5.5,\"baseSeverity\":\"MEDIUM\",\"attackVector\":\"LOCAL\",\"attackComplexity\":\"LOW\",\"privilegesRequired\":\"LOW\",\"userInteraction\":\"NONE\",\"scope\":\"UNCHANGED\",\"confidentialityImpact\":\"NONE\",\"integrityImpact\":\"NONE\",\"availabilityImpact\":\"HIGH\"},\"exploitabilityScore\":1.8,\"impactScore\":3.6}]},\"weaknesses\":[{\"source\":\"nvd@nist.gov\",\"type\":\"Primary\",\"description\":[{\"lang\":\"en\",\"value\":\"CWE-476\"}]}],\"configurations\":[{\"nodes\":[{\"operator\":\"OR\",\"negate\":false,\"cpeMatch\":[{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"4.12\",\"versionEndExcluding\":\"4.19.247\",\"matchCriteriaId\":\"14D48FB4-4920-47B2-961A-E24AFEC157E4\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"4.20\",\"versionEndExcluding\":\"5.4.198\",\"matchCriteriaId\":\"3EC49633-14DE-4EBD-BB80-76AE2E3EABB9\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.5\",\"versionEndExcluding\":\"5.10.121\",\"matchCriteriaId\":\"34ACD872-E5BC-401C-93D5-B357A62426E0\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.11\",\"versionEndExcluding\":\"5.15.46\",\"matchCriteriaId\":\"20D41697-0E8B-4B7D-8842-F17BF2AA21E1\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.16\",\"versionEndExcluding\":\"5.17.14\",\"matchCriteriaId\":\"15E2DD33-2255-4B76-9C15-04FF8CBAB252\"},{\"vulnerable\":true,\"criteria\":\"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\",\"versionStartIncluding\":\"5.18\",\"versionEndExcluding\":\"5.18.3\",\"matchCriteriaId\":\"8E122216-2E9E-4B3E-B7B8-D575A45BA3C2\"}]}]}],\"references\":[{\"url\":\"https://git.kernel.org/stable/c/2aaf51dd39afb6d01d13f1e6fe20b684733b37d5\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/385edd3ce5b4b1e9d31f474a5e35a39779ec1110\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/45b2b7d7108ae1e25a5036cab04ab9273e792332\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/51d584704d18e60fa473823654f35611c777b291\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/5e47a7add3dda7f236548c5ec3017776dc2a729f\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/b26e1c777890e4b938136deb8ec07a29f33862e4\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]},{\"url\":\"https://git.kernel.org/stable/c/ed7efc472c00986dcd6903ab6ed165c7fa167674\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"tags\":[\"Patch\"]}]}}",
    "redhat_vex": {
      "aggregate_severity": "None",
      "current_release_date": "2026-06-30T10:29:04+00:00",
      "cve": "CVE-2022-49425",
      "id": "CVE-2022-49425",
      "initial_release_date": "2022-01-01T00:00:00+00:00",
      "product_status:known_not_affected": "274",
      "source": "Red Hat CSAF VEX",
      "status": "final",
      "title": "kernel: f2fs: fix dereference of stale list iterator after loop body",
      "url": "https://security.access.redhat.com/data/csaf/v2/vex/2022/cve-2022-49425.json",
      "version": "3"
    }
  }
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.

Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…