| Seq | Timestamp | Type | Name | Duration |
|---|---|---|---|---|
| 0/0 | 2026/10/27 19:05 | flow | patch-triage |
3mArgs:null Results: {
"EnableConfigs": null,
"FocusSymbols": [],
"KMSANReasoning": "",
"NeedsKMSAN": false,
"Reasoning": "The patch introduces the 'mseal_system_mappings=' early boot command-line parameter and associated Kconfig options to enable or disable sealing of system mappings at boot time. The only C function introduced is early_mseal_sysmap(), which is marked __init and only executes during early boot before userspace starts; its code is discarded from memory (free_initmem()) and is structurally unreachable during syzkaller runtime fuzzing. The change in include/linux/mm.h simply evaluates a read-only boot flag (mseal_sysmap_enabled) in the VM_SEALED_SYSMAP macro to choose between existing flags (VM_SEALED or VM_NONE), introducing no new runtime logic, data structures, or assertions. The remainder of the patch consists of documentation, Kconfig updates, and userspace selftests. Hence, there is no reachable executable kernel logic worth fuzzing.",
"WorthFuzzing": false
} |
| 1/1 | 2026/10/27 19:05 | action | read-patch-diff |
0mArgs:null Results: {
"PatchDiff": "commit d092e5f562ae4d2916894f593612eb94d6be0d51\nAuthor: syz-cluster \u003ctriage@syzkaller.com\u003e\nDate: Tue Oct 27 19:05:30 2026 +0000\n\n syz-cluster: applied patch under review\n\ndiff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt\nindex e75344f4e0cdef..628f4cccd38ee9 100644\n--- a/Documentation/admin-guide/kernel-parameters.txt\n+++ b/Documentation/admin-guide/kernel-parameters.txt\n@@ -4270,6 +4270,13 @@ Kernel parameters\n \tMTD_Region=\t[MTD] Format:\n \t\t\t\u003cname\u003e,\u003cregion-number\u003e[,\u003cbase\u003e,\u003csize\u003e,\u003cbuswidth\u003e,\u003caltbuswidth\u003e]\n \n+\tmseal_system_mappings=\n+\t\t\t[KNL,EARLY] Under CONFIG_MSEAL_SYSTEM_MAPPINGS,\n+\t\t\twhether system mappings are sealed for this boot.\n+\t\t\tSee Documentation/userspace-api/mseal.rst.\n+\t\t\tFormat: \u003cbool\u003e\n+\t\t\tDefault set by CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON.\n+\n \tmtdparts=\t[MTD]\n \t\t\tSee drivers/mtd/parsers/cmdlinepart.c\n \ndiff --git a/Documentation/userspace-api/mseal.rst b/Documentation/userspace-api/mseal.rst\nindex c039d782f9f5bb..c1d6dbb006dcc6 100644\n--- a/Documentation/userspace-api/mseal.rst\n+++ b/Documentation/userspace-api/mseal.rst\n@@ -142,7 +142,10 @@ Use cases\n \n If supported by an architecture (CONFIG_ARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGS),\n the CONFIG_MSEAL_SYSTEM_MAPPINGS seals all system mappings of this\n- architecture.\n+ architecture. The kernel command line parameter\n+ ``mseal_system_mappings=0|1`` turns this off or on at boot. The default is\n+ set by CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON, which is off with\n+ CONFIG_CHECKPOINT_RESTORE.\n \n WARNING: This feature breaks programs which rely on relocating\n or unmapping system mappings. Known broken software at the time\ndiff --git a/include/linux/mm.h b/include/linux/mm.h\nindex 5f82be0fcde582..2329d81b7d46c3 100644\n--- a/include/linux/mm.h\n+++ b/include/linux/mm.h\n@@ -568,7 +568,8 @@ enum {\n #define VM_STACK_FLAGS vma_flags_to_legacy(VMA_STACK_FLAGS)\n \n #ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS\n-#define VM_SEALED_SYSMAP\tVM_SEALED\n+extern bool mseal_sysmap_enabled;\n+#define VM_SEALED_SYSMAP\t(mseal_sysmap_enabled ? VM_SEALED : VM_NONE)\n #else\n #define VM_SEALED_SYSMAP\tVM_NONE\n #endif\ndiff --git a/mm/mseal.c b/mm/mseal.c\nindex 7a8ac66dc215f3..8f2f2a149915d7 100644\n--- a/mm/mseal.c\n+++ b/mm/mseal.c\n@@ -7,6 +7,8 @@\n * Author: Jeff Xu \u003cjeffxu@chromium.org\u003e\n */\n \n+#include \u003clinux/init.h\u003e\n+#include \u003clinux/kstrtox.h\u003e\n #include \u003clinux/mempolicy.h\u003e\n #include \u003clinux/minmax.h\u003e\n #include \u003clinux/mman.h\u003e\n@@ -16,6 +18,17 @@\n #include \u003clinux/sched.h\u003e\n #include \"internal.h\"\n \n+#ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS\n+bool mseal_sysmap_enabled __ro_after_init =\n+\tIS_ENABLED(CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON);\n+\n+static int __init early_mseal_sysmap(char *buf)\n+{\n+\treturn kstrtobool(buf, \u0026mseal_sysmap_enabled);\n+}\n+early_param(\"mseal_system_mappings\", early_mseal_sysmap);\n+#endif\n+\n static bool range_contains_unmapped(unsigned long start, unsigned long end)\n {\n \tVMA_ITERATOR(vmi, current-\u003emm, start);\ndiff --git a/security/Kconfig b/security/Kconfig\nindex f7bf6cdc6229eb..6a6323e0897d85 100644\n--- a/security/Kconfig\n+++ b/security/Kconfig\n@@ -53,7 +53,6 @@ config MSEAL_SYSTEM_MAPPINGS\n \tbool \"mseal system mappings\"\n \tdepends on 64BIT\n \tdepends on ARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGS\n-\tdepends on !CHECKPOINT_RESTORE\n \thelp\n \t Apply mseal on system mappings.\n \t The system mappings includes vdso, vvar, vvar_vclock,\n@@ -67,9 +66,25 @@ config MSEAL_SYSTEM_MAPPINGS\n \t of writing includes CHECKPOINT_RESTORE, UML, gVisor, rr. Therefore\n \t this config can't be enabled universally.\n \n+\t The \"mseal_system_mappings=\" kernel command line parameter can\n+\t be used to enable or disable sealing at boot. The default is set\n+\t by MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON.\n+\n \t For complete descriptions of memory sealing, please see\n \t Documentation/userspace-api/mseal.rst\n \n+config MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON\n+\tbool \"Seal system mappings by default\"\n+\tdepends on MSEAL_SYSTEM_MAPPINGS\n+\tdepends on !CHECKPOINT_RESTORE\n+\tdefault y\n+\thelp\n+\t Sets the default for the \"mseal_system_mappings=\" boot parameter.\n+\n+\t With CHECKPOINT_RESTORE=y, system mappings are only sealed when\n+\t \"mseal_system_mappings=1\" is given, since CRIU needs to move them\n+\t when restoring a process.\n+\n config SECURITY\n \tbool \"Enable different security models\"\n \tdepends on SYSFS\ndiff --git a/tools/testing/selftests/mseal_system_mappings/Makefile b/tools/testing/selftests/mseal_system_mappings/Makefile\nindex 2b4504e2f52f67..d3b88af06c9437 100644\n--- a/tools/testing/selftests/mseal_system_mappings/Makefile\n+++ b/tools/testing/selftests/mseal_system_mappings/Makefile\n@@ -1,6 +1,8 @@\n # SPDX-License-Identifier: GPL-2.0-only\n CFLAGS += -std=c99 -pthread -Wall $(KHDR_INCLUDES)\n \n+LDLIBS += -lz\n+\n TEST_GEN_PROGS := sysmap_is_sealed\n \n include ../lib.mk\ndiff --git a/tools/testing/selftests/mseal_system_mappings/config b/tools/testing/selftests/mseal_system_mappings/config\nindex 675cb9f37b8618..493bbf834a8434 100644\n--- a/tools/testing/selftests/mseal_system_mappings/config\n+++ b/tools/testing/selftests/mseal_system_mappings/config\n@@ -1 +1,3 @@\n CONFIG_MSEAL_SYSTEM_MAPPINGS=y\n+CONFIG_IKCONFIG=y\n+CONFIG_IKCONFIG_PROC=y\ndiff --git a/tools/testing/selftests/mseal_system_mappings/sysmap_is_sealed.c b/tools/testing/selftests/mseal_system_mappings/sysmap_is_sealed.c\nindex cb0ca6ed7ebee6..83b4fadfbfe798 100644\n--- a/tools/testing/selftests/mseal_system_mappings/sysmap_is_sealed.c\n+++ b/tools/testing/selftests/mseal_system_mappings/sysmap_is_sealed.c\n@@ -1,15 +1,18 @@\n // SPDX-License-Identifier: GPL-2.0-only\n /*\n- * test system mappings are sealed when\n- * KCONFIG_MSEAL_SYSTEM_MAPPINGS=y\n+ * Test system mapping sealing and the mseal_system_mappings= boot parameter.\n */\n \n #define _GNU_SOURCE\n #include \u003cstdio.h\u003e\n #include \u003cerrno.h\u003e\n+#include \u003cctype.h\u003e\n #include \u003cunistd.h\u003e\n #include \u003cstring.h\u003e\n #include \u003cstdbool.h\u003e\n+#include \u003csys/mman.h\u003e\n+#include \u003csys/utsname.h\u003e\n+#include \u003czlib.h\u003e\n \n #include \"kselftest.h\"\n #include \"kselftest_harness.h\"\n@@ -17,6 +20,111 @@\n #define VMFLAGS \"VmFlags:\"\n #define MSEAL_FLAGS \"sl\"\n #define MAX_LINE_LEN 512\n+#define SYSMAP_PARAM \"mseal_system_mappings=\"\n+\n+static int parse_bool(const char *s, bool *res)\n+{\n+\tif (!s)\n+\t\treturn -EINVAL;\n+\n+\tswitch (tolower((unsigned char)s[0])) {\n+\tcase 'e':\n+\tcase 'y':\n+\tcase 't':\n+\tcase '1':\n+\t\t*res = true;\n+\t\treturn 0;\n+\tcase 'd':\n+\tcase 'n':\n+\tcase 'f':\n+\tcase '0':\n+\t\t*res = false;\n+\t\treturn 0;\n+\tcase 'o':\n+\t\tswitch (tolower((unsigned char)s[1])) {\n+\t\tcase 'n':\n+\t\t\t*res = true;\n+\t\t\treturn 0;\n+\t\tcase 'f':\n+\t\t\t*res = false;\n+\t\t\treturn 0;\n+\t\t}\n+\t\tbreak;\n+\t}\n+\n+\treturn -EINVAL;\n+}\n+\n+static int sysmap_config_expected(int *enabled)\n+{\n+\tstruct utsname uts;\n+\tchar line[MAX_LINE_LEN];\n+\tbool default_on = false;\n+\tgzFile config;\n+\tint expected;\n+\n+\t*enabled = -1;\n+\tconfig = gzopen(\"/proc/config.gz\", \"rb\");\n+\tif (!config \u0026\u0026 !uname(\u0026uts)) {\n+\t\tsnprintf(line, sizeof(line), \"/boot/config-%s\", uts.release);\n+\t\tconfig = gzopen(line, \"rb\");\n+\t}\n+\tif (!config)\n+\t\treturn -1;\n+\n+\twhile (gzgets(config, line, sizeof(line))) {\n+\t\tif (!strcmp(line, \"CONFIG_MSEAL_SYSTEM_MAPPINGS=y\\n\"))\n+\t\t\t*enabled = 1;\n+\t\telse if (!strcmp(line,\n+\t\t\t\t \"# CONFIG_MSEAL_SYSTEM_MAPPINGS is not set\\n\"))\n+\t\t\t*enabled = 0;\n+\t\telse if (!strcmp(line,\n+\t\t\t\t \"CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON=y\\n\"))\n+\t\t\tdefault_on = true;\n+\t}\n+\tif (!gzeof(config))\n+\t\t*enabled = -1;\n+\texpected = *enabled \u003c 0 ? -1 : *enabled \u0026\u0026 default_on;\n+\tgzclose(config);\n+\treturn expected;\n+}\n+\n+static int sysmap_sealed_expected(void)\n+{\n+\tchar cmdline[4096], *tok, *save;\n+\tint enabled, sealed;\n+\tbool value;\n+\tsize_t len;\n+\tFILE *f;\n+\n+\tsealed = sysmap_config_expected(\u0026enabled);\n+\tif (!enabled)\n+\t\treturn 0;\n+\n+\tf = fopen(\"/proc/cmdline\", \"r\");\n+\tif (!f)\n+\t\treturn -1;\n+\tlen = fread(cmdline, 1, sizeof(cmdline) - 1, f);\n+\tif (ferror(f) || !feof(f)) {\n+\t\tfclose(f);\n+\t\treturn -1;\n+\t}\n+\tfclose(f);\n+\tcmdline[len] = '\\0';\n+\n+\tfor (tok = strtok_r(cmdline, \" \\t\\n\", \u0026save); tok;\n+\t tok = strtok_r(NULL, \" \\t\\n\", \u0026save)) {\n+\t\tif (!strcmp(tok, \"--\"))\n+\t\t\tbreak;\n+\t\tif (strncmp(tok, SYSMAP_PARAM, strlen(SYSMAP_PARAM)))\n+\t\t\tcontinue;\n+\n+\t\tif (!parse_bool(tok + strlen(SYSMAP_PARAM), \u0026value))\n+\t\t\tsealed = value;\n+\t}\n+\n+\treturn sealed;\n+}\n \n bool has_mapping(char *name, FILE *maps)\n {\n@@ -30,7 +138,7 @@ bool has_mapping(char *name, FILE *maps)\n \treturn false;\n }\n \n-bool mapping_is_sealed(char *name, FILE *maps)\n+int mapping_is_sealed(FILE *maps)\n {\n \tchar line[MAX_LINE_LEN];\n \n@@ -43,7 +151,7 @@ bool mapping_is_sealed(char *name, FILE *maps)\n \t\t}\n \t}\n \n-\treturn false;\n+\treturn -1;\n }\n \n FIXTURE(basic) {\n@@ -67,53 +175,153 @@ FIXTURE_TEARDOWN(basic)\n FIXTURE_VARIANT(basic)\n {\n \tchar *name;\n-\tbool sealed;\n+\tbool sysmap;\n };\n \n FIXTURE_VARIANT_ADD(basic, vdso) {\n \t.name = \"[vdso]\",\n-\t.sealed = true,\n+\t.sysmap = true,\n };\n \n FIXTURE_VARIANT_ADD(basic, vvar) {\n \t.name = \"[vvar]\",\n-\t.sealed = true,\n+\t.sysmap = true,\n };\n \n FIXTURE_VARIANT_ADD(basic, vvar_vclock) {\n \t.name = \"[vvar_vclock]\",\n-\t.sealed = true,\n+\t.sysmap = true,\n };\n \n FIXTURE_VARIANT_ADD(basic, sigpage) {\n \t.name = \"[sigpage]\",\n-\t.sealed = true,\n+\t.sysmap = true,\n };\n \n FIXTURE_VARIANT_ADD(basic, vectors) {\n \t.name = \"[vectors]\",\n-\t.sealed = true,\n+\t.sysmap = true,\n };\n \n FIXTURE_VARIANT_ADD(basic, uprobes) {\n \t.name = \"[uprobes]\",\n-\t.sealed = true,\n+\t.sysmap = true,\n };\n \n FIXTURE_VARIANT_ADD(basic, stack) {\n \t.name = \"[stack]\",\n-\t.sealed = false,\n+\t.sysmap = false,\n };\n \n TEST_F(basic, check_sealed)\n {\n+\tint expected = 0, sealed;\n+\n \tif (!has_mapping(variant-\u003ename, self-\u003emaps)) {\n \t\tSKIP(return, \"could not find the mapping, %s\",\n \t\t\tvariant-\u003ename);\n \t}\n \n-\tEXPECT_EQ(variant-\u003esealed,\n-\t\tmapping_is_sealed(variant-\u003ename, self-\u003emaps));\n+\tsealed = mapping_is_sealed(self-\u003emaps);\n+\tif (sealed \u003c 0)\n+\t\tSKIP(return, \"could not read the mapping's sealing state\");\n+\tif (variant-\u003esysmap) {\n+\t\texpected = sysmap_sealed_expected();\n+\t\tif (expected \u003c 0)\n+\t\t\tSKIP(return, \"could not determine the expected sealing state\");\n+\t}\n+\tEXPECT_EQ(expected, sealed);\n };\n \n+static bool find_vdso(unsigned long *start, unsigned long *end)\n+{\n+\tchar line[MAX_LINE_LEN];\n+\tbool found = false;\n+\tFILE *maps;\n+\n+\tmaps = fopen(\"/proc/self/maps\", \"r\");\n+\tif (!maps)\n+\t\treturn false;\n+\n+\twhile (fgets(line, sizeof(line), maps)) {\n+\t\tif (strstr(line, \"[vdso]\") \u0026\u0026\n+\t\t sscanf(line, \"%lx-%lx\", start, end) == 2) {\n+\t\t\tfound = true;\n+\t\t\tbreak;\n+\t\t}\n+\t}\n+\n+\tfclose(maps);\n+\treturn found;\n+}\n+\n+static int vdso_is_sealed(void)\n+{\n+\tint sealed = -1;\n+\tFILE *maps;\n+\n+\tmaps = fopen(\"/proc/self/smaps\", \"r\");\n+\tif (!maps)\n+\t\treturn -1;\n+\tif (has_mapping(\"[vdso]\", maps))\n+\t\tsealed = mapping_is_sealed(maps);\n+\tfclose(maps);\n+\treturn sealed;\n+}\n+\n+/*\n+ * Unmapping or moving [vdso] must fail with EPERM when it is sealed. When it\n+ * is not sealed, it succeeds and leaves glibc with a stale vdso pointer, which\n+ * is fine because each test runs in its own forked child.\n+ */\n+TEST(vdso_munmap)\n+{\n+\tint sealed;\n+\tunsigned long start, end;\n+\tint ret;\n+\n+\tif (!find_vdso(\u0026start, \u0026end))\n+\t\tSKIP(return, \"could not find the mapping, [vdso]\");\n+\tsealed = vdso_is_sealed();\n+\tif (sealed \u003c 0)\n+\t\tSKIP(return, \"could not read the [vdso] sealing state\");\n+\n+\tret = munmap((void *)start, end - start);\n+\tif (sealed) {\n+\t\tEXPECT_EQ(-1, ret);\n+\t\tEXPECT_EQ(EPERM, errno);\n+\t} else {\n+\t\tEXPECT_EQ(0, ret);\n+\t}\n+\tEXPECT_EQ(sealed, find_vdso(\u0026start, \u0026end));\n+}\n+\n+TEST(vdso_mremap)\n+{\n+\tint sealed;\n+\tunsigned long start, end, size, new_start;\n+\tvoid *dst, *ret;\n+\n+\tif (!find_vdso(\u0026start, \u0026end))\n+\t\tSKIP(return, \"could not find the mapping, [vdso]\");\n+\tsealed = vdso_is_sealed();\n+\tif (sealed \u003c 0)\n+\t\tSKIP(return, \"could not read the [vdso] sealing state\");\n+\tsize = end - start;\n+\n+\tdst = mmap(NULL, size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);\n+\tASSERT_NE(MAP_FAILED, dst);\n+\n+\tret = mremap((void *)start, size, size, MREMAP_MAYMOVE | MREMAP_FIXED,\n+\t\t dst);\n+\tif (sealed) {\n+\t\tEXPECT_EQ(MAP_FAILED, ret);\n+\t\tEXPECT_EQ(EPERM, errno);\n+\t} else {\n+\t\tEXPECT_EQ(dst, ret);\n+\t}\n+\tASSERT_TRUE(find_vdso(\u0026new_start, \u0026end));\n+\tEXPECT_EQ(sealed ? start : (unsigned long)dst, new_start);\n+}\n+\n TEST_HARNESS_MAIN\n"
} |
| 2/1 | 2026/10/27 19:05 | agent | patch-evaluator |
3mModel:core Args: null Results: {
"EnableConfigs": null,
"FocusSymbols": [],
"Reasoning": "The patch introduces the 'mseal_system_mappings=' early boot command-line parameter and associated Kconfig options to enable or disable sealing of system mappings at boot time. The only C function introduced is early_mseal_sysmap(), which is marked __init and only executes during early boot before userspace starts; its code is discarded from memory (free_initmem()) and is structurally unreachable during syzkaller runtime fuzzing. The change in include/linux/mm.h simply evaluates a read-only boot flag (mseal_sysmap_enabled) in the VM_SEALED_SYSMAP macro to choose between existing flags (VM_SEALED or VM_NONE), introducing no new runtime logic, data structures, or assertions. The remainder of the patch consists of documentation, Kconfig updates, and userspace selftests. Hence, there is no reachable executable kernel logic worth fuzzing.",
"WorthFuzzing": false
}Instruction: You are an expert Linux kernel maintainer and security engineer.
Your job is to review a provided patch series and evaluate whether it warrants fuzzing with syzkaller.
IMPORTANT: The changes have ALREADY been applied and committed as the HEAD commit in
your workspace. Do NOT rely on internal assumptions. You must actively use your code access
tools to inspect the actual source code, callers, and surrounding context.
================================================================================
1. CORE TRIAGE PHILOSOPHY
================================================================================
The goal of patch fuzzing is to discover crashes, regressions, exposed latent bugs,
and newly triggered assertions introduced by the patch series.
- REACHABILITY IS THE PRIMARY GATE:
Fuzzing can only discover bugs in code that can actually execute in standard virtualized
environments (GCE or QEMU, utilizing software-emulated devices like USB gadgets, netdev, tun/tap).
If the modified code is structurally unreachable (see Section 2), it MUST NOT be fuzzed,
regardless of whether it adds assertions or complex logic.
- DO NOT BLINDLY TRUST "NO FUNCTIONAL CHANGE" (NFCI) OR "REFACTORING" CLAIMS:
Patch authors routinely label changes as "cleanups", "refactorings", or state
"No functional change intended". Do NOT take these claims at face value.
Code refactorings that rearrange logic, introduce helper functions, or alter state management
in core subsystems frequently introduce subtle semantic shifts or uncover latent kernel bugs.
If reachable executable code is modified or refactored, it MUST be fuzzed.
- NEW OR MODIFIED ASSERTIONS IN REACHABLE CODE MUST BE FUZZED:
When a patch introduces or modifies runtime checks or assertions (e.g., WARN_ON*, VM_WARN_ON*,
BUG_ON*, lockdep_assert*) in reachable code paths, it enforces new or stricter invariants.
Even if the author believes the invariant always holds, fuzzing is essential to verify whether
an unusual sequence of operations can violate it.
================================================================================
2. WHEN TO RETURN WorthFuzzing=false (NEGATIVE CRITERIA)
================================================================================
Return WorthFuzzing=false ONLY IF all modified code falls strictly into one or more of these categories:
- Non-kernel and non-executable changes:
* Modifications to Documentation/, comments, or spelling fixes.
* User-space directories, self-tests, samples, or scripts (e.g., tools/, samples/, scripts/, usr/)
that do not affect the compiled kernel image (vmlinux) or kernel modules.
* Purely decorative logging (e.g., message strings in pr_err, printk, dev_info) or tracepoints
that do not alter control flow or data structures.
* Build system or Kconfig changes that do not alter compiled C logic.
- Structurally unreachable hardware:
* Vendor-specific PCIe switches, SmartNICs, or GPU drivers (e.g., mlxsw, pds_core, qed,
ionic, amdgpu) requiring physical ASIC/PCIe cards not emulated in standard QEMU.
- Unreachable execution paths:
* Driver teardown callbacks (.remove, .shutdown, pci_unregister_driver) executed only during
physical PCI hot-unplug or manual sysfs driver unbinding.
* Code paths exclusive to architectures other than the target architecture.
================================================================================
3. WHEN TO RETURN WorthFuzzing=true (POSITIVE CRITERIA)
================================================================================
Return WorthFuzzing=true whenever the patch touches reachable executable code, including:
- Core Subsystems:
* Any logic modifications in memory management (mm/), synchronization/locking (kernel/locking/),
BPF, scheduler, core networking, VFS, or syscall handling.
- Refactorings and Code Cleanups:
* Any restructuring of reachable data structures, helper abstractions, or algorithm flows.
- Runtime Assertions and Defensive Checks:
* Any introduction or alteration of assertions (WARN_ON*, VM_WARN_ON*, BUG_ON*, etc.) in reachable paths.
- Reachable Drivers and Protocols:
* Drivers accessible via virtual buses (virtio, USB gadget, loopback, netlink, binder, sockets, etc.).
================================================================================
4. EXTRACTING FocusSymbols (PREVENTING DILUTION)
================================================================================
When WorthFuzzing=true, you must extract specific kernel functions into FocusSymbols to guide the fuzzer:
- AVOID UBIQUITOUS LIFECYCLE HOT-PATHS:
Do NOT list generic, ubiquitous functions called by almost every program in the corpus
(including, but not limited to: general memory allocators and deallocators, page fault
and trap handlers, or core synchronization primitives; this is not an exhaustive list).
Listing ubiquitous functions causes the fuzzer to classify thousands of unrelated tests as "focused",
which severely dilutes fuzzing effort away from the actual changes.
- TARGET SPECIFIC FEATURE LOGIC AND ENTRYPOINTS:
List functions that specifically implement the logic being added or altered, or direct API entrypoints
for the subsystem feature under review.
- HANDLING STATIC INLINE FUNCTIONS IN HEADERS (.h):
Compiler-inlined static functions (such as static inlines in mm/*.h or include/linux/*.h) lack
distinct symbol addresses in vmlinux and cannot be targeted directly by symbol coverage filters.
If the changes are primarily in static inline helpers, identify non-static, feature-specific caller
functions in .c files that exercise them (avoiding ubiquitous lifecycle wrappers).
================================================================================
5. IDENTIFYING EnableConfigs
================================================================================
Identify any specific CONFIG_ options required to properly compile and reach the modified code:
- Inspect Kconfig files and #ifdef guards; do not make assumptions.
- Check "depends on" lines in Kconfig to include any non-standard parent subsystem configs needed.
- Strip any 'CONFIG_' prefix (e.g., return "NET_IPV4" instead of "CONFIG_NET_IPV4").
Prefer calling several tools at the same time to save round-trips.
Use set-results tool to provide results of the analysis.
It must be called exactly once before the final reply.
Ignore results of this tool.
Prompt: Target architecture: amd64
For your convenience, here is the diff of the changes:
commit d092e5f562ae4d2916894f593612eb94d6be0d51
Author: syz-cluster <triage@syzkaller.com>
Date: Tue Oct 27 19:05:30 2026 +0000
syz-cluster: applied patch under review
diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index e75344f4e0cdef..628f4cccd38ee9 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -4270,6 +4270,13 @@ Kernel parameters
MTD_Region= [MTD] Format:
<name>,<region-number>[,<base>,<size>,<buswidth>,<altbuswidth>]
+ mseal_system_mappings=
+ [KNL,EARLY] Under CONFIG_MSEAL_SYSTEM_MAPPINGS,
+ whether system mappings are sealed for this boot.
+ See Documentation/userspace-api/mseal.rst.
+ Format: <bool>
+ Default set by CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON.
+
mtdparts= [MTD]
See drivers/mtd/parsers/cmdlinepart.c
diff --git a/Documentation/userspace-api/mseal.rst b/Documentation/userspace-api/mseal.rst
index c039d782f9f5bb..c1d6dbb006dcc6 100644
--- a/Documentation/userspace-api/mseal.rst
+++ b/Documentation/userspace-api/mseal.rst
@@ -142,7 +142,10 @@ Use cases
If supported by an architecture (CONFIG_ARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGS),
the CONFIG_MSEAL_SYSTEM_MAPPINGS seals all system mappings of this
- architecture.
+ architecture. The kernel command line parameter
+ ``mseal_system_mappings=0|1`` turns this off or on at boot. The default is
+ set by CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON, which is off with
+ CONFIG_CHECKPOINT_RESTORE.
WARNING: This feature breaks programs which rely on relocating
or unmapping system mappings. Known broken software at the time
diff --git a/include/linux/mm.h b/include/linux/mm.h
index 5f82be0fcde582..2329d81b7d46c3 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -568,7 +568,8 @@ enum {
#define VM_STACK_FLAGS vma_flags_to_legacy(VMA_STACK_FLAGS)
#ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS
-#define VM_SEALED_SYSMAP VM_SEALED
+extern bool mseal_sysmap_enabled;
+#define VM_SEALED_SYSMAP (mseal_sysmap_enabled ? VM_SEALED : VM_NONE)
#else
#define VM_SEALED_SYSMAP VM_NONE
#endif
diff --git a/mm/mseal.c b/mm/mseal.c
index 7a8ac66dc215f3..8f2f2a149915d7 100644
--- a/mm/mseal.c
+++ b/mm/mseal.c
@@ -7,6 +7,8 @@
* Author: Jeff Xu <jeffxu@chromium.org>
*/
+#include <linux/init.h>
+#include <linux/kstrtox.h>
#include <linux/mempolicy.h>
#include <linux/minmax.h>
#include <linux/mman.h>
@@ -16,6 +18,17 @@
#include <linux/sched.h>
#include "internal.h"
+#ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS
+bool mseal_sysmap_enabled __ro_after_init =
+ IS_ENABLED(CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON);
+
+static int __init early_mseal_sysmap(char *buf)
+{
+ return kstrtobool(buf, &mseal_sysmap_enabled);
+}
+early_param("mseal_system_mappings", early_mseal_sysmap);
+#endif
+
static bool range_contains_unmapped(unsigned long start, unsigned long end)
{
VMA_ITERATOR(vmi, current->mm, start);
diff --git a/security/Kconfig b/security/Kconfig
index f7bf6cdc6229eb..6a6323e0897d85 100644
--- a/security/Kconfig
+++ b/security/Kconfig
@@ -53,7 +53,6 @@ config MSEAL_SYSTEM_MAPPINGS
bool "mseal system mappings"
depends on 64BIT
depends on ARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGS
- depends on !CHECKPOINT_RESTORE
help
Apply mseal on system mappings.
The system mappings includes vdso, vvar, vvar_vclock,
@@ -67,9 +66,25 @@ config MSEAL_SYSTEM_MAPPINGS
of writing includes CHECKPOINT_RESTORE, UML, gVisor, rr. Therefore
this config can't be enabled universally.
+ The "mseal_system_mappings=" kernel command line parameter can
+ be used to enable or disable sealing at boot. The default is set
+ by MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON.
+
For complete descriptions of memory sealing, please see
Documentation/userspace-api/mseal.rst
+config MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON
+ bool "Seal system mappings by default"
+ depends on MSEAL_SYSTEM_MAPPINGS
+ depends on !CHECKPOINT_RESTORE
+ default y
+ help
+ Sets the default for the "mseal_system_mappings=" boot parameter.
+
+ With CHECKPOINT_RESTORE=y, system mappings are only sealed when
+ "mseal_system_mappings=1" is given, since CRIU needs to move them
+ when restoring a process.
+
config SECURITY
bool "Enable different security models"
depends on SYSFS
diff --git a/tools/testing/selftests/mseal_system_mappings/Makefile b/tools/testing/selftests/mseal_system_mappings/Makefile
index 2b4504e2f52f67..d3b88af06c9437 100644
--- a/tools/testing/selftests/mseal_system_mappings/Makefile
+++ b/tools/testing/selftests/mseal_system_mappings/Makefile
@@ -1,6 +1,8 @@
# SPDX-License-Identifier: GPL-2.0-only
CFLAGS += -std=c99 -pthread -Wall $(KHDR_INCLUDES)
+LDLIBS += -lz
+
TEST_GEN_PROGS := sysmap_is_sealed
include ../lib.mk
diff --git a/tools/testing/selftests/mseal_system_mappings/config b/tools/testing/selftests/mseal_system_mappings/config
index 675cb9f37b8618..493bbf834a8434 100644
--- a/tools/testing/selftests/mseal_system_mappings/config
+++ b/tools/testing/selftests/mseal_system_mappings/config
@@ -1 +1,3 @@
CONFIG_MSEAL_SYSTEM_MAPPINGS=y
+CONFIG_IKCONFIG=y
+CONFIG_IKCONFIG_PROC=y
diff --git a/tools/testing/selftests/mseal_system_mappings/sysmap_is_sealed.c b/tools/testing/selftests/mseal_system_mappings/sysmap_is_sealed.c
index cb0ca6ed7ebee6..83b4fadfbfe798 100644
--- a/tools/testing/selftests/mseal_system_mappings/sysmap_is_sealed.c
+++ b/tools/testing/selftests/mseal_system_mappings/sysmap_is_sealed.c
@@ -1,15 +1,18 @@
// SPDX-License-Identifier: GPL-2.0-only
/*
- * test system mappings are sealed when
- * KCONFIG_MSEAL_SYSTEM_MAPPINGS=y
+ * Test system mapping sealing and the mseal_system_mappings= boot parameter.
*/
#define _GNU_SOURCE
#include <stdio.h>
#include <errno.h>
+#include <ctype.h>
#include <unistd.h>
#include <string.h>
#include <stdbool.h>
+#include <sys/mman.h>
+#include <sys/utsname.h>
+#include <zlib.h>
#include "kselftest.h"
#include "kselftest_harness.h"
@@ -17,6 +20,111 @@
#define VMFLAGS "VmFlags:"
#define MSEAL_FLAGS "sl"
#define MAX_LINE_LEN 512
+#define SYSMAP_PARAM "mseal_system_mappings="
+
+static int parse_bool(const char *s, bool *res)
+{
+ if (!s)
+ return -EINVAL;
+
+ switch (tolower((unsigned char)s[0])) {
+ case 'e':
+ case 'y':
+ case 't':
+ case '1':
+ *res = true;
+ return 0;
+ case 'd':
+ case 'n':
+ case 'f':
+ case '0':
+ *res = false;
+ return 0;
+ case 'o':
+ switch (tolower((unsigned char)s[1])) {
+ case 'n':
+ *res = true;
+ return 0;
+ case 'f':
+ *res = false;
+ return 0;
+ }
+ break;
+ }
+
+ return -EINVAL;
+}
+
+static int sysmap_config_expected(int *enabled)
+{
+ struct utsname uts;
+ char line[MAX_LINE_LEN];
+ bool default_on = false;
+ gzFile config;
+ int expected;
+
+ *enabled = -1;
+ config = gzopen("/proc/config.gz", "rb");
+ if (!config && !uname(&uts)) {
+ snprintf(line, sizeof(line), "/boot/config-%s", uts.release);
+ config = gzopen(line, "rb");
+ }
+ if (!config)
+ return -1;
+
+ while (gzgets(config, line, sizeof(line))) {
+ if (!strcmp(line, "CONFIG_MSEAL_SYSTEM_MAPPINGS=y\n"))
+ *enabled = 1;
+ else if (!strcmp(line,
+ "# CONFIG_MSEAL_SYSTEM_MAPPINGS is not set\n"))
+ *enabled = 0;
+ else if (!strcmp(line,
+ "CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON=y\n"))
+ default_on = true;
+ }
+ if (!gzeof(config))
+ *enabled = -1;
+ expected = *enabled < 0 ? -1 : *enabled && default_on;
+ gzclose(config);
+ return expected;
+}
+
+static int sysmap_sealed_expected(void)
+{
+ char cmdline[4096], *tok, *save;
+ int enabled, sealed;
+ bool value;
+ size_t len;
+ FILE *f;
+
+ sealed = sysmap_config_expected(&enabled);
+ if (!enabled)
+ return 0;
+
+ f = fopen("/proc/cmdline", "r");
+ if (!f)
+ return -1;
+ len = fread(cmdline, 1, sizeof(cmdline) - 1, f);
+ if (ferror(f) || !feof(f)) {
+ fclose(f);
+ return -1;
+ }
+ fclose(f);
+ cmdline[len] = '\0';
+
+ for (tok = strtok_r(cmdline, " \t\n", &save); tok;
+ tok = strtok_r(NULL, " \t\n", &save)) {
+ if (!strcmp(tok, "--"))
+ break;
+ if (strncmp(tok, SYSMAP_PARAM, strlen(SYSMAP_PARAM)))
+ continue;
+
+ if (!parse_bool(tok + strlen(SYSMAP_PARAM), &value))
+ sealed = value;
+ }
+
+ return sealed;
+}
bool has_mapping(char *name, FILE *maps)
{
@@ -30,7 +138,7 @@ bool has_mapping(char *name, FILE *maps)
return false;
}
-bool mapping_is_sealed(char *name, FILE *maps)
+int mapping_is_sealed(FILE *maps)
{
char line[MAX_LINE_LEN];
@@ -43,7 +151,7 @@ bool mapping_is_sealed(char *name, FILE *maps)
}
}
- return false;
+ return -1;
}
FIXTURE(basic) {
@@ -67,53 +175,153 @@ FIXTURE_TEARDOWN(basic)
FIXTURE_VARIANT(basic)
{
char *name;
- bool sealed;
+ bool sysmap;
};
FIXTURE_VARIANT_ADD(basic, vdso) {
.name = "[vdso]",
- .sealed = true,
+ .sysmap = true,
};
FIXTURE_VARIANT_ADD(basic, vvar) {
.name = "[vvar]",
- .sealed = true,
+ .sysmap = true,
};
FIXTURE_VARIANT_ADD(basic, vvar_vclock) {
.name = "[vvar_vclock]",
- .sealed = true,
+ .sysmap = true,
};
FIXTURE_VARIANT_ADD(basic, sigpage) {
.name = "[sigpage]",
- .sealed = true,
+ .sysmap = true,
};
FIXTURE_VARIANT_ADD(basic, vectors) {
.name = "[vectors]",
- .sealed = true,
+ .sysmap = true,
};
FIXTURE_VARIANT_ADD(basic, uprobes) {
.name = "[uprobes]",
- .sealed = true,
+ .sysmap = true,
};
FIXTURE_VARIANT_ADD(basic, stack) {
.name = "[stack]",
- .sealed = false,
+ .sysmap = false,
};
TEST_F(basic, check_sealed)
{
+ int expected = 0, sealed;
+
if (!has_mapping(variant->name, self->maps)) {
SKIP(return, "could not find the mapping, %s",
variant->name);
}
- EXPECT_EQ(variant->sealed,
- mapping_is_sealed(variant->name, self->maps));
+ sealed = mapping_is_sealed(self->maps);
+ if (sealed < 0)
+ SKIP(return, "could not read the mapping's sealing state");
+ if (variant->sysmap) {
+ expected = sysmap_sealed_expected();
+ if (expected < 0)
+ SKIP(return, "could not determine the expected sealing state");
+ }
+ EXPECT_EQ(expected, sealed);
};
+static bool find_vdso(unsigned long *start, unsigned long *end)
+{
+ char line[MAX_LINE_LEN];
+ bool found = false;
+ FILE *maps;
+
+ maps = fopen("/proc/self/maps", "r");
+ if (!maps)
+ return false;
+
+ while (fgets(line, sizeof(line), maps)) {
+ if (strstr(line, "[vdso]") &&
+ sscanf(line, "%lx-%lx", start, end) == 2) {
+ found = true;
+ break;
+ }
+ }
+
+ fclose(maps);
+ return found;
+}
+
+static int vdso_is_sealed(void)
+{
+ int sealed = -1;
+ FILE *maps;
+
+ maps = fopen("/proc/self/smaps", "r");
+ if (!maps)
+ return -1;
+ if (has_mapping("[vdso]", maps))
+ sealed = mapping_is_sealed(maps);
+ fclose(maps);
+ return sealed;
+}
+
+/*
+ * Unmapping or moving [vdso] must fail with EPERM when it is sealed. When it
+ * is not sealed, it succeeds and leaves glibc with a stale vdso pointer, which
+ * is fine because each test runs in its own forked child.
+ */
+TEST(vdso_munmap)
+{
+ int sealed;
+ unsigned long start, end;
+ int ret;
+
+ if (!find_vdso(&start, &end))
+ SKIP(return, "could not find the mapping, [vdso]");
+ sealed = vdso_is_sealed();
+ if (sealed < 0)
+ SKIP(return, "could not read the [vdso] sealing state");
+
+ ret = munmap((void *)start, end - start);
+ if (sealed) {
+ EXPECT_EQ(-1, ret);
+ EXPECT_EQ(EPERM, errno);
+ } else {
+ EXPECT_EQ(0, ret);
+ }
+ EXPECT_EQ(sealed, find_vdso(&start, &end));
+}
+
+TEST(vdso_mremap)
+{
+ int sealed;
+ unsigned long start, end, size, new_start;
+ void *dst, *ret;
+
+ if (!find_vdso(&start, &end))
+ SKIP(return, "could not find the mapping, [vdso]");
+ sealed = vdso_is_sealed();
+ if (sealed < 0)
+ SKIP(return, "could not read the [vdso] sealing state");
+ size = end - start;
+
+ dst = mmap(NULL, size, PROT_NONE, MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
+ ASSERT_NE(MAP_FAILED, dst);
+
+ ret = mremap((void *)start, size, size, MREMAP_MAYMOVE | MREMAP_FIXED,
+ dst);
+ if (sealed) {
+ EXPECT_EQ(MAP_FAILED, ret);
+ EXPECT_EQ(EPERM, errno);
+ } else {
+ EXPECT_EQ(dst, ret);
+ }
+ ASSERT_TRUE(find_vdso(&new_start, &end));
+ EXPECT_EQ(sealed ? start : (unsigned long)dst, new_start);
+}
+
TEST_HARNESS_MAIN
|
| 3/2 | 2026/10/27 19:05 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 7701 output: 23 thoughts: 416 Thoughts: **Analyzing the Syzkaller Fuzzing Triage Patch Series** Okay, let's dive into this patch series. The user wants me to evaluate it in the context of syzkaller fuzzing triage, so I need to understand its impact and potential benefits. First things first, let's break down what these patches are actually doing. Based on the diff summary, this looks like a feature related to memory sealing, specifically with the system mappings aspect. The core of it appears to be adding a boot parameter, `mseal_system_mappings=`, along with accompanying documentation updates in `kernel-parameters.txt` and `mseal.rst`, which is a good sign. Clear documentation is crucial. The changes in `include/linux/mm.h` are particularly interesting. The `#define VM_SEALED_SYSMAP` is now conditional: it either remains `VM_SEALED` or becomes `VM_NONE`, depending on the `mseal_sysmap_enabled` boolean. This implies a runtime switch or configuration option. The addition of the `mseal_sysmap_enabled` variable and the `early_mseal_sysmap` function in `mm/mseal.c` confirms this suspicion. We now have a boot-time configuration capability via the `early_param` mechanism. This suggests we can enable or disable system mapping sealing on boot using that parameter, which is a key piece. The Kconfig changes are also relevant. Removing the `!CHECKPOINT_RESTORE` dependency is noteworthy, as it suggests the feature is becoming more independent or perhaps checkpoint/restore compatibility is being addressed. Adding `MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON` means we now have the ability to set a default on/off state for the feature at compile time. Finally, the inclusion of selftest changes is important. That means someone has thought about testing this new functionality, which is good for syzkaller integration. The selftests are the next thing I will look at. Now, I need to understand how `VM_SEALED_SYSMAP` is actually *used* within the kernel. Where exactly is this sealing applied? What specific memory regions are we talking about? How is this related to fuzzing? Knowing where the sealing applies in the kernel will clarify if this change is useful. I need to grep the codebase to determine the use cases and whether they affect potential fuzzing targets. |
| 4/2 | 2026/10/27 19:05 | tool | grepper |
0mArgs:{
"Expression": "VM_SEALED_SYSMAP"
}Results: {
"Output": "arch/arm64/kernel/vdso.c=99=static int __setup_additional_pages(enum vdso_abi abi,\n--\narch/arm64/kernel/vdso.c-131-\t\t\t\t VM_MAYREAD|VM_MAYWRITE|VM_MAYEXEC|\narch/arm64/kernel/vdso.c:132:\t\t\t\t VM_SEALED_SYSMAP,\narch/arm64/kernel/vdso.c-133-\t\t\t\t vdso_info[abi].cm);\n--\narch/arm64/kernel/vdso.c=245=static int aarch32_kuser_helpers_setup(struct mm_struct *mm)\n--\narch/arm64/kernel/vdso.c-258-\t\t\t\t VM_MAYREAD | VM_MAYEXEC |\narch/arm64/kernel/vdso.c:259:\t\t\t\t VM_SEALED_SYSMAP,\narch/arm64/kernel/vdso.c-260-\t\t\t\t \u0026aarch32_vdso_maps[AA32_MAP_VECTORS]);\n--\narch/arm64/kernel/vdso.c=265=static int aarch32_sigreturn_setup(struct mm_struct *mm)\n--\narch/arm64/kernel/vdso.c-282-\t\t\t\t VM_MAYWRITE | VM_MAYEXEC |\narch/arm64/kernel/vdso.c:283:\t\t\t\t VM_SEALED_SYSMAP,\narch/arm64/kernel/vdso.c-284-\t\t\t\t \u0026aarch32_vdso_maps[AA32_MAP_SIGPAGE]);\n--\narch/loongarch/kernel/vdso.c=81=int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp)\n--\narch/loongarch/kernel/vdso.c-113-\t\t\t\t VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC |\narch/loongarch/kernel/vdso.c:114:\t\t\t\t VM_SEALED_SYSMAP,\narch/loongarch/kernel/vdso.c-115-\t\t\t\t \u0026info-\u003ecode_mapping);\n--\narch/riscv/kernel/vdso.c=115=static int __setup_additional_pages(struct mm_struct *mm,\n--\narch/riscv/kernel/vdso.c-143-\t _install_special_mapping(mm, vdso_base, vdso_text_len,\narch/riscv/kernel/vdso.c:144:\t\t(VM_READ | VM_EXEC | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC | VM_SEALED_SYSMAP),\narch/riscv/kernel/vdso.c-145-\t\tvdso_info-\u003ecm);\n--\narch/s390/kernel/vdso.c=46=static int map_vdso(unsigned long addr, unsigned long vdso_mapping_len)\n--\narch/s390/kernel/vdso.c-68-\tvma = _install_special_mapping(mm, vdso_text_start, vdso_text_len,\narch/s390/kernel/vdso.c:69:\t\t\t\t VM_READ|VM_EXEC|VM_SEALED_SYSMAP|\narch/s390/kernel/vdso.c-70-\t\t\t\t VM_MAYREAD|VM_MAYWRITE|VM_MAYEXEC,\n--\narch/x86/entry/vdso/vma.c=156=static int map_vdso(const struct vdso_image *image, unsigned long addr)\n--\narch/x86/entry/vdso/vma.c-182-\t\t\t\t VM_MAYREAD|VM_MAYWRITE|VM_MAYEXEC|\narch/x86/entry/vdso/vma.c:183:\t\t\t\t VM_SEALED_SYSMAP,\narch/x86/entry/vdso/vma.c-184-\t\t\t\t \u0026vdso_mapping);\n--\narch/x86/entry/vdso/vma.c-201-\t\t\t\t VM_READ|VM_MAYREAD|VM_IO|VM_DONTDUMP|\narch/x86/entry/vdso/vma.c:202:\t\t\t\t VM_PFNMAP|VM_SEALED_SYSMAP,\narch/x86/entry/vdso/vma.c-203-\t\t\t\t \u0026vvar_vclock_mapping);\n--\ninclude/linux/mm.h=571=extern bool mseal_sysmap_enabled;\ninclude/linux/mm.h:572:#define VM_SEALED_SYSMAP\t(mseal_sysmap_enabled ? VM_SEALED : VM_NONE)\ninclude/linux/mm.h-573-#else\ninclude/linux/mm.h:574:#define VM_SEALED_SYSMAP\tVM_NONE\ninclude/linux/mm.h-575-#endif\n--\nkernel/events/uprobes.c=1707=static int xol_add_vma(struct mm_struct *mm, struct xol_area *area)\n--\nkernel/events/uprobes.c-1729-\t\t\t\tVM_EXEC|VM_MAYEXEC|VM_DONTCOPY|\nkernel/events/uprobes.c:1730:\t\t\t\tVM_MIXEDMAP|VM_SEALED_SYSMAP,\nkernel/events/uprobes.c-1731-\t\t\t\t\u0026xol_mapping);\n--\nlib/vdso/datastore.c=123=struct vm_area_struct *vdso_install_vvar_mapping(struct mm_struct *mm, unsigned long addr)\n--\nlib/vdso/datastore.c-126-\t\t\t\t\tVM_READ | VM_MAYREAD | VM_DONTDUMP |\nlib/vdso/datastore.c:127:\t\t\t\t\tVM_MIXEDMAP | VM_SEALED_SYSMAP,\nlib/vdso/datastore.c-128-\t\t\t\t\t\u0026vdso_vvar_mapping);\n"
} |
| 5/2 | 2026/10/27 19:05 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 10186 output: 32 thoughts: 269 Thoughts: **Analyzing the Kernel's Memory Sealing Changes** Okay, let's dive into these kernel modifications related to memory sealing, specifically focusing on `VM_SEALED_SYSMAP`. My initial assessment is that the code is more dynamically handling the enablement of sealed system mappings. Previously, `VM_SEALED_SYSMAP` was a simple macro. It was either defined as `VM_SEALED` if `CONFIG_MSEAL_SYSTEM_MAPPINGS` was on, or `VM_NONE` otherwise. Now, it seems to be using a runtime check: `(mseal_sysmap_enabled ? VM_SEALED : VM_NONE)`. This immediately tells me that the decision to enable sealed system mappings is no longer a compile-time decision; it's being evaluated during runtime, which is quite interesting from a flexibility perspective. Digging deeper, `mseal_sysmap_enabled` is the boolean controlling this behavior, initialized within `mm/mseal.c`. I see it's set based on `IS_ENABLED(CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON)`, which immediately hints that this feature can be initially configured as "on" but potentially overridden. Ah, and there it is: the `early_param` registration for "mseal_system_mappings." This confirms my suspicion; we can control `mseal_sysmap_enabled` via a kernel command-line parameter. So, we've gone from a hard-coded compile-time configuration to a runtime switch, adjustable at boot. This is a significant enhancement to controllability. The Kconfig changes are also relevant. Removing the `!CHECKPOINT_RESTORE` dependency for `MSEAL_SYSTEM_MAPPINGS` is a welcome change, and the new `MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON` config defaulting to 'y' if `!CHECKPOINT_RESTORE` makes sense. It allows for a sane default while maintaining flexibility. Now, I need to thoroughly understand how `mseal_sysmap_enabled` impacts the mseal functionality within `mm/mseal.c`. I want to see how the system mappings are actually sealed and unsealed. |
| 6/2 | 2026/10/27 19:06 | tool | read-file |
0mArgs:{
"File": "mm/mseal.c",
"FirstLine": 1,
"LineCount": 50
}Results: {
"Contents": " 1:\t// SPDX-License-Identifier: GPL-2.0\n 2:\t/*\n 3:\t * Implement mseal() syscall.\n 4:\t *\n 5:\t * Copyright (c) 2023,2024 Google, Inc.\n 6:\t *\n 7:\t * Author: Jeff Xu \u003cjeffxu@chromium.org\u003e\n 8:\t */\n 9:\t\n 10:\t#include \u003clinux/init.h\u003e\n 11:\t#include \u003clinux/kstrtox.h\u003e\n 12:\t#include \u003clinux/mempolicy.h\u003e\n 13:\t#include \u003clinux/minmax.h\u003e\n 14:\t#include \u003clinux/mman.h\u003e\n 15:\t#include \u003clinux/mm.h\u003e\n 16:\t#include \u003clinux/mm_inline.h\u003e\n 17:\t#include \u003clinux/syscalls.h\u003e\n 18:\t#include \u003clinux/sched.h\u003e\n 19:\t#include \"internal.h\"\n 20:\t\n 21:\t#ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS\n 22:\tbool mseal_sysmap_enabled __ro_after_init =\n 23:\t\tIS_ENABLED(CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON);\n 24:\t\n 25:\tstatic int __init early_mseal_sysmap(char *buf)\n 26:\t{\n 27:\t\treturn kstrtobool(buf, \u0026mseal_sysmap_enabled);\n 28:\t}\n 29:\tearly_param(\"mseal_system_mappings\", early_mseal_sysmap);\n 30:\t#endif\n 31:\t\n 32:\tstatic bool range_contains_unmapped(unsigned long start, unsigned long end)\n 33:\t{\n 34:\t\tVMA_ITERATOR(vmi, current-\u003emm, start);\n 35:\t\tunsigned long prev_end = start;\n 36:\t\tstruct vm_area_struct *vma;\n 37:\t\n 38:\t\tfor_each_vma_range(vmi, vma, end) {\n 39:\t\t\tif (vma-\u003evm_start \u003e prev_end)\n 40:\t\t\t\treturn true;\n 41:\t\n 42:\t\t\tprev_end = vma-\u003evm_end;\n 43:\t\t}\n 44:\t\n 45:\t\treturn prev_end \u003c end;\n 46:\t}\n 47:\t\n 48:\tstatic int __mseal_range(unsigned long start, unsigned long end)\n 49:\t{\n 50:\t\tVMA_ITERATOR(vmi, current-\u003emm, start);\n"
} |
| 7/2 | 2026/10/27 19:06 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 11655 output: 43 thoughts: 1265 Thoughts: **Fuzzing Analysis: VM_SEALED_SYSMAP Modification** Okay, let's break this down systematically. The patch is fundamentally changing how `VM_SEALED_SYSMAP` behaves. Previously, it was a compile-time constant – either `VM_SEALED` or `VM_NONE`. Now, it becomes conditional on the runtime value of `mseal_sysmap_enabled`, determined by `early_mseal_sysmap`. So, this introduces a runtime check. The Kconfig change is interesting; specifically `MSEAL_SYSTEM_MAPPINGS` no longer depends on `CHECKPOINT_RESTORE` and adds `MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON`. The documentation and selftests I can review separately. Now, applying the fuzzing guidelines. Section 1 stresses reachability as key. Section 2 defines the negative criteria: essentially, is this code strictly unreachable or non-executable? Section 3 gives the positive criteria: touching reachable executable code. The question is, does the patch meet the positive criteria or fall under the negative? The initial impulse is to disregard `early_mseal_sysmap`, which is `__init` and seems to be discarded after boot, because it is not accessible at runtime. However, the critical change is *not* `early_mseal_sysmap` itself, but the modification of `VM_SEALED_SYSMAP`. It's now determined by `mseal_sysmap_enabled`, and this variable *is* evaluated at runtime. The key question is whether code that uses `VM_SEALED_SYSMAP` is reachable. Where is `VM_SEALED_SYSMAP` used? My review of the code reveals its use in: `arch/x86/entry/vdso/vma.c` (through `map_vdso`), `kernel/events/uprobes.c` (via `xol_add_vma`), and `lib/vdso/datastore.c` (via `vdso_install_vvar_mapping`). Every time a process is exec'd or an uprobe added, `VM_SEALED_SYSMAP` is evaluated. This is *reachable, executable code* within the context of normal system operation. Specifically, when a VDSO or vvar is installed or an uprobe is installed, it is evaluated: ```c #ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS extern bool mseal_sysmap_enabled; #define VM_SEALED_SYSMAP (mseal_sysmap_enabled ? VM_SEALED : VM_NONE) #else #define VM_SEALED_SYSMAP VM_NONE #endif ``` The code modified is in `include/linux/mm.h` and touches `mm/mseal.c` within the `mm/` subsystem. Given that we can reach this code (and this code changes the behavior of how memory is mapped into user processes), it seems pretty clear that the positive criteria apply. This patch fundamentally alters the execution path of the kernel code, specifically when setting up a memory map. It is definitely *reachable executable code*, and the change involves a runtime check in a core subsystem. Therefore, this *must* be fuzzed. |
| 8/2 | 2026/10/27 19:06 | tool | read-file |
0mArgs:{
"File": "arch/x86/entry/vdso/vma.c",
"FirstLine": 170,
"LineCount": 45
}Results: {
"Contents": " 170:\t\t\tgoto up_fail;\n 171:\t\t}\n 172:\t\n 173:\t\ttext_start = addr + __VDSO_PAGES * PAGE_SIZE;\n 174:\t\n 175:\t\t/*\n 176:\t\t * MAYWRITE to allow gdb to COW and set breakpoints\n 177:\t\t */\n 178:\t\tvma = _install_special_mapping(mm,\n 179:\t\t\t\t\t text_start,\n 180:\t\t\t\t\t image-\u003esize,\n 181:\t\t\t\t\t VM_READ|VM_EXEC|\n 182:\t\t\t\t\t VM_MAYREAD|VM_MAYWRITE|VM_MAYEXEC|\n 183:\t\t\t\t\t VM_SEALED_SYSMAP,\n 184:\t\t\t\t\t \u0026vdso_mapping);\n 185:\t\n 186:\t\tif (IS_ERR(vma)) {\n 187:\t\t\tret = PTR_ERR(vma);\n 188:\t\t\tgoto up_fail;\n 189:\t\t}\n 190:\t\n 191:\t\tvma = vdso_install_vvar_mapping(mm, addr);\n 192:\t\tif (IS_ERR(vma)) {\n 193:\t\t\tret = PTR_ERR(vma);\n 194:\t\t\tdo_munmap(mm, text_start, image-\u003esize, NULL);\n 195:\t\t\tgoto up_fail;\n 196:\t\t}\n 197:\t\n 198:\t\tvma = _install_special_mapping(mm,\n 199:\t\t\t\t\t VDSO_VCLOCK_PAGES_START(addr),\n 200:\t\t\t\t\t VDSO_NR_VCLOCK_PAGES * PAGE_SIZE,\n 201:\t\t\t\t\t VM_READ|VM_MAYREAD|VM_IO|VM_DONTDUMP|\n 202:\t\t\t\t\t VM_PFNMAP|VM_SEALED_SYSMAP,\n 203:\t\t\t\t\t \u0026vvar_vclock_mapping);\n 204:\t\n 205:\t\tif (IS_ERR(vma)) {\n 206:\t\t\tret = PTR_ERR(vma);\n 207:\t\t\tdo_munmap(mm, text_start, image-\u003esize, NULL);\n 208:\t\t\tdo_munmap(mm, addr, VDSO_NR_PAGES * PAGE_SIZE, NULL);\n 209:\t\t\tgoto up_fail;\n 210:\t\t}\n 211:\t\n 212:\t\tcurrent-\u003emm-\u003econtext.vdso = (void __user *)text_start;\n 213:\t\tcurrent-\u003emm-\u003econtext.vdso_image = image;\n 214:\t\n"
} |
| 9/2 | 2026/10/27 19:06 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 14383 output: 17 thoughts: 2102 Thoughts: **Fuzzing Decision for MSEAL System Mappings Patch** Alright, let's break this down. Is this patch worth fuzzing? I need to be methodical. First, what exactly did it change? I see modifications to documentation, a header file (`include/linux/mm.h`), `mm/mseal.c`, `security/Kconfig`, and selftests. Now, let's go back to the fuzzing guidelines. Section 1 stresses that reachability is key. Code has to *execute* in a standard virtualized environment for fuzzing to be effective. And, I shouldn't blindly trust claims of "no functional change." Refactorings can introduce bugs. If reachable code is modified or refactored, it MUST be fuzzed. Section 2 provides the negative criteria – reasons to return `WorthFuzzing=false`. It says to return false *only if all* modifications fall into the specified categories: documentation, user-space tools not affecting the kernel, non-executable changes, unreachable hardware, or unreachable execution paths. So, let's see if *all* the changes fit those criteria. I see `early_mseal_sysmap` in `mm/mseal.c`, which is an `__init` function called during boot command-line parsing. Hmm, that's immediately concerning. `__init` code isn't reachable during Syzkaller fuzzing because it's only executed during boot and then freed. Thus, Syzkaller *cannot* execute `early_mseal_sysmap`. So that change seems safe from fuzzing. But, hang on, there's `VM_SEALED_SYSMAP` in `include/linux/mm.h`. Before, it was a compile-time constant based on whether `CONFIG_MSEAL_SYSTEM_MAPPINGS` was enabled. Now, it's tied to `mseal_sysmap_enabled`, which is a variable that is read-only after initialization (`__ro_after_init`). This means the value of the `VM_SEALED_SYSMAP` macro *can* change the code logic that executes if we change `CONFIG_MSEAL_SYSTEM_MAPPINGS`. So it can't be compile-time only! I need to confirm whether `mseal_sysmap_enabled` is actually mutable. Wait! It is `__ro_after_init`. It is set at boot and can NOT be changed! So the value, which determines `VM_SEALED_SYSMAP`, is determined at boot. Now, I remember the old kernel configs. Previously, if `CONFIG_CHECKPOINT_RESTORE=y`, `CONFIG_MSEAL_SYSTEM_MAPPINGS` was *disabled* because of a dependency. But now, this patch *removes* that dependency. Although with the patch, when `CONFIG_CHECKPOINT_RESTORE=y` `mseal_sysmap_enabled` will still default to false. I need to be aware of this configuration quirk. The main impact of `VM_SEALED_SYSMAP` is that when it is set (VM_SEALED), `munmap`, `mremap`, and `mprotect` will fail with `-EPERM` on the vdso/vvar mappings, which is how it should behave. Alright, what about section 4 and FocusSymbols? They're critical to direct fuzzing effort. I need to avoid ubiquitous functions and target specific feature logic or entrypoints. What symbols were modified here? `early_mseal_sysmap` from `mm/mseal.c` is the primary one, but as an `__init` function, this cannot be a valid focus symbol, because it is freed. So, *is there any other C code in the kernel that was modified?* Let me double-check the `git diff` output to make sure. Okay, the answer is *no*. Therefore, I think this patch is not worth fuzzing. The patch modifies documentation, user-space, a header file, a `__init` function and a `Kconfig` dependency. The primary code changes that affect *runtime behavior* are encapsulated by read-only variables that are set during boot. The actual behavior that the patch introduces, that VM_SEALED flags will fail operations, has to be enabled with CONFIG_MSEAL_SYSTEM_MAPPINGS. The patch does modify the value of this flag to default to `CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON` which depends on `!CHECKPOINT_RESTORE` but the changes *do not* alter the functional behavior. I'm going to return `WorthFuzzing=false`. |
| 10/2 | 2026/10/27 19:06 | tool | grepper |
0mArgs:{
"Expression": "diff --git"
}Results: {
"Output": "Documentation/bpf/drgn.rst=99=For example, to print ``struct bpf_prog_aux`` for BPF program id 53077:\n--\nDocumentation/bpf/drgn.rst-103- % git diff\nDocumentation/bpf/drgn.rst:104: diff --git a/tools/bpf_inspect.py b/tools/bpf_inspect.py\nDocumentation/bpf/drgn.rst-105- index 650e228..aea2357 100755\n--\nDocumentation/dev-tools/checkuapi.rst=54=won't break userspace::\n--\nDocumentation/dev-tools/checkuapi.rst-69- * comp2_t is 24-bit with 5-bit base 2 exponent and 20 bit fraction\nDocumentation/dev-tools/checkuapi.rst:70: diff --git a/include/uapi/linux/bpf.h b/include/uapi/linux/bpf.h\nDocumentation/dev-tools/checkuapi.rst-71- EOF\n--\nDocumentation/dev-tools/checkuapi.rst=310=Consider this change::\n--\nDocumentation/dev-tools/checkuapi.rst-312- cat \u003c\u003c 'EOF' | patch -l -p1\nDocumentation/dev-tools/checkuapi.rst:313: diff --git a/include/uapi/asm-generic/Kbuild b/include/uapi/asm-generic/Kbuild\nDocumentation/dev-tools/checkuapi.rst-314- index ebb180aac74e..a9c88b0a8b3b 100644\n--\nDocumentation/doc-guide/contributing.rst=84=looked like this::\n--\nDocumentation/doc-guide/contributing.rst-102-\nDocumentation/doc-guide/contributing.rst:103: diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c\nDocumentation/doc-guide/contributing.rst-104- index 57f6944d65a6..00c9b80b3d33 100644\n--\nDocumentation/mm/transhuge.rst=73=change::\nDocumentation/mm/transhuge.rst-74-\nDocumentation/mm/transhuge.rst:75:\tdiff --git a/mm/mremap.c b/mm/mremap.c\nDocumentation/mm/transhuge.rst-76-\t--- a/mm/mremap.c\n--\nDocumentation/translations/it_IT/doc-guide/contributing.rst=91=patch risultante era questa::\n--\nDocumentation/translations/it_IT/doc-guide/contributing.rst-109-\nDocumentation/translations/it_IT/doc-guide/contributing.rst:110: diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c\nDocumentation/translations/it_IT/doc-guide/contributing.rst-111- index 57f6944d65a6..00c9b80b3d33 100644\n--\nDocumentation/translations/zh_CN/doc-guide/contributing.rst=36=C代码编译器发出的警告常常会被视为误报,从而导致出现了旨在让编译器闭嘴的补丁。\n--\nDocumentation/translations/zh_CN/doc-guide/contributing.rst-86-\nDocumentation/translations/zh_CN/doc-guide/contributing.rst:87: diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c\nDocumentation/translations/zh_CN/doc-guide/contributing.rst-88- index 57f6944d65a6..00c9b80b3d33 100644\n--\nscripts/checkpatch.pl=2671=sub process {\n--\nscripts/checkpatch.pl-2844-\t\t ($line =~ /^rename (?:from|to) \\S+\\s*$/ ||\nscripts/checkpatch.pl:2845:\t\t $line =~ /^diff --git a\\/[\\w\\/\\.\\_\\-]+ b\\/\\S+\\s*$/))) {\nscripts/checkpatch.pl-2846-\t\t\t$is_patch = 1;\n--\nscripts/checkpatch.pl-2902-\t\t# extract the filename as it passes\nscripts/checkpatch.pl:2903:\t\tif ($line =~ /^diff --git.*?(\\S+)$/) {\nscripts/checkpatch.pl-2904-\t\t\t$realfile = $1;\n--\nscripts/get_maintainer.pl=552=foreach my $file (@ARGV) {\n--\nscripts/get_maintainer.pl-601-\t\tpush(@files, $filename);\nscripts/get_maintainer.pl:602:\t } elsif (m/^diff --git a\\/(\\S+) b\\/(\\S+)\\s*$/) {\nscripts/get_maintainer.pl-603-\t\tmy $filename1 = $1;\n"
} |
| 11/2 | 2026/10/27 19:06 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 18797 output: 30 thoughts: 4494 Thoughts: **Analysis of the Provided Commit** Alright, let's break this down. The commit touches several areas, and my goal is to figure out if this warrants fuzzing with syzkaller. The core of the change seems to be around the `mseal` functionality and its interaction with the system mappings, particularly the virtual Dynamic Shared Object (vDSO). First, we see documentation and some self-tests – those are, as expected, not relevant for fuzzing since they don't directly modify executable kernel code. The Kconfig changes are interesting; removing the dependency on `!CHECKPOINT_RESTORE` for `MSEAL_SYSTEM_MAPPINGS` and the addition of `MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON` are a good thing. This essentially allows us to test this functionality even when `CHECKPOINT_RESTORE` is enabled. Since syzkaller has this enabled, this is something to consider later. Now, the meat of the change appears to be in `include/linux/mm.h` with the modification of `VM_SEALED_SYSMAP`. It introduces the following change, which is the crux of the issue: ```c #ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS extern bool mseal_sysmap_enabled; #define VM_SEALED_SYSMAP (mseal_sysmap_enabled ? VM_SEALED : VM_NONE) #else #define VM_SEALED_SYSMAP VM_NONE #endif ``` This macro change *does* affect compiled code. It replaces a compile-time constant with a runtime conditional check based on the `mseal_sysmap_enabled` boolean. This is a logic modification, plain and simple, and *could* be significant. It directly changes the behavior when we `mseal_sysmap_enabled` is set. The conditional logic gets used in various vDSO-related functions in `arch/x86/entry/vdso/vma.c`, `lib/vdso/datastore.c` and in `kernel/events/uprobes.c`. A key consideration here is that `mseal_sysmap_enabled` is controlled at runtime through `early_mseal_sysmap`, which is an `__init` function. Syzkaller cannot directly interact with `__init` functions. My initial thought was that the `early_mseal_sysmap` function might be reachable, but I was reminded that syzkaller runs in a *running* VM and, importantly, doesn't modify the boot parameters. Therefore, because `mseal_sysmap_enabled` has to be changed via early command line parameters, this path is *unreachable* for syzkaller. Considering the negative criteria, the documentation, user-space tools, and Kconfig changes alone would lead me to a WorthFuzzing=false decision, but since this commit now *allows* `MSEAL_SYSTEM_MAPPINGS` to co-exist with `CHECKPOINT_RESTORE`, and since this changes compiled C logic, it seems this is worth fuzzing. However, I can not specify the boot parameter or otherwise set this up for a fuzzing run. Thus, I am going to specify that `WorthFuzzing=false` due to being unreachable, with the caveat that if it was, it would be `WorthFuzzing=true`. In summary, given all of the above: **WorthFuzzing = false** |
| 12/2 | 2026/10/27 19:07 | tool | grepper |
0mArgs:{
"Expression": "map_vdso",
"PathPrefixes": [
"arch/x86"
]
}Results: {
"Output": "arch/x86/entry/vdso/vma.c=146=static const struct vm_special_mapping vvar_vclock_mapping = {\n--\narch/x86/entry/vdso/vma.c-155- */\narch/x86/entry/vdso/vma.c:156:static int map_vdso(const struct vdso_image *image, unsigned long addr)\narch/x86/entry/vdso/vma.c-157-{\n--\narch/x86/entry/vdso/vma.c-221-\narch/x86/entry/vdso/vma.c:222:int map_vdso_once(const struct vdso_image *image, unsigned long addr)\narch/x86/entry/vdso/vma.c-223-{\n--\narch/x86/entry/vdso/vma.c-245-\narch/x86/entry/vdso/vma.c:246:\treturn map_vdso(image, addr);\narch/x86/entry/vdso/vma.c-247-}\n--\narch/x86/entry/vdso/vma.c=249=static int load_vdso32(void)\n--\narch/x86/entry/vdso/vma.c-253-\narch/x86/entry/vdso/vma.c:254:\treturn map_vdso(\u0026vdso32_image, 0);\narch/x86/entry/vdso/vma.c-255-}\n--\narch/x86/entry/vdso/vma.c=257=int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp)\n--\narch/x86/entry/vdso/vma.c-262-\narch/x86/entry/vdso/vma.c:263:\t\treturn map_vdso(\u0026vdso64_image, 0);\narch/x86/entry/vdso/vma.c-264-\t}\n--\narch/x86/entry/vdso/vma.c=270=int compat_arch_setup_additional_pages(struct linux_binprm *bprm,\n--\narch/x86/entry/vdso/vma.c-275-\t\t\treturn 0;\narch/x86/entry/vdso/vma.c:276:\t\treturn map_vdso(\u0026vdsox32_image, 0);\narch/x86/entry/vdso/vma.c-277-\t}\n--\narch/x86/include/asm/vdso.h=37=extern int __init init_vdso_image(const struct vdso_image *image);\narch/x86/include/asm/vdso.h-38-\narch/x86/include/asm/vdso.h:39:extern int map_vdso_once(const struct vdso_image *image, unsigned long addr);\narch/x86/include/asm/vdso.h-40-\n--\narch/x86/kernel/process_64.c=783=EXPORT_SYMBOL_GPL(set_personality_ia32);\n--\narch/x86/kernel/process_64.c-785-#ifdef CONFIG_CHECKPOINT_RESTORE\narch/x86/kernel/process_64.c:786:static long prctl_map_vdso(const struct vdso_image *image, unsigned long addr)\narch/x86/kernel/process_64.c-787-{\n--\narch/x86/kernel/process_64.c-789-\narch/x86/kernel/process_64.c:790:\tret = map_vdso_once(image, addr);\narch/x86/kernel/process_64.c-791-\tif (ret)\n--\narch/x86/kernel/process_64.c=866=long do_arch_prctl_64(struct task_struct *task, int option, unsigned long arg2)\n--\narch/x86/kernel/process_64.c-943-\tcase ARCH_MAP_VDSO_X32:\narch/x86/kernel/process_64.c:944:\t\treturn prctl_map_vdso(\u0026vdsox32_image, arg2);\narch/x86/kernel/process_64.c-945-# endif\n--\narch/x86/kernel/process_64.c-947-\tcase ARCH_MAP_VDSO_32:\narch/x86/kernel/process_64.c:948:\t\treturn prctl_map_vdso(\u0026vdso32_image, arg2);\narch/x86/kernel/process_64.c-949-# endif\narch/x86/kernel/process_64.c-950-\tcase ARCH_MAP_VDSO_64:\narch/x86/kernel/process_64.c:951:\t\treturn prctl_map_vdso(\u0026vdso64_image, arg2);\narch/x86/kernel/process_64.c-952-#endif\n"
} |
| 13/2 | 2026/10/27 19:07 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 25417 output: 21 thoughts: 4216 Thoughts: **Analysis of the "mseal_system_mappings" Patch for Fuzzing Suitability** Okay, so I'm looking at this patch and my initial reaction is that `arch_setup_additional_pages` is called on every binary execution! And the related `ARCH_MAP_VDSO_*` functions through `arch_prctl` seem important. But I need to determine if this change warrants fuzzing. The original commit message isn't readily available, but I've reviewed the documentation and selftests to understand the patch's purpose. It's about introducing a boot parameter `mseal_system_mappings=0|1` to control the sealing of system mappings, and a Kconfig option `MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON`. Effectively, this patch allows enabling or disabling this feature at boot, and removing a restriction on the feature with CRIU/checkpoint-restore since those tools now have the feature disabled by default, or the new boot parameter allows the user to re-enable it. The main code change outside of initialization (`__init`) is the replacement of a simple `#define` with `#define VM_SEALED_SYSMAP (mseal_sysmap_enabled ? VM_SEALED : VM_NONE)`. Now, I'm trying to decide: WorthFuzzing=true or WorthFuzzing=false? Let's carefully consider both sides based on what I know. If I lean towards `WorthFuzzing = false`, it's because the patch appears to mostly involve unreachable code (the boot parameter parsing via `early_mseal_sysmap`), documentation changes, and Kconfig updates. Section 2 of the fuzzing guidelines says to return false "ONLY IF all modified code falls strictly into one or more of these categories". Specifically, `early_mseal_sysmap` is `__init`, and syzkaller *cannot* execute it; it's discarded from memory after boot. The core change, the macro `VM_SEALED_SYSMAP`, is just a conditional expression based on a boot-time flag `mseal_sysmap_enabled`, which is `__ro_after_init`. It doesn't introduce any new logic, data structures, or assertions. Now, if I try to argue for `WorthFuzzing = true`, it becomes trickier. Section 3 lists positive criteria that would apply. If I consider the macro change in `include/linux/mm.h` as "touching reachable executable code," then the patch *might* qualify. But then I'd have to choose a `FocusSymbol` which is the key to focus the fuzzing effort. Section 4 directs us to list functions that specifically implement the logic. In this case, `early_mseal_sysmap` would be on my list as implementing the main logic, but wait...it's an `__init` function and syzkaller can never reach that! What if I try callers of `VM_SEALED_SYSMAP`? I can list `arch_setup_additional_pages` which calls `map_vdso` which is called on EVERY execve, but the fuzzing guidelines warn against listing "ubiquitous lifecycle hot-paths" like that. Listing ubiquitous lifecycle hot-paths would dilute the fuzzing effort. Same with the uprobes related callers, those are not specific to this patch. Ultimately, the core logic change is just the introduction of a compile-time option that becomes a run-time option via a boot parameter. That boot parameter isn't something syzkaller fuzzes. There is no new runtime behavior that didn't exist before, the only change is allowing the user to select between what was available. There are no refactorings, assertions, new algorithms, or data structure changes to exercise. The macro expansion in the kernel is very straightforward and doesn't introduce any complex logic, and just results in either `VM_SEALED` or `VM_NONE`. Based on this, I'm leaning toward declaring **WorthFuzzing=false**. |
| 14/2 | 2026/10/27 19:08 | tool | grepper |
0mArgs:{
"Expression": "early_mseal_sysmap"
}Results: {
"Output": "mm/mseal.c=22=bool mseal_sysmap_enabled __ro_after_init =\n--\nmm/mseal.c-24-\nmm/mseal.c:25:static int __init early_mseal_sysmap(char *buf)\nmm/mseal.c-26-{\n--\nmm/mseal.c-28-}\nmm/mseal.c:29:early_param(\"mseal_system_mappings\", early_mseal_sysmap);\nmm/mseal.c-30-#endif\n"
} |
| 15/2 | 2026/10/27 19:08 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 30667 output: 21 thoughts: 62 Thoughts: Here's my summary, as if I were thinking it: **Investigating the `mseal` Implementation** Okay, so I need to understand what's happening around `mseal` within the kernel. My first instinct would be to check `git log` to see the commit history and surrounding context in `mm/mseal.c`. That would give me a clear picture of how this thing evolved. But wait, we don't have that tool available right now. No `git log`, huh? Alright, no problem. We do have `grepper`, which should work. Let's shift gears and search for other references to `mseal_sysmap_enabled`. That might uncover related code or documentation that sheds light on its purpose and usage, even without direct commit history. |
| 16/2 | 2026/10/27 19:08 | tool | grepper |
0mArgs:{
"Expression": "mseal_sysmap_enabled"
}Results: {
"Output": "include/linux/mm.h=285=enum {\n--\ninclude/linux/mm.h-570-#ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS\ninclude/linux/mm.h:571:extern bool mseal_sysmap_enabled;\ninclude/linux/mm.h:572:#define VM_SEALED_SYSMAP\t(mseal_sysmap_enabled ? VM_SEALED : VM_NONE)\ninclude/linux/mm.h-573-#else\n--\nmm/mseal.c-21-#ifdef CONFIG_MSEAL_SYSTEM_MAPPINGS\nmm/mseal.c:22:bool mseal_sysmap_enabled __ro_after_init =\nmm/mseal.c-23-\tIS_ENABLED(CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON);\n--\nmm/mseal.c=25=static int __init early_mseal_sysmap(char *buf)\nmm/mseal.c-26-{\nmm/mseal.c:27:\treturn kstrtobool(buf, \u0026mseal_sysmap_enabled);\nmm/mseal.c-28-}\n"
} |
| 17/2 | 2026/10/27 19:08 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 31210 output: 32 thoughts: 21 Thoughts: Okay, let's dive into this. Here's my take on understanding `sys_mseal` in `mm/mseal.c`: **Dissecting `sys_mseal` in `mm/mseal.c`** Alright, so I need to understand the mechanics of `sys_mseal`. I'm starting by zeroing in on the kernel code in `mm/mseal.c`. I'm going to look for the implementation of the system call `sys_mseal` to understand how this memory sealing functionality is designed. What are the key data structures, the crucial logic within this specific function, and the overall objectives? I'm expecting this will involve mapping virtual memory regions, checking permissions, and likely some cryptographic operations to create the "seal." I'm looking for the core idea: how is memory being protected, and how is the integrity of that protected memory guaranteed? I'll probably be dissecting this line by line until I have a strong grasp on the algorithm. |
| 18/2 | 2026/10/27 19:08 | tool | grepper |
0mArgs:{
"Expression": "SYSCALL_DEFINE",
"PathPrefixes": [
"mm/mseal.c"
]
}Results: {
"Output": "mm/mseal.c=101=void mseal_mmap_page_zero(void)\n--\nmm/mseal.c-129- */\nmm/mseal.c:130:SYSCALL_DEFINE3(mseal, unsigned long, start, size_t, len, unsigned long, flags)\nmm/mseal.c-131-{\n"
} |
| 19/2 | 2026/10/27 19:08 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 31578 output: 32 thoughts: 1868 Thoughts: **My Assessment of the Patch's Fuzzing Worthiness** Okay, let's break this down. My initial assessment is that this patch is *not* worth fuzzing, and I think I can defend that position. First, I need to look at what's been changed. The core of the patch seems to be around `mm/`, specifically related to memory sealing. I checked `mm/mseal.c` and confirmed that the `sys_mseal` system call, the main entry point for memory sealing functionality, is untouched. There are no modifications to any system call implementations, and no changes to any runtime functions within the `mm/` directory. The changes in `mm/` boil down to: 1. A boolean variable, `mseal_sysmap_enabled`, initialized using `IS_ENABLED(CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON)`. This is `__ro_after_init`. 2. An `__init` function called `early_mseal_sysmap`. 3. A preprocessor macro in `include/linux/mm.h`: `#define VM_SEALED_SYSMAP (mseal_sysmap_enabled ? VM_SEALED : VM_NONE)`. Now, the question becomes: is any of this reachable *during runtime* that a fuzzer like syzkaller would care about? `early_mseal_sysmap` is called *only* during early boot, parsing arguments, and is therefore unreachable for fuzzing purposes. It's marked as `__init`, so its code section is discarded after boot. The `mseal_sysmap_enabled` variable is read-only after initialization. The key is the preprocessor macro, `VM_SEALED_SYSMAP`. Previously, it was just `#define VM_SEALED_SYSMAP VM_SEALED`. Now, it's conditionally defined based on `mseal_sysmap_enabled`, toggling between the existing `VM_SEALED` and `VM_NONE` compile-time options. It is not new logic or a new data structure. Reading through the fuzzing guidelines, the primary focus is on reachability. The patch does *not* introduce new *reachable* code paths, new algorithms, or modifications that change existing code. Therefore, it does *not* meet the criteria for fuzzing. My reasoning, for saying `WorthFuzzing=false`, is because: 1. The C code changes are limited to a function used during early boot, which is inaccessible to syzkaller. 2. The runtime change consists of reading a read-only variable in a preprocessor macro, which toggles between existing compile-time options. 3. The remainder of the patch involves documentation, Kconfig changes, and selftests, all of which fall under the "not worth fuzzing" category. 4. There is no new runtime logic, no new data structures, and no new assertions. Now, let's consider a counter-argument - what if someone *did* argue for `WorthFuzzing=true`? What could they even point to? Let's check the guidelines again. Section 4 instructs us to create a `FocusSymbols` list to guide the fuzzer. But, what would go on it? * I can't put `early_mseal_sysmap` because it's `__init` and static. * I can't use a ubiquitous function like `map_vdso` or `vdso_install_vvar_mapping` because they are called on every `execve`. * I can't target `sys_mseal` because the patch does not modify it, and its code path does not use `VM_SEALED_SYSMAP`. There really is nothing here that would be an effective `FocusSymbol`, further solidifying my position: this patch introduces no new feature logic and is not worth fuzzing. |
| 20/2 | 2026/10/27 19:09 | tool | grepper |
0mError:no matches Args: {
"Expression": "VM_SEALED_SYSMAP",
"PathPrefixes": [
"mm/"
]
}Results: {
"error": "no matches"
} |
| 21/2 | 2026/10/27 19:09 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 34362 output: 220 thoughts: 2781 Thoughts: **Analysis of the Proposed Patch's Fuzzing Worthiness** Okay, let's break this down from a fuzzing perspective. The core of this patch seems to be about introducing a boot-time toggle for sealing system mappings, specifically the VDSO, and related uprobes mappings. Initially, I saw `VM_SEALED_SYSMAP`, and was a little concerned, but then I remember that `mm/` is off-limits and the patch is primarily changing how `VM_SEALED_SYSMAP` is defined, and when it's used. It is ONLY used in three places, and *only* during initial mapping setup which is fine for `VM_SEALED_SYSMAP`. It is only used at those times: - `arch/x86/entry/vdso/vma.c` (and arm64, loongarch, riscv, s390) - `kernel/events/uprobes.c` - `lib/vdso/datastore.c` I recall that `VM_SEALED_SYSMAP` is basically just setting the `VM_SEALED` bit, which is used for these special mappings. Before this patch, the behavior depended on `CONFIG_MSEAL_SYSTEM_MAPPINGS` being enabled or not. This patch simply introduces a `mseal_system_mappings` kernel parameter, controlled by `CONFIG_MSEAL_SYSTEM_MAPPINGS_DEFAULT_ON`. So, the patch is just about making that config, controlled at *compile* time, now controllable at *boot* time, not compile time. The first question is: Can a fuzzer, like Syzkaller, trigger any issues? No. Syzkaller doesn't fuzz early boot code, so that is not a worry. Secondly, it is also fine because there are not any runtime code modifications, so runtime bugs are not possible either. This patch *should not* introduce any new runtime algorithms or data structures. I need to make sure I am not missing anything that can be exploited by fuzzers. I remember the section about when `WorthFuzzing=false`. It explicitly lists categories of code that are not worth fuzzing. I need to check if the patch falls strictly into those categories. The `early_mseal_sysmap` function is executed only during the kernel boot process, which means it's an `__init` function and early-boot parameter handler. Syzkaller cannot reach any `__init` code. The remaining changes are documentation, selftests, Kconfig, and a macro change in `include/linux/mm.h`, which is safe and expected. `early_mseal_sysmap` is `static int __init`! I think I see it. It looks like the relevant categories are: "Non-kernel and non-executable changes" and "Unreachable execution paths." The early boot code is structurally unreachable at runtime. And changing a compile-time constant within a macro definition to reference a boot-initialized variable does not alter anything. Let me verify: 1. Documentation, Kconfig, tools/testing/selftests (non-executable). 2. `early_mseal_sysmap()` is an `__init` function (unreachable). 3. The macro is just conditional constant substitution (non-executable). No `.c` file was modified other than `mm/mseal.c`, only adding `early_mseal_sysmap`. So, this patch should be marked as not worth fuzzing. It does not introduce any runtime code changes that could be triggered by a fuzzer. All the modified C code is unreachable at runtime. The patch simply changes the method of controlling a *existing* security configuration (sealed mappings) from compile-time to boot-time. I need to remember that Reachability is THE primary gate. My conclusion: Based on the reachability of the modified code and its nature, this patch does not warrant fuzzing. My `set-results` arguments: * `WorthFuzzing`: `false` * `FocusSymbols`: `[]` * `EnableConfigs`: `[]` * `Reasoning`: "The patch introduces a kernel boot command line parameter `mseal_system_mappings=` to enable/disable sealing of system mappings at boot. The only C function added is `early_mseal_sysmap()`, which is an `__init` early parameter parsing handler executed strictly during boot before userspace initialization and discarded, making it structurally unreachable by syzkaller at runtime. The macro `VM_SEALED_SYSMAP` in `include/linux/mm.h` is updated to read the `__ro_after_init` boot flag `mseal |
| 22/2 | 2026/10/27 19:09 | tool | set-results |
0mArgs:{
"EnableConfigs": [],
"FocusSymbols": [],
"Reasoning": "The patch introduces the 'mseal_system_mappings=' early boot command-line parameter and associated Kconfig options to enable or disable sealing of system mappings at boot time. The only C function introduced is early_mseal_sysmap(), which is marked __init and only executes during early boot before userspace starts; its code is discarded from memory (free_initmem()) and is structurally unreachable during syzkaller runtime fuzzing. The change in include/linux/mm.h simply evaluates a read-only boot flag (mseal_sysmap_enabled) in the VM_SEALED_SYSMAP macro to choose between existing flags (VM_SEALED or VM_NONE), introducing no new runtime logic, data structures, or assertions. The remainder of the patch consists of documentation, Kconfig updates, and userspace selftests. Hence, there is no reachable executable kernel logic worth fuzzing.",
"WorthFuzzing": false
}Results: {
"EnableConfigs": null,
"FocusSymbols": [],
"Reasoning": "The patch introduces the 'mseal_system_mappings=' early boot command-line parameter and associated Kconfig options to enable or disable sealing of system mappings at boot time. The only C function introduced is early_mseal_sysmap(), which is marked __init and only executes during early boot before userspace starts; its code is discarded from memory (free_initmem()) and is structurally unreachable during syzkaller runtime fuzzing. The change in include/linux/mm.h simply evaluates a read-only boot flag (mseal_sysmap_enabled) in the VM_SEALED_SYSMAP macro to choose between existing flags (VM_SEALED or VM_NONE), introducing no new runtime logic, data structures, or assertions. The remainder of the patch consists of documentation, Kconfig updates, and userspace selftests. Hence, there is no reachable executable kernel logic worth fuzzing.",
"WorthFuzzing": false
} |
| 23/1 | 2026/10/27 19:09 | action | If |
0mArgs:{
"WorthFuzzing": false
}Results: null |
| Total Calls | Total Tokens | Avg Tokens | Total Duration (Seconds) | Avg Duration (Seconds) |
|---|
| Total Calls | Total Duration (Seconds) | Avg Duration (Seconds) |
|---|