CVE-2024-26674
Vulnerability from cvelistv5
Published
2024-04-02 07:01
Modified
2024-08-02 00:14
Severity ?
Summary
x86/lib: Revert to _ASM_EXTABLE_UA() for {get,put}_user() fixups
Impacted products
LinuxLinux
LinuxLinux
Show details on NVD website


{
  "containers": {
    "adp": [
      {
        "metrics": [
          {
            "other": {
              "content": {
                "id": "CVE-2024-26674",
                "options": [
                  {
                    "Exploitation": "none"
                  },
                  {
                    "Automatable": "no"
                  },
                  {
                    "Technical Impact": "partial"
                  }
                ],
                "role": "CISA Coordinator",
                "timestamp": "2024-04-02T12:41:02.015400Z",
                "version": "2.0.3"
              },
              "type": "ssvc"
            }
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2024-07-05T17:21:22.719Z",
          "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
          "shortName": "CISA-ADP"
        },
        "title": "CISA ADP Vulnrichment"
      },
      {
        "providerMetadata": {
          "dateUpdated": "2024-08-02T00:14:12.563Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/2aed1b6c33afd8599d01c6532bbecb829480a674"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/2da241c5ed78d0978228a1150735539fe1a60eca"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/8eed4e00a370b37b4e5985ed983dccedd555ea9d"
          }
        ],
        "title": "CVE Program Container"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "arch/x86/lib/getuser.S",
            "arch/x86/lib/putuser.S"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "2aed1b6c33af",
              "status": "affected",
              "version": "b19b74bc99b1",
              "versionType": "git"
            },
            {
              "lessThan": "2da241c5ed78",
              "status": "affected",
              "version": "b19b74bc99b1",
              "versionType": "git"
            },
            {
              "lessThan": "8eed4e00a370",
              "status": "affected",
              "version": "b19b74bc99b1",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "arch/x86/lib/getuser.S",
            "arch/x86/lib/putuser.S"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.4"
            },
            {
              "lessThan": "6.4",
              "status": "unaffected",
              "version": "0",
              "versionType": "custom"
            },
            {
              "lessThanOrEqual": "6.6.*",
              "status": "unaffected",
              "version": "6.6.17",
              "versionType": "custom"
            },
            {
              "lessThanOrEqual": "6.7.*",
              "status": "unaffected",
              "version": "6.7.5",
              "versionType": "custom"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.8",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nx86/lib: Revert to _ASM_EXTABLE_UA() for {get,put}_user() fixups\n\nDuring memory error injection test on kernels \u003e= v6.4, the kernel panics\nlike below. However, this issue couldn\u0027t be reproduced on kernels \u003c= v6.3.\n\n  mce: [Hardware Error]: CPU 296: Machine Check Exception: f Bank 1: bd80000000100134\n  mce: [Hardware Error]: RIP 10:\u003cffffffff821b9776\u003e {__get_user_nocheck_4+0x6/0x20}\n  mce: [Hardware Error]: TSC 411a93533ed ADDR 346a8730040 MISC 86\n  mce: [Hardware Error]: PROCESSOR 0:a06d0 TIME 1706000767 SOCKET 1 APIC 211 microcode 80001490\n  mce: [Hardware Error]: Run the above through \u0027mcelog --ascii\u0027\n  mce: [Hardware Error]: Machine check: Data load in unrecoverable area of kernel\n  Kernel panic - not syncing: Fatal local machine check\n\nThe MCA code can recover from an in-kernel #MC if the fixup type is\nEX_TYPE_UACCESS, explicitly indicating that the kernel is attempting to\naccess userspace memory. However, if the fixup type is EX_TYPE_DEFAULT\nthe only thing that is raised for an in-kernel #MC is a panic.\n\nex_handler_uaccess() would warn if users gave a non-canonical addresses\n(with bit 63 clear) to {get, put}_user(), which was unexpected.\n\nTherefore, commit\n\n  b19b74bc99b1 (\"x86/mm: Rework address range check in get_user() and put_user()\")\n\nreplaced _ASM_EXTABLE_UA() with _ASM_EXTABLE() for {get, put}_user()\nfixups. However, the new fixup type EX_TYPE_DEFAULT results in a panic.\n\nCommit\n\n  6014bc27561f (\"x86-64: make access_ok() independent of LAM\")\n\nadded the check gp_fault_address_ok() right before the WARN_ONCE() in\nex_handler_uaccess() to not warn about non-canonical user addresses due\nto LAM.\n\nWith that in place, revert back to _ASM_EXTABLE_UA() for {get,put}_user()\nexception fixups in order to be able to handle in-kernel MCEs correctly\nagain.\n\n  [ bp: Massage commit message. ]"
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2024-05-29T05:20:37.064Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/2aed1b6c33afd8599d01c6532bbecb829480a674"
        },
        {
          "url": "https://git.kernel.org/stable/c/2da241c5ed78d0978228a1150735539fe1a60eca"
        },
        {
          "url": "https://git.kernel.org/stable/c/8eed4e00a370b37b4e5985ed983dccedd555ea9d"
        }
      ],
      "title": "x86/lib: Revert to _ASM_EXTABLE_UA() for {get,put}_user() fixups",
      "x_generator": {
        "engine": "bippy-a5840b7849dd"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2024-26674",
    "datePublished": "2024-04-02T07:01:39.114Z",
    "dateReserved": "2024-02-19T14:20:24.151Z",
    "dateUpdated": "2024-08-02T00:14:12.563Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.1",
  "meta": {
    "nvd": "{\"cve\":{\"id\":\"CVE-2024-26674\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2024-04-02T07:15:44.033\",\"lastModified\":\"2024-04-02T12:50:42.233\",\"vulnStatus\":\"Awaiting Analysis\",\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nx86/lib: Revert to _ASM_EXTABLE_UA() for {get,put}_user() fixups\\n\\nDuring memory error injection test on kernels \u003e= v6.4, the kernel panics\\nlike below. However, this issue couldn\u0027t be reproduced on kernels \u003c= v6.3.\\n\\n  mce: [Hardware Error]: CPU 296: Machine Check Exception: f Bank 1: bd80000000100134\\n  mce: [Hardware Error]: RIP 10:\u003cffffffff821b9776\u003e {__get_user_nocheck_4+0x6/0x20}\\n  mce: [Hardware Error]: TSC 411a93533ed ADDR 346a8730040 MISC 86\\n  mce: [Hardware Error]: PROCESSOR 0:a06d0 TIME 1706000767 SOCKET 1 APIC 211 microcode 80001490\\n  mce: [Hardware Error]: Run the above through \u0027mcelog --ascii\u0027\\n  mce: [Hardware Error]: Machine check: Data load in unrecoverable area of kernel\\n  Kernel panic - not syncing: Fatal local machine check\\n\\nThe MCA code can recover from an in-kernel #MC if the fixup type is\\nEX_TYPE_UACCESS, explicitly indicating that the kernel is attempting to\\naccess userspace memory. However, if the fixup type is EX_TYPE_DEFAULT\\nthe only thing that is raised for an in-kernel #MC is a panic.\\n\\nex_handler_uaccess() would warn if users gave a non-canonical addresses\\n(with bit 63 clear) to {get, put}_user(), which was unexpected.\\n\\nTherefore, commit\\n\\n  b19b74bc99b1 (\\\"x86/mm: Rework address range check in get_user() and put_user()\\\")\\n\\nreplaced _ASM_EXTABLE_UA() with _ASM_EXTABLE() for {get, put}_user()\\nfixups. However, the new fixup type EX_TYPE_DEFAULT results in a panic.\\n\\nCommit\\n\\n  6014bc27561f (\\\"x86-64: make access_ok() independent of LAM\\\")\\n\\nadded the check gp_fault_address_ok() right before the WARN_ONCE() in\\nex_handler_uaccess() to not warn about non-canonical user addresses due\\nto LAM.\\n\\nWith that in place, revert back to _ASM_EXTABLE_UA() for {get,put}_user()\\nexception fixups in order to be able to handle in-kernel MCEs correctly\\nagain.\\n\\n  [ bp: Massage commit message. ]\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se resolvi\u00f3 la siguiente vulnerabilidad: x86/lib: vuelva a _ASM_EXTABLE_UA() para reparaciones de {get,put}_user() Durante la prueba de inyecci\u00f3n de errores de memoria en kernels \u0026gt;= v6.4, el kernel entra en p\u00e1nico como se muestra a continuaci\u00f3n. Sin embargo, este problema no se pudo reproducir en kernels \u0026lt;= v6.3. mce: [Error de hardware]: CPU 296: Excepci\u00f3n de verificaci\u00f3n de la m\u00e1quina: f Banco 1: bd80000000100134 mce: [Error de hardware]: RIP 10: {__get_user_nocheck_4+0x6/0x20} mce: [Error de hardware]: TSC 411a93533ed ADDR 346a87300 40 MISC 86 mce: [Error de hardware]: PROCESADOR 0:a06d0 HORA 1706000767 SOCKET 1 APIC 211 microc\u00f3digo 80001490 mce: [Error de hardware]: Ejecute lo anterior a trav\u00e9s de \u0027mcelog --ascii\u0027 mce: [Error de hardware]: Verificaci\u00f3n de la m\u00e1quina: Carga de datos en un \u00e1rea irrecuperable del kernel P\u00e1nico del kernel - no se sincroniza: verificaci\u00f3n fatal de la m\u00e1quina local El c\u00f3digo MCA se puede recuperar de un #MC en el kernel si el tipo de reparaci\u00f3n es EX_TYPE_UACCESS, lo que indica expl\u00edcitamente que el kernel est\u00e1 intentando acceder a la memoria del espacio de usuario. Sin embargo, si el tipo de reparaci\u00f3n es EX_TYPE_DEFAULT, lo \u00fanico que se genera para un #MC en el kernel es p\u00e1nico. ex_handler_uaccess() advertir\u00eda si los usuarios proporcionaban direcciones no can\u00f3nicas (con el bit 63 claro) a {get, put}_user(), lo cual era inesperado. Por lo tanto, el commit b19b74bc99b1 (\\\"x86/mm: Reelaborar la verificaci\u00f3n del rango de direcciones en get_user() y put_user()\\\") reemplaz\u00f3 _ASM_EXTABLE_UA() con _ASM_EXTABLE() para las correcciones de {get, put}_user(). Sin embargo, el nuevo tipo de reparaci\u00f3n EX_TYPE_DEFAULT provoca p\u00e1nico. El commit 6014bc27561f (\\\"x86-64: hacer que access_ok() sea independiente de LAM\\\") agreg\u00f3 la verificaci\u00f3n gp_fault_address_ok() justo antes de WARN_ONCE() en ex_handler_uaccess() para no advertir sobre direcciones de usuarios no can\u00f3nicas debido a LAM. Una vez implementado esto, vuelva a _ASM_EXTABLE_UA() para corregir excepciones de {get,put}_user() para poder manejar correctamente los MCE en el kernel nuevamente. [pb: mensaje de commit. ]\"}],\"metrics\":{},\"references\":[{\"url\":\"https://git.kernel.org/stable/c/2aed1b6c33afd8599d01c6532bbecb829480a674\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/2da241c5ed78d0978228a1150735539fe1a60eca\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/8eed4e00a370b37b4e5985ed983dccedd555ea9d\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"}]}}"
  }
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading...

Loading...