)]}'
{
  "commit": "079a028d6327e68cfa5d38b36123637b321c19a7",
  "tree": "d6bed2ef9b0f5969d1105f010d8b4a8804a13f61",
  "parents": [
    "58c4ce8cd6cd1fbf1bca2e1d1f42f9e2899fa934"
  ],
  "author": {
    "name": "Kees Cook",
    "email": "kees@kernel.org",
    "time": "Mon Mar 23 01:27:25 2026 +0000"
  },
  "committer": {
    "name": "Kees Cook",
    "email": "kees@kernel.org",
    "time": "Thu Jun 18 16:39:31 2026 -0700"
  },
  "message": "string: Remove strncpy() from the kernel\n\nstrncpy() has been a persistent source of bugs due to its ambiguous\nintended usage and frequently counter-intuitive semantics: it may not\nNUL-terminate the destination, and it unconditionally zero-pads to the\nfull length, which isn\u0027t always needed. All former callers have been\nmigrated[1] to:\n\n  - strscpy()        for NUL-terminated destinations\n  - strscpy_pad()    for NUL-terminated destinations needing zero-padding\n  - strtomem_pad()   for non-NUL-terminated fixed-width fields\n  - memcpy_and_pad() for bounded copies with explicit padding\n  - memcpy()         for known-length copies\n\nRemove the generic implementation, its declaration, the FORTIFY_SOURCE\nwrapper, and associated tests.\n\nLink: https://github.com/KSPP/linux/issues/90 [1]\nSigned-off-by: Kees Cook \u003ckees@kernel.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "03de71f654c76f4895cd8068d77c0a1c3197e297",
      "old_mode": 33188,
      "old_path": "Documentation/process/deprecated.rst",
      "new_id": "22a5e62c92eaf206c5b0a3cd4885bd30a1295211",
      "new_mode": 33188,
      "new_path": "Documentation/process/deprecated.rst"
    },
    {
      "type": "modify",
      "old_id": "7615a02dfc477ae7fb185ce6801ced2c78c1e823",
      "old_mode": 33188,
      "old_path": "drivers/misc/lkdtm/fortify.c",
      "new_id": "5e66707e11804412709a30ffc097d37ed3d019e9",
      "new_mode": 33188,
      "new_path": "drivers/misc/lkdtm/fortify.c"
    },
    {
      "type": "modify",
      "old_id": "171982e53c9aa0ccb56a0464bc95e11aaa7bbabd",
      "old_mode": 33188,
      "old_path": "include/linux/fortify-string.h",
      "new_id": "cf841dc71feffd82c266b225624a0a2c714c6ea7",
      "new_mode": 33188,
      "new_path": "include/linux/fortify-string.h"
    },
    {
      "type": "modify",
      "old_id": "b850bd91b3d88406f3fc7ee44bc8129007bf376a",
      "old_mode": 33188,
      "old_path": "include/linux/string.h",
      "new_id": "5702daca4326b7ebbfcecf6a84f710fe75ef8542",
      "new_mode": 33188,
      "new_path": "include/linux/string.h"
    },
    {
      "type": "modify",
      "old_id": "b632c71df1a5061256f556c40a30587cf45dce18",
      "old_mode": 33188,
      "old_path": "lib/string.c",
      "new_id": "45ca1cfe0184466e2ceb150f72ce2a3cc2e53452",
      "new_mode": 33188,
      "new_path": "lib/string.c"
    },
    {
      "type": "delete",
      "old_id": "8dcfb8c788dd2f61529ba44902bebc8b2d6e8560",
      "old_mode": 33188,
      "old_path": "lib/test_fortify/write_overflow-strncpy-src.c",
      "new_id": "0000000000000000000000000000000000000000",
      "new_mode": 0,
      "new_path": "/dev/null"
    },
    {
      "type": "delete",
      "old_id": "b85f079c815dd710d411646b43f0f34d1cf2b0ad",
      "old_mode": 33188,
      "old_path": "lib/test_fortify/write_overflow-strncpy.c",
      "new_id": "0000000000000000000000000000000000000000",
      "new_mode": 0,
      "new_path": "/dev/null"
    },
    {
      "type": "modify",
      "old_id": "fc9c76f026d636e4e3a74292be40988df38dec44",
      "old_mode": 33188,
      "old_path": "lib/tests/fortify_kunit.c",
      "new_id": "413cdbf3dc0da3c7bec127db44004b46dc1e31f7",
      "new_mode": 33188,
      "new_path": "lib/tests/fortify_kunit.c"
    }
  ]
}
