get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/2217888/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 2217888,
    "url": "http://patchwork.ozlabs.org/api/patches/2217888/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/linux-cifs-client/patch/f6jyHqZ0Ycp1KP50Nf0K6QULaw7WbojZIPK4NrYYw6zNoj93MvpecYMT0xE5mjChSgdLhieKk9rpjUDjWtY73UAjwFGS85VxlkO4yJuEInE=@proton.me/",
    "project": {
        "id": 12,
        "url": "http://patchwork.ozlabs.org/api/projects/12/?format=api",
        "name": "Linux CIFS Client",
        "link_name": "linux-cifs-client",
        "list_id": "linux-cifs.vger.kernel.org",
        "list_email": "linux-cifs@vger.kernel.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<f6jyHqZ0Ycp1KP50Nf0K6QULaw7WbojZIPK4NrYYw6zNoj93MvpecYMT0xE5mjChSgdLhieKk9rpjUDjWtY73UAjwFGS85VxlkO4yJuEInE=@proton.me>",
    "list_archive_url": null,
    "date": "2026-03-30T21:10:14",
    "name": "fs/smb/client: fix out-of-bounds read in cifs_sanitize_prepath",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "5c6ef3a0cc3d35ec310e78594ab92790726e6fa1",
    "submitter": {
        "id": 92999,
        "url": "http://patchwork.ozlabs.org/api/people/92999/?format=api",
        "name": "FredTheDude",
        "email": "FredTheDude@proton.me"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/linux-cifs-client/patch/f6jyHqZ0Ycp1KP50Nf0K6QULaw7WbojZIPK4NrYYw6zNoj93MvpecYMT0xE5mjChSgdLhieKk9rpjUDjWtY73UAjwFGS85VxlkO4yJuEInE=@proton.me/mbox/",
    "series": [
        {
            "id": 498095,
            "url": "http://patchwork.ozlabs.org/api/series/498095/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/linux-cifs-client/list/?series=498095",
            "date": "2026-03-30T21:10:14",
            "name": "fs/smb/client: fix out-of-bounds read in cifs_sanitize_prepath",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/498095/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2217888/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2217888/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "\n <linux-cifs+bounces-10585-incoming=patchwork.ozlabs.org@vger.kernel.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "linux-cifs@vger.kernel.org"
        ],
        "Delivered-To": "patchwork-incoming@legolas.ozlabs.org",
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n secure) header.d=proton.me header.i=@proton.me header.a=rsa-sha256\n header.s=protonmail header.b=YidgZ1o9;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c04:e001:36c::12fc:5321; helo=tor.lore.kernel.org;\n envelope-from=linux-cifs+bounces-10585-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)",
            "smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=proton.me header.i=@proton.me\n header.b=\"YidgZ1o9\"",
            "smtp.subspace.kernel.org;\n arc=none smtp.client-ip=85.9.210.45",
            "smtp.subspace.kernel.org;\n dmarc=pass (p=quarantine dis=none) header.from=proton.me",
            "smtp.subspace.kernel.org;\n spf=pass smtp.mailfrom=proton.me"
        ],
        "Received": [
            "from tor.lore.kernel.org (tor.lore.kernel.org\n [IPv6:2600:3c04:e001:36c::12fc:5321])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fl3n84kNbz1yCp\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 31 Mar 2026 08:10:36 +1100 (AEDT)",
            "from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby tor.lore.kernel.org (Postfix) with ESMTP id 54C07300B549\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 30 Mar 2026 21:10:34 +0000 (UTC)",
            "from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id A631939F181;\n\tMon, 30 Mar 2026 21:10:32 +0000 (UTC)",
            "from mail-06.mail-europe.com (mail-06.mail-europe.com [85.9.210.45])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id 1092239EF1A\n\tfor <linux-cifs@vger.kernel.org>; Mon, 30 Mar 2026 21:10:27 +0000 (UTC)"
        ],
        "ARC-Seal": "i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1774905032; cv=none;\n b=DOUDMQtzaKMNCTvQnDnCFC9jh6g+jaMnyWTtXX1ls7hRk1TdrZAYHKhnn44lpaEfeiRGkVVp4gaWjTShXYdfbNRll7D3d+2dC+Ttpj7SJ9iS2GnZSvWuYzHaeg3oJlKVof3KuN1Ice4/5Ytz4pTU1GF/HhfjOjYCS9Y7pkjryxk=",
        "ARC-Message-Signature": "i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1774905032; c=relaxed/simple;\n\tbh=GU5VXvQJFY0/uC9eC9G7mqYpq09UbP5fOBc8AiA1Qcg=;\n\th=Date:To:From:Cc:Subject:Message-ID:MIME-Version:Content-Type;\n b=J710woWVnS6gSJUpYderqEr7TU5iaOaZ2qWOC04iMSuE0F+gPQa2SNA+HQJ/8wboxWESoKKqXIBcvi5P0jsFU0pG1wXuCRvMC4D3jm2Nim3sgxKA9kXpan14qg3KhT/19Ty/u5eVhJIH7wRIEKT5xKtgYtWoJZtEPM+8SjdyVkU=",
        "ARC-Authentication-Results": "i=1; smtp.subspace.kernel.org;\n dmarc=pass (p=quarantine dis=none) header.from=proton.me;\n spf=pass smtp.mailfrom=proton.me;\n dkim=pass (2048-bit key) header.d=proton.me header.i=@proton.me\n header.b=YidgZ1o9; arc=none smtp.client-ip=85.9.210.45",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=proton.me;\n\ts=protonmail; t=1774905018; x=1775164218;\n\tbh=X3Q+LYlTt9jH2ObR7NqgyduNMxki+7TD4MsYI73loVU=;\n\th=Date:To:From:Cc:Subject:Message-ID:Feedback-ID:From:To:Cc:Date:\n\t Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector;\n\tb=YidgZ1o9dHwg6MBJ4a17bJ7K+eaU2hEBwm7yAE6SzkbM9eFNsM8CLmjb9xtHjdMSN\n\t CRvqFeXWHJlnkBPHVL202bChwChyWOwlP8l1xsCD0UdFzA8jo8qC6y4U8PaLjsT+9d\n\t orLIHO+NSO8/jFe/+Q8d7qwepgqcJ/Bpw13qS8zmdpJArX7H+Ss5+WuzI5kJhL7Rlq\n\t NSOajPV1t5IUZsP70wyH4QfaN8uIfuQWPb4PhuA05GW8Mc/it4w9cqmEVpVZMk3i+W\n\t Y76Iv6f7MptgabKXKF10zT55kL/7hPSIfjTxYhNrTK6ZqwlHW1SaPmDZzPR1Cwj+oW\n\t FU6A7diiKMgrA==",
        "Date": "Mon, 30 Mar 2026 21:10:14 +0000",
        "To": "\"sfrench@samba.org\" <sfrench@samba.org>",
        "From": "FredTheDude <FredTheDude@proton.me>",
        "Cc": "\"linux-cifs@vger.kernel.org\" <linux-cifs@vger.kernel.org>",
        "Subject": "[PATCH] fs/smb/client: fix out-of-bounds read in\n  cifs_sanitize_prepath",
        "Message-ID": "\n <f6jyHqZ0Ycp1KP50Nf0K6QULaw7WbojZIPK4NrYYw6zNoj93MvpecYMT0xE5mjChSgdLhieKk9rpjUDjWtY73UAjwFGS85VxlkO4yJuEInE=@proton.me>",
        "Feedback-ID": "151443565:user:proton",
        "X-Pm-Message-ID": "c6e4555d1b2a40993c960e2445828e088e2f08c4",
        "Precedence": "bulk",
        "X-Mailing-List": "linux-cifs@vger.kernel.org",
        "List-Id": "<linux-cifs.vger.kernel.org>",
        "List-Subscribe": "<mailto:linux-cifs+subscribe@vger.kernel.org>",
        "List-Unsubscribe": "<mailto:linux-cifs+unsubscribe@vger.kernel.org>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=utf-8",
        "Content-Transfer-Encoding": "quoted-printable"
    },
    "content": "When cifs_sanitize_prepath is called with an empty string or a string\ncontaining only delimiters (e.g., \"/\"), the current logic attempts to\ncheck *(cursor2 - 1) before cursor2 has advanced. This results in an\nout-of-bounds read.\n\nThis patch adds an early exit check after stripping prepended\ndelimiters. If no path content remains, the function returns NULL.\n\nThe bug was identified via manual audit and verified using a\nstandalone test case compiled with AddressSanitizer, which\ntriggered a SEGV on affected inputs.\n\nSigned-off-by: Fredric Cover <FredTheDude@proton.me>\n\n---\n\nIf I made any stupid mistakes, let me know.\nI am just a high-school freshman, and I have a lot to learn, especially in C.\nThanks for taking your time to look at my patch.\n---\n fs/smb/client/fs_context.c | 4 ++++\n 1 file changed, 4 insertions(+)\n\n--\n2.43.0",
    "diff": "diff --git a/fs/smb/client/fs_context.c b/fs/smb/client/fs_context.c\nindex 03c112f4d..3f0faae99 100644\n--- a/fs/smb/client/fs_context.c\n+++ b/fs/smb/client/fs_context.c\n@@ -588,6 +588,10 @@ char *cifs_sanitize_prepath(char *prepath, gfp_t gfp)\n        while (IS_DELIM(*cursor1))\n                cursor1++;\n\n+       /* exit in case of only delimiters */\n+       if (!*cursor1)\n+               return NULL;\n+\n        /* copy the first letter */\n        *cursor2 = *cursor1;\n\n",
    "prefixes": []
}