Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/1.1/patches/2222214/?format=api
{ "id": 2222214, "url": "http://patchwork.ozlabs.org/api/1.1/patches/2222214/?format=api", "web_url": "http://patchwork.ozlabs.org/project/netfilter-devel/patch/20260410204843.64259-1-xmei5@asu.edu/", "project": { "id": 26, "url": "http://patchwork.ozlabs.org/api/1.1/projects/26/?format=api", "name": "Netfilter Development", "link_name": "netfilter-devel", "list_id": "netfilter-devel.vger.kernel.org", "list_email": "netfilter-devel@vger.kernel.org", "web_url": null, "scm_url": null, "webscm_url": null }, "msgid": "<20260410204843.64259-1-xmei5@asu.edu>", "date": "2026-04-10T20:48:43", "name": "[nf] netfilter: nfnetlink_osf: fix divide-by-zero in OSF_WSS_MODULO", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "df78353b86a7a137451413168875447459db963d", "submitter": { "id": 93033, "url": "http://patchwork.ozlabs.org/api/1.1/people/93033/?format=api", "name": "Xiang Mei", "email": "xmei5@asu.edu" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/netfilter-devel/patch/20260410204843.64259-1-xmei5@asu.edu/mbox/", "series": [ { "id": 499505, "url": "http://patchwork.ozlabs.org/api/1.1/series/499505/?format=api", "web_url": "http://patchwork.ozlabs.org/project/netfilter-devel/list/?series=499505", "date": "2026-04-10T20:48:43", "name": "[nf] netfilter: nfnetlink_osf: fix divide-by-zero in OSF_WSS_MODULO", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/499505/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2222214/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2222214/checks/", "tags": {}, "headers": { "Return-Path": "\n <netfilter-devel+bounces-11814-incoming=patchwork.ozlabs.org@vger.kernel.org>", "X-Original-To": [ "incoming@patchwork.ozlabs.org", "netfilter-devel@vger.kernel.org" ], "Delivered-To": "patchwork-incoming@legolas.ozlabs.org", "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=asu.edu header.i=@asu.edu header.a=rsa-sha256\n header.s=google header.b=HioFDOg8;\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=netfilter-devel+bounces-11814-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)", "smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=asu.edu header.i=@asu.edu\n header.b=\"HioFDOg8\"", "smtp.subspace.kernel.org;\n arc=none smtp.client-ip=74.125.82.44", "smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=asu.edu", "smtp.subspace.kernel.org;\n spf=pass smtp.mailfrom=asu.edu" ], "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 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fspn35S9mz1yGS\n\tfor <incoming@patchwork.ozlabs.org>; Sat, 11 Apr 2026 06:48:55 +1000 (AEST)", "from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby tor.lore.kernel.org (Postfix) with ESMTP id E6E72302D97D\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 10 Apr 2026 20:48:52 +0000 (UTC)", "from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id EC89C3A6B66;\n\tFri, 10 Apr 2026 20:48:51 +0000 (UTC)", "from mail-dl1-f44.google.com (mail-dl1-f44.google.com\n [74.125.82.44])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id 091FA2F5491\n\tfor <netfilter-devel@vger.kernel.org>; Fri, 10 Apr 2026 20:48:49 +0000 (UTC)", "by mail-dl1-f44.google.com with SMTP id\n a92af1059eb24-12c19d23b19so2572730c88.0\n for <netfilter-devel@vger.kernel.org>;\n Fri, 10 Apr 2026 13:48:49 -0700 (PDT)", "from p1.scai.dhcp.asu.edu (209-147-138-15.nat.asu.edu.\n [209.147.138.15])\n by smtp.gmail.com with ESMTPSA id\n a92af1059eb24-12c345a9623sm4796228c88.4.2026.04.10.13.48.48\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Fri, 10 Apr 2026 13:48:48 -0700 (PDT)" ], "ARC-Seal": "i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1775854131; cv=none;\n b=rNBspOtFlFqV3usIICsIsFvKE9XyHTNynCuUdm9sTyvzyZfC/0C1B6spFsBZ1G+ldijAYUJxP9Ia/OaJess2R5jTUWWQX5LSgd74hKvunSK2Lr8NQTMaDIfYefBzXYWLPem1pFiwFOmd1eRBfXA+xxMnZkVf2ZE4rgE92jkNOvo=", "ARC-Message-Signature": "i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1775854131; c=relaxed/simple;\n\tbh=7ikf22Yk9gDKjKnQ4vG7L4LBTt9F/m2LDetXkk9Vbcw=;\n\th=From:To:Cc:Subject:Date:Message-ID:MIME-Version;\n b=tM9Am8wMDDpkCFMViMWFpO6EYXCn6zIvcVdhtX22bjsgv8lT0naeiCReba8nfU1c2ndSBtWlIqCLARfP/VpiROxSTAy1WipyCfk0fyEoj+MY0MQg/r0blYWn1O9tJ4EUb3QeLcpmt/Zi9jEOhyEt6vxufZ3XTlOh//M/xpNJ6dM=", "ARC-Authentication-Results": "i=1; smtp.subspace.kernel.org;\n dmarc=pass (p=none dis=none) header.from=asu.edu;\n spf=pass smtp.mailfrom=asu.edu;\n dkim=pass (2048-bit key) header.d=asu.edu header.i=@asu.edu\n header.b=HioFDOg8; arc=none smtp.client-ip=74.125.82.44", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=asu.edu; s=google; t=1775854129; x=1776458929; darn=vger.kernel.org;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:from:to:cc:subject:date:message-id:reply-to;\n bh=o8Z8RVZ7gmrp+TUiE+Acjq5yoAXHwEewB9LLWN/bJr4=;\n b=HioFDOg88DYUziL3eaKgknZujplVAZLVfZqxF8lAMocSrgJ6MXId9sRgxVEH96yCLT\n 8br/Sa1f+42LvO0IGSoB725YYe0ItRnxx0nHlDemqvyOmy0O53FZ44bUm6z/mGqo1k/r\n y/MzgTzLMUL+FAZ5xjpCrRJiHyWgMWQ9jCycpecsrJX+5Ilx23GWaZHx5IvdWsqUUWeu\n oWX3gZ1h8INlydsKui6pTBIz/TqyXEU+HDVbFpNAZosoDeKAxXUlu2cTuRiWFjoFyxIP\n O1VnrFVeEQFcInv2xjPaLyAIizyV5gFHgJKvDWxDEPJOYQ0EcX88nrfBrF4l4INefZwU\n 6djg==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1775854129; x=1776458929;\n h=content-transfer-encoding:mime-version:message-id:date:subject:cc\n :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date\n :message-id:reply-to;\n bh=o8Z8RVZ7gmrp+TUiE+Acjq5yoAXHwEewB9LLWN/bJr4=;\n b=VsbpVlgJm4PLrv6k+N76YqRxeuBvReQt2ys93FO2DtWzoPoJFqOt/5AWXFSEsM/QMA\n P9CaoM6E4pWhjkbLzhuIJ5orBXpLyYRKYDc0nRt9e2dDKEnz5xDcwWdgR5u69Y2GZH7b\n JVETRbu+unRHWJT3+zluIQqZ1y/qx73zzs3ZI8Ao4c45CJaPAtPHkwTdCg+tw2E0qhss\n 88aa+laZZxaAysb2VebL37zLm+xZD+RJMs1Aoc2W3RgrtkOjUqE4duP+NRPMNFtxKzCW\n 5w1kz/ojadaPHhRl8vw4UrHmMVwAu7Q46KtKh78GVlquGFma3VQdYqYLE57W+bBytcbb\n IEmA==", "X-Gm-Message-State": "AOJu0Yxcre7fFD5aNNxNVe/q/mbyLb0WjOG0+T4iL6Tz29QC0hSxn0oN\n\tIBZearScVMZlyMxSsSd94ELzj7PwcWtplxQWzl08hnlZgm7THi7HJGpyJ+Tp40koLRd7ypLI0+c\n\tJc4kITw==", "X-Gm-Gg": "AeBDietWzCwfhKswjFDu1PDVcvHyBoUFf1VqGKR3rv8NI2IBxm3kdaULBbCkqLJTWi7\n\tGOZdFZqCqisXHHHGy+HOc1TiQCbN/JJNNe5WVIM1IHmLdJ6H4MtEXSYBnW2mHvVm6JnEuMAsE/t\n\t2OzS0SPYd7sOYUxldcS3ROmJnjYR+Vn/nwEa2A8RNrwIE+V4qXrGP0cZRUAWL86ud/ZyiDHs4Pf\n\thCoaL85r3140wMBV18UtEsqeKazNcmAZYWePxTO+bWZBforZB0RK7BlHXQRraC6bvomg2Pwtft9\n\tRQLdM28Zx37oi0xlQHbMsW3tbHTG+Gf+ARKtGC5zMBgMHHnqedkVGtbT5+svce0uxXJEFKvMmDQ\n\tnIXAA3Hd/d7ob1EfJTPIQHvRPM7BkqzO0WOreSek8wxDM14oetKkxgGqOrVje8Pvl6asuZQrK5M\n\txOJQknD2vmfAyCayo3o9yAkDCUKrrnbOxOKERwht5sNqtp3+cifkmx9A==", "X-Received": "by 2002:a05:7022:4589:b0:12a:6902:ddce with SMTP id\n a92af1059eb24-12c34e6012fmr2803898c88.10.1775854128840;\n Fri, 10 Apr 2026 13:48:48 -0700 (PDT)", "From": "Xiang Mei <xmei5@asu.edu>", "To": "netfilter-devel@vger.kernel.org", "Cc": "Pablo Neira Ayuso <pablo@netfilter.org>,\n\tFlorian Westphal <fw@strlen.de>,\n\tPhil Sutter <phil@nwl.cc>,\n\tcoreteam@netfilter.org,\n\tWeiming Shi <bestswngs@gmail.com>,\n\tXiang Mei <xmei5@asu.edu>", "Subject": "[PATCH nf] netfilter: nfnetlink_osf: fix divide-by-zero in\n OSF_WSS_MODULO", "Date": "Fri, 10 Apr 2026 13:48:43 -0700", "Message-ID": "<20260410204843.64259-1-xmei5@asu.edu>", "X-Mailer": "git-send-email 2.43.0", "Precedence": "bulk", "X-Mailing-List": "netfilter-devel@vger.kernel.org", "List-Id": "<netfilter-devel.vger.kernel.org>", "List-Subscribe": "<mailto:netfilter-devel+subscribe@vger.kernel.org>", "List-Unsubscribe": "<mailto:netfilter-devel+unsubscribe@vger.kernel.org>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit" }, "content": "The OSF_WSS_MODULO branch in nf_osf_match_one() performs:\n\n ctx->window % f->wss.val\n\nwithout guarding against f->wss.val == 0. A user with CAP_NET_ADMIN\ncan add an OSF fingerprint with wss.wc = OSF_WSS_MODULO and wss.val = 0\nvia nfnetlink. When a matching TCP SYN packet arrives, the kernel\nexecutes a division by zero and panics.\n\nThe OSF_WSS_PLAIN case already treats val == 0 as a wildcard (match\neverything). Apply the same semantics to OSF_WSS_MODULO: if val is 0,\nany window value matches rather than dividing by zero.\n\nCrash:\n Oops: divide error: 0000 [#1] SMP KASAN NOPTI\n RIP: 0010:nf_osf_match_one (net/netfilter/nfnetlink_osf.c:98)\n Call Trace:\n <IRQ>\n nf_osf_match (net/netfilter/nfnetlink_osf.c:220 (discriminator 6))\n xt_osf_match_packet (net/netfilter/xt_osf.c:32)\n ipt_do_table (net/ipv4/netfilter/ip_tables.c:348)\n nf_hook_slow (net/netfilter/core.c:622 (discriminator 1))\n ip_local_deliver (net/ipv4/ip_input.c:265)\n ip_rcv (include/linux/skbuff.h:1162)\n __netif_receive_skb_one_core (net/core/dev.c:6181)\n process_backlog (.include/linux/skbuff.h:2502 net/core/dev.c:6642)\n __napi_poll (net/core/dev.c:7710)\n net_rx_action (net/core/dev.c:7945)\n handle_softirqs (kernel/softirq.c:622)\n\nFixes: 31a9c29210e2 (\"netfilter: nf_osf: add struct nf_osf_hdr_ctx\")\nReported-by: Weiming Shi <bestswngs@gmail.com>\nSigned-off-by: Xiang Mei <xmei5@asu.edu>\n---\n net/netfilter/nfnetlink_osf.c | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)", "diff": "diff --git a/net/netfilter/nfnetlink_osf.c b/net/netfilter/nfnetlink_osf.c\nindex 45d9ad231..193436aa9 100644\n--- a/net/netfilter/nfnetlink_osf.c\n+++ b/net/netfilter/nfnetlink_osf.c\n@@ -150,7 +150,7 @@ static bool nf_osf_match_one(const struct sk_buff *skb,\n \t\t\t\tfmatch = FMATCH_OK;\n \t\t\tbreak;\n \t\tcase OSF_WSS_MODULO:\n-\t\t\tif ((ctx->window % f->wss.val) == 0)\n+\t\t\tif (f->wss.val == 0 || (ctx->window % f->wss.val) == 0)\n \t\t\t\tfmatch = FMATCH_OK;\n \t\t\tbreak;\n \t\t}\n", "prefixes": [ "nf" ] }