| Seq | Timestamp | Type | Name | Duration |
|---|---|---|---|---|
| 0/0 | 2026/07/25 20:28 | flow | patch-triage |
0mArgs:null Results: {
"EnableConfigs": [
"PACKET"
],
"FocusSymbols": [
"packet_sendmsg",
"packet_sendmsg_spkt"
],
"Reasoning": "The patch modifies `packet_parse_headers` in `net/packet/af_packet.c`, which is called during packet transmission on AF_PACKET sockets. It moves `skb_reset_mac_header(skb)` out of an if-condition, ensuring the MAC header is always reset for all socket types. This is a functional change in the core networking packet transmission path and should be fuzzed.",
"WorthFuzzing": true
} |
| 1/1 | 2026/07/25 20:28 | action | read-patch-diff |
0mArgs:null Results: {
"PatchDiff": "commit 8ed3d89b558a621e9e57bc0870835747f12d30e5\nAuthor: syz-cluster \u003ctriage@syzkaller.com\u003e\nDate: Sat Jul 25 20:28:19 2026 +0000\n\n syz-cluster: applied patch under review\n\ndiff --git a/net/packet/af_packet.c b/net/packet/af_packet.c\nindex e75d2932475ac0..5ae0511e89e32c 100644\n--- a/net/packet/af_packet.c\n+++ b/net/packet/af_packet.c\n@@ -1924,11 +1924,12 @@ static void packet_parse_headers(struct sk_buff *skb, struct socket *sock)\n {\n \tint depth;\n \n+\t/* On TX skb-\u003edata is the L2 header; anchor it for all socket types. */\n+\tskb_reset_mac_header(skb);\n+\n \tif ((!skb-\u003eprotocol || skb-\u003eprotocol == htons(ETH_P_ALL)) \u0026\u0026\n-\t sock-\u003etype == SOCK_RAW) {\n-\t\tskb_reset_mac_header(skb);\n+\t sock-\u003etype == SOCK_RAW)\n \t\tskb-\u003eprotocol = dev_parse_header_protocol(skb);\n-\t}\n \n \t/* Move network header to the right position for VLAN tagged packets */\n \tif (likely(skb-\u003edev-\u003etype == ARPHRD_ETHER) \u0026\u0026\n"
} |
| 2/1 | 2026/07/25 20:28 | agent | patch-evaluator |
0mModel:best-expensive Args: null Results: {
"EnableConfigs": [
"PACKET"
],
"FocusSymbols": [
"packet_sendmsg",
"packet_sendmsg_spkt"
],
"Reasoning": "The patch modifies `packet_parse_headers` in `net/packet/af_packet.c`, which is called during packet transmission on AF_PACKET sockets. It moves `skb_reset_mac_header(skb)` out of an if-condition, ensuring the MAC header is always reset for all socket types. This is a functional change in the core networking packet transmission path and should be fuzzed.",
"WorthFuzzing": true
}Instruction: You are an expert Linux kernel maintainer. Your job is to review a provided patch series and determine if it makes functional changes to the kernel that should be fuzzed. IMPORTANT: The changes have ALREADY been applied and committed as the HEAD commit in your workspace. Do NOT rely on your internal knowledge of the kernel. You must actively use your code access tools to examine the actual source code and confirm any assumptions. Return WorthFuzzing=false if the patch only contains: - Modifications to Documentation/, Kconfig files, or code comments. - Purely decorative changes, such as logging (e.g., pr_err, printk) or tracepoints. - Changes to numeric constants or macros that do not functionally alter execution flow. - Code paths that are impossible to reach in virtualized environments like GCE or QEMU, even when utilizing software-emulated hardware (e.g., usb gadget, mac80211_hwsim). - Code in vendor-specific PCIe switch, SmartNIC, or GPU drivers (e.g., mlxsw, pds_core, qed, ionic, amdgpu) that require physical PCIe hardware cards not emulated in standard QEMU. - Driver .remove, .shutdown, or pci_unregister_driver teardown callbacks (e.g., igb_remove) that are executed only during PCI hot-unplug or sysfs driver unbind operations. If it modifies reachable core kernel logic, drivers, or architectures, use your code search tools to verify the code can be executed, then return WorthFuzzing=true. When returning WorthFuzzing=true, you MUST ALSO: 1. Extract any specific kernel functions that should be heavily fuzzed into FocusSymbols. Avoid listing generic hot-path functions to prevent skewed test distributions. Prefer non-static, non-inlined API entrypoint functions over internal static helper functions (which are inlined by the compiler and do not have distinct symbol addresses). 2. Identify any specific CONFIG_ options required to properly test this new/modified feature. Go and look into the Kconfig files and check for ifdefs around the code, do not make assumptions. Also check "depends on" lines in Kconfig to include any non-standard parent subsystem configs needed for Kbuild to compile the code statically into vmlinux. List them in the EnableConfigs output array, and DO NOT add a '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: For your convenience, here is the diff of the changes:
commit 8ed3d89b558a621e9e57bc0870835747f12d30e5
Author: syz-cluster <triage@syzkaller.com>
Date: Sat Jul 25 20:28:19 2026 +0000
syz-cluster: applied patch under review
diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c
index e75d2932475ac0..5ae0511e89e32c 100644
--- a/net/packet/af_packet.c
+++ b/net/packet/af_packet.c
@@ -1924,11 +1924,12 @@ static void packet_parse_headers(struct sk_buff *skb, struct socket *sock)
{
int depth;
+ /* On TX skb->data is the L2 header; anchor it for all socket types. */
+ skb_reset_mac_header(skb);
+
if ((!skb->protocol || skb->protocol == htons(ETH_P_ALL)) &&
- sock->type == SOCK_RAW) {
- skb_reset_mac_header(skb);
+ sock->type == SOCK_RAW)
skb->protocol = dev_parse_header_protocol(skb);
- }
/* Move network header to the right position for VLAN tagged packets */
if (likely(skb->dev->type == ARPHRD_ETHER) &&
|
| 3/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 2148 output: 34 thoughts: 86 Thoughts: **Analyzing the AF_PACKET Patch** Okay, so I'm looking at this patch that's touched `net/packet/af_packet.c`. Specifically, it seems to have moved the `skb_reset_mac_header(skb);` call out of that `if` block within `packet_parse_headers`. Right away, I recognize this as a functional change, a modification to how the packet socket transmission path behaves. My immediate instinct is to dive into `packet_parse_headers` in `net/packet/af_packet.c` and understand the implications of this change. I need to pinpoint the exact control flow paths affected and assess the impact on the packet header parsing and, subsequently, the SKB's MAC header setup. This is going to be about tracing the logic and understanding the rationale for moving that function call – likely a subtle but potentially significant performance or correctness adjustment. I want to see *why* this was done and confirm there are no unintended side effects. |
| 4/2 | 2026/07/25 20:28 | tool | grepper |
0mArgs:{
"Expression": "packet_parse_headers",
"PathPrefix": "net/packet/af_packet.c"
}Results: {
"Output": "net/packet/af_packet.c=1857=static int packet_rcv_spkt(struct sk_buff *skb, struct net_device *dev,\n--\nnet/packet/af_packet.c-1922-\nnet/packet/af_packet.c:1923:static void packet_parse_headers(struct sk_buff *skb, struct socket *sock)\nnet/packet/af_packet.c-1924-{\n--\nnet/packet/af_packet.c=1948=static int packet_sendmsg_spkt(struct socket *sock, struct msghdr *msg,\n--\nnet/packet/af_packet.c-2060-\nnet/packet/af_packet.c:2061:\tpacket_parse_headers(skb, sock);\nnet/packet/af_packet.c-2062-\n--\nnet/packet/af_packet.c=2570=static int tpacket_fill_skb(struct packet_sock *po, struct sk_buff *skb,\n--\nnet/packet/af_packet.c-2644-\nnet/packet/af_packet.c:2645:\tpacket_parse_headers(skb, sock);\nnet/packet/af_packet.c-2646-\n--\nnet/packet/af_packet.c=2946=static int packet_snd(struct socket *sock, struct msghdr *msg, size_t len)\n--\nnet/packet/af_packet.c-3072-\nnet/packet/af_packet.c:3073:\tpacket_parse_headers(skb, sock);\nnet/packet/af_packet.c-3074-\n"
} |
| 5/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 2913 output: 30 thoughts: 73 Thoughts: **Analyzing the Impact of `packet_parse_headers`** Okay, so `packet_parse_headers` is clearly a key function. It's called from `packet_sendmsg_spkt`, `tpacket_fill_skb`, and `packet_snd`. Hmm, those all sound like different ways to send packets via packet sockets – essentially, the send paths. This makes it a high-priority area to understand. The change I'm looking at *is* definitely reachable, which is good. Now, I need to dig into the configuration. I should check the config for `net/packet/af_packet.c` to see how these different paths are set up and how `packet_parse_headers` fits into the broader picture of the packet socket implementation. Time to get the details. |
| 6/2 | 2026/07/25 20:28 | tool | grepper |
0mArgs:{
"Expression": "af_packet\\.o",
"PathPrefix": "net/packet/Makefile"
}Results: {
"Output": "net/packet/Makefile-5-\nnet/packet/Makefile:6:obj-$(CONFIG_PACKET) += af_packet.o\nnet/packet/Makefile-7-obj-$(CONFIG_PACKET_DIAG) += af_packet_diag.o\n"
} |
| 7/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 3259 output: 36 thoughts: 156 Thoughts: **Analyzing the Network Packet Configuration** Okay, so I'm digging into this `CONFIG_PACKET` configuration. I need to understand the data flow, the key functions that are involved. My initial targets, the symbols I should be focusing on, are `packet_sendmsg_spkt`, `tpacket_fill_skb`, `packet_snd`, and then, in theory, `packet_parse_headers`. Hmm, wait a second. I remember now, `packet_parse_headers` is static, which means I can't directly target it. It's only callable within the file it's defined. That's fine, the *callers* of `packet_parse_headers` are what I'm interested in! So, the callers are... `packet_sendmsg_spkt`, `tpacket_fill_skb`, and `packet_snd`. Hold on, `tpacket_fill_skb` is also static! Which means I need to dig even deeper, and find out *who* calls *that* one. Ah, okay, `tpacket_snd` calls it. Got it. Right, so now the strategy is clear. I need to take a close look at `tpacket_snd`, `packet_snd`, and `packet_sendmsg_spkt` and see how they work. That should give me the big picture. |
| 8/2 | 2026/07/25 20:28 | tool | grepper |
0mArgs:{
"Expression": "tpacket_fill_skb",
"PathPrefix": "net/packet/af_packet.c"
}Results: {
"Output": "net/packet/af_packet.c=2547=static int packet_snd_vnet_parse(struct msghdr *msg, size_t *len,\n--\nnet/packet/af_packet.c-2569-\nnet/packet/af_packet.c:2570:static int tpacket_fill_skb(struct packet_sock *po, struct sk_buff *skb,\nnet/packet/af_packet.c-2571-\t\tvoid *frame, struct net_device *dev, void *data, int tp_len,\n--\nnet/packet/af_packet.c=2718=static int tpacket_snd(struct packet_sock *po, struct msghdr *msg)\n--\nnet/packet/af_packet.c-2850-\t\t}\nnet/packet/af_packet.c:2851:\t\ttp_len = tpacket_fill_skb(po, skb, ph, dev, data, tp_len, proto,\nnet/packet/af_packet.c-2852-\t\t\t\t\t addr, hlen, copylen, \u0026sockc);\n"
} |
| 9/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 4029 output: 36 thoughts: 45 Thoughts: Okay, here's my take on those thoughts, tailored for an expert audience: **Analyzing Packet Transmission Symbols** Alright, I'm zeroing in on the kernel symbols related to packet transmission: `packet_sendmsg_spkt`, `tpacket_snd`, and `packet_snd`. My initial thought is to quickly verify the nature of `packet_sendmsg_spkt`. Hold on, a static function, I'd better confirm that. It looks like `packet_sendmsg_spkt` is going to be something very specific that gets resolved at compile time, something that may be highly relevant to low-level packet processing efficiency, or perhaps related to the specifics of the networking stack being used. I need to dig deeper and confirm that static qualifier and then consider the implications if it is indeed static. |
| 10/2 | 2026/07/25 20:28 | tool | grepper |
0mArgs:{
"Expression": "packet_sendmsg_spkt",
"PathPrefix": "net/packet/af_packet.c"
}Results: {
"Output": "net/packet/af_packet.c=1923=static void packet_parse_headers(struct sk_buff *skb, struct socket *sock)\n--\nnet/packet/af_packet.c-1947-\nnet/packet/af_packet.c:1948:static int packet_sendmsg_spkt(struct socket *sock, struct msghdr *msg,\nnet/packet/af_packet.c-1949-\t\t\t size_t len)\n--\nnet/packet/af_packet.c=4650=static const struct proto_ops packet_ops_spkt = {\n--\nnet/packet/af_packet.c-4663-\t.shutdown =\tsock_no_shutdown,\nnet/packet/af_packet.c:4664:\t.sendmsg =\tpacket_sendmsg_spkt,\nnet/packet/af_packet.c-4665-\t.recvmsg =\tpacket_recvmsg,\n"
} |
| 11/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 4527 output: 32 thoughts: 31 Thoughts: Okay, here's my interpretation of those thoughts, presented as a personal thought process, as requested: **Digging into the `packet_sendmsg_spkt` Function** Hmm, so `packet_sendmsg_spkt` is static, which is interesting in itself. But it's also declared as a `proto_ops` callback. That makes me think about scope and potential concurrency issues right away. A static function, particularly in a callback situation like this, suggests it's likely scoped to a specific module or compilation unit, which offers certain advantages. But is `packet_snd` static too? The linkage of that function is relevant in determining the constraints on how `packet_sendmsg_spkt` interacts with the rest of the system. I need to understand that relationship to truly grasp the implications of these design decisions. The implications of this are significant. |
| 12/2 | 2026/07/25 20:28 | tool | grepper |
0mArgs:{
"Expression": "packet_snd",
"PathPrefix": "net/packet/af_packet.c"
}Results: {
"Output": "net/packet/af_packet.c=2511=static void tpacket_destruct_skb(struct sk_buff *skb)\n--\nnet/packet/af_packet.c-2530-\nnet/packet/af_packet.c:2531:static int __packet_snd_vnet_parse(struct virtio_net_hdr *vnet_hdr, size_t len)\nnet/packet/af_packet.c-2532-{\n--\nnet/packet/af_packet.c-2546-\nnet/packet/af_packet.c:2547:static int packet_snd_vnet_parse(struct msghdr *msg, size_t *len,\nnet/packet/af_packet.c-2548-\t\t\t\t struct virtio_net_hdr *vnet_hdr, int vnet_hdr_sz)\n--\nnet/packet/af_packet.c-2558-\nnet/packet/af_packet.c:2559:\tret = __packet_snd_vnet_parse(vnet_hdr, *len);\nnet/packet/af_packet.c-2560-\tif (ret)\n--\nnet/packet/af_packet.c=2650=static int tpacket_parse_header(struct packet_sock *po, void *frame,\n--\nnet/packet/af_packet.c-2717-\nnet/packet/af_packet.c:2718:static int tpacket_snd(struct packet_sock *po, struct msghdr *msg)\nnet/packet/af_packet.c-2719-{\n--\nnet/packet/af_packet.c-2830-\t\t\tmemcpy(\u0026vnet_hdr, data - vnet_hdr_sz, sizeof(vnet_hdr));\nnet/packet/af_packet.c:2831:\t\t\tif (__packet_snd_vnet_parse(\u0026vnet_hdr, tp_len)) {\nnet/packet/af_packet.c-2832-\t\t\t\ttp_len = -EINVAL;\n--\nnet/packet/af_packet.c=2920=static struct sk_buff *packet_alloc_skb(struct sock *sk, size_t prepad,\n--\nnet/packet/af_packet.c-2945-\nnet/packet/af_packet.c:2946:static int packet_snd(struct socket *sock, struct msghdr *msg, size_t len)\nnet/packet/af_packet.c-2947-{\n--\nnet/packet/af_packet.c-3002-\tif (vnet_hdr_sz) {\nnet/packet/af_packet.c:3003:\t\terr = packet_snd_vnet_parse(msg, \u0026len, \u0026vnet_hdr, vnet_hdr_sz);\nnet/packet/af_packet.c-3004-\t\tif (err)\n--\nnet/packet/af_packet.c=3104=static int packet_sendmsg(struct socket *sock, struct msghdr *msg, size_t len)\n--\nnet/packet/af_packet.c-3109-\t/* Reading tx_ring.pg_vec without holding pg_vec_lock is racy.\nnet/packet/af_packet.c:3110:\t * tpacket_snd() will redo the check safely.\nnet/packet/af_packet.c-3111-\t */\nnet/packet/af_packet.c-3112-\tif (data_race(po-\u003etx_ring.pg_vec))\nnet/packet/af_packet.c:3113:\t\treturn tpacket_snd(po, msg);\nnet/packet/af_packet.c-3114-\nnet/packet/af_packet.c:3115:\treturn packet_snd(sock, msg, len);\nnet/packet/af_packet.c-3116-}\n"
} |
| 13/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 5745 output: 33 thoughts: 34 Thoughts: **Analyzing the Network Packet Transmission Entry Point** Okay, so `packet_sendmsg` – that's the key here, it's the non-static entry point, or maybe it's just aliased to `sendmsg` statically. I need to clarify that. Right now, I should delve into `packet_sendmsg`. It's where the packet transmission process actually starts. I need to understand what's happening at that point and how things flow from there. Let's dig in. |
| 14/2 | 2026/07/25 20:28 | tool | grepper |
0mArgs:{
"Expression": "packet_sendmsg",
"PathPrefix": "net/packet/af_packet.c"
}Results: {
"Output": "net/packet/af_packet.c=1923=static void packet_parse_headers(struct sk_buff *skb, struct socket *sock)\n--\nnet/packet/af_packet.c-1947-\nnet/packet/af_packet.c:1948:static int packet_sendmsg_spkt(struct socket *sock, struct msghdr *msg,\nnet/packet/af_packet.c-1949-\t\t\t size_t len)\n--\nnet/packet/af_packet.c=2718=static int tpacket_snd(struct packet_sock *po, struct msghdr *msg)\n--\nnet/packet/af_packet.c-2740-\nnet/packet/af_packet.c:2741:\t/* packet_sendmsg() check on tx_ring.pg_vec was lockless,\nnet/packet/af_packet.c-2742-\t * we need to confirm it under protection of pg_vec_lock.\n--\nnet/packet/af_packet.c=2946=static int packet_snd(struct socket *sock, struct msghdr *msg, size_t len)\n--\nnet/packet/af_packet.c-3103-\nnet/packet/af_packet.c:3104:static int packet_sendmsg(struct socket *sock, struct msghdr *msg, size_t len)\nnet/packet/af_packet.c-3105-{\n--\nnet/packet/af_packet.c=4650=static const struct proto_ops packet_ops_spkt = {\n--\nnet/packet/af_packet.c-4663-\t.shutdown =\tsock_no_shutdown,\nnet/packet/af_packet.c:4664:\t.sendmsg =\tpacket_sendmsg_spkt,\nnet/packet/af_packet.c-4665-\t.recvmsg =\tpacket_recvmsg,\n--\nnet/packet/af_packet.c=4669=static const struct proto_ops packet_ops = {\n--\nnet/packet/af_packet.c-4684-\t.getsockopt_iter =\tpacket_getsockopt,\nnet/packet/af_packet.c:4685:\t.sendmsg =\tpacket_sendmsg,\nnet/packet/af_packet.c-4686-\t.recvmsg =\tpacket_recvmsg,\n"
} |
| 15/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 6521 output: 43 thoughts: 117 Thoughts: **Examining the AF_PACKET Send Path** Okay, so I'm looking at how `sendmsg` works for `AF_PACKET` sockets. I see `packet_sendmsg` and `packet_sendmsg_spkt` as the callback functions used for the `sendmsg` operation. The important thing to note is that these are *static* functions, which means they are the actual entry points, but they are localized. The immediate thought is, can I leverage any other *non-static* functions within that family? Are there perhaps any intermediary functions that are exposed more widely? If not, then I'll simply have to work directly with these static functions. Hang on… just a quick confirmation, `packet_sendmsg` is *indeed* static. Okay, no confusion there. Alright, the most logical next step is to carefully check the `net/packet/af_packet.c` file to ensure I haven't missed a more appropriate non-static option. I'll scan through it and see if anything jumps out. |
| 16/2 | 2026/07/25 20:28 | tool | grepper |
0mError:no matches Args: {
"Expression": "^int [a-zA-Z0-9_]+\\(",
"PathPrefix": "net/packet/af_packet.c"
}Results: {
"error": "no matches"
} |
| 17/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 6919 output: 43 thoughts: 19 Thoughts: Okay, here's my interpretation of that thought process, tailored for an expert audience: **Pattern Recognition in Code Snippets** Alright, I see a pattern emerging. The hint given is `^void [a-zA-Z0-9_]+\(`. Immediately, my mind is drawn to the implications. The `^` anchors the start of the match. That's good. `void` is a clear type declaration. From a language perspective, it signals a function that doesn't return a value. The subsequent space reinforces the type-function separation which makes me think of C, C++, or similar languages. Then we have `[a-zA-Z0-9_]+`. This is where it gets interesting. I see a character class representing alphanumeric characters and underscores, repeated one or more times, which directly signifies a function name or an identifier under established naming rules. Finally, the `\(` indicates an open parenthesis, which immediately suggests a function definition or declaration. It's the standard way in C-like languages. Therefore, my immediate thought is that this is likely a regular expression pattern designed to identify function signatures within source code, specifically those with a `void` return type and a standard alphanumeric function name. It's a rather specific and common pattern. This hints at a parsing or code analysis task, maybe identifying functions for static analysis, refactoring, or code generation. It will capture the name and the beginning of the function declaration for further processing. I would need more context to understand the exact goal of the pattern matching, but this initial breakdown is a sound starting point. |
| 18/2 | 2026/07/25 20:28 | tool | grepper |
0mError:no matches Args: {
"Expression": "^void [a-zA-Z0-9_]+\\(",
"PathPrefix": "net/packet/af_packet.c"
}Results: {
"error": "no matches"
} |
| 19/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 7329 output: 44 thoughts: 20 Thoughts: Okay, here's my interpretation of that thought process, assuming I'm an expert in this field, expressed in the first person: **Analyzing that Regular Expression Snippet** Alright, I'm looking at this expression, `^static int [a-zA-Z0-9_]+\(`, and my brain is instantly parsing it. The `^` at the beginning tells me this is meant to match from the start of a line or string. That's good, sets a clear anchor. Then, I see `static int`. This strongly suggests we're hunting for function declarations, specifically ones that are `static` and return an `int`. Okay, classic C/C++ or similar language, probably. The ` ` (space) is important in such cases, because it denotes the separating of the "static int" from the name of the variable. The meat of it is the next part: `[a-zA-Z0-9_]+\(`. Here, `[a-zA-Z0-9_]+` is the key. That's a character class matching one or more alphanumeric characters and underscores. That's *exactly* what a valid function name in most C-like languages is. It's expecting a function identifier, basically. And the `\` before the `(` is interesting, as it is a way to escape special characters, in the case of parenthesis. Lastly, the `\(`, well, that's the tell. That open parenthesis is essential: it indicates the beginning of a function's parameter list. So, all together, this looks like a regex designed to identify function signatures in code, or at least a portion of them. Perhaps a quick way to find function declarations in a code file? Or a very specific function naming convention check? |
| 20/2 | 2026/07/25 20:28 | tool | grepper |
0mArgs:{
"Expression": "^static int [a-zA-Z0-9_]+\\(",
"PathPrefix": "net/packet/af_packet.c"
}Results: {
"Output": "net/packet/af_packet.c=167=union tpacket_uhdr {\n--\nnet/packet/af_packet.c-173-\nnet/packet/af_packet.c:174:static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u,\nnet/packet/af_packet.c-175-\t\tint closing, int tx_ring);\n--\nnet/packet/af_packet.c=191=struct packet_sock;\nnet/packet/af_packet.c:192:static int tpacket_rcv(struct sk_buff *skb, struct net_device *dev,\nnet/packet/af_packet.c-193-\t\t struct packet_type *pt, struct net_device *orig_dev);\n--\nnet/packet/af_packet.c=198=static void packet_increment_head(struct packet_ring_buffer *buff);\nnet/packet/af_packet.c:199:static int prb_curr_blk_in_use(struct tpacket_block_desc *);\nnet/packet/af_packet.c-200-static void *prb_dispatch_next_block(struct tpacket_kbdq_core *,\n--\nnet/packet/af_packet.c=202=static void prb_retire_current_block(struct tpacket_kbdq_core *,\nnet/packet/af_packet.c-203-\t\tstruct packet_sock *, unsigned int status);\nnet/packet/af_packet.c:204:static int prb_queue_frozen(struct tpacket_kbdq_core *);\nnet/packet/af_packet.c-205-static void prb_open_block(struct tpacket_kbdq_core *,\n--\nnet/packet/af_packet.c=247=static noinline struct sk_buff *nf_hook_direct_egress(struct sk_buff *skb)\n--\nnet/packet/af_packet.c-272-\nnet/packet/af_packet.c:273:static int packet_xmit(const struct packet_sock *po, struct sk_buff *skb)\nnet/packet/af_packet.c-274-{\n--\nnet/packet/af_packet.c=400=static void __packet_set_status(struct packet_sock *po, void *frame, int status)\n--\nnet/packet/af_packet.c-427-\nnet/packet/af_packet.c:428:static int __packet_get_status(const struct packet_sock *po, void *frame)\nnet/packet/af_packet.c-429-{\n--\nnet/packet/af_packet.c=583=static void prb_shutdown_retire_blk_timer(struct packet_sock *po,\n--\nnet/packet/af_packet.c-591-\nnet/packet/af_packet.c:592:static int prb_calc_retire_blk_tmo(struct packet_sock *po,\nnet/packet/af_packet.c-593-\t\t\t\tint blk_size_in_bytes)\n--\nnet/packet/af_packet.c=940=static void prb_retire_current_block(struct tpacket_kbdq_core *pkc,\n--\nnet/packet/af_packet.c-965-\nnet/packet/af_packet.c:966:static int prb_curr_blk_in_use(struct tpacket_block_desc *pbd)\nnet/packet/af_packet.c-967-{\n--\nnet/packet/af_packet.c-970-\nnet/packet/af_packet.c:971:static int prb_queue_frozen(struct tpacket_kbdq_core *pkc)\nnet/packet/af_packet.c-972-{\n--\nnet/packet/af_packet.c=1128=static void *prb_lookup_block(const struct packet_sock *po,\n--\nnet/packet/af_packet.c-1140-\nnet/packet/af_packet.c:1141:static int prb_previous_blk_num(struct packet_ring_buffer *rb)\nnet/packet/af_packet.c-1142-{\n--\nnet/packet/af_packet.c=1208=static unsigned int packet_read_pending(const struct packet_ring_buffer *rb)\n--\nnet/packet/af_packet.c-1222-\nnet/packet/af_packet.c:1223:static int packet_alloc_pending(struct packet_sock *po)\nnet/packet/af_packet.c-1224-{\n--\nnet/packet/af_packet.c=1257=static bool __tpacket_v3_has_room(const struct packet_sock *po, int pow_off)\n--\nnet/packet/af_packet.c-1269-\nnet/packet/af_packet.c:1270:static int __packet_rcv_has_room(const struct packet_sock *po,\nnet/packet/af_packet.c-1271-\t\t\t\t const struct sk_buff *skb)\n--\nnet/packet/af_packet.c-1303-\nnet/packet/af_packet.c:1304:static int packet_rcv_has_room(struct packet_sock *po, struct sk_buff *skb)\nnet/packet/af_packet.c-1305-{\n--\nnet/packet/af_packet.c=1451=static bool fanout_has_flag(struct packet_fanout *f, u16 flag)\n--\nnet/packet/af_packet.c-1455-\nnet/packet/af_packet.c:1456:static int packet_rcv_fanout(struct sk_buff *skb, struct net_device *dev,\nnet/packet/af_packet.c-1457-\t\t\t struct packet_type *pt, struct net_device *orig_dev)\n--\nnet/packet/af_packet.c=1568=static void __fanout_set_data_bpf(struct packet_fanout *f, struct bpf_prog *new)\n--\nnet/packet/af_packet.c-1582-\nnet/packet/af_packet.c:1583:static int fanout_set_data_cbpf(struct packet_sock *po, sockptr_t data,\nnet/packet/af_packet.c-1584-\t\t\t\tunsigned int len)\n--\nnet/packet/af_packet.c-1604-\nnet/packet/af_packet.c:1605:static int fanout_set_data_ebpf(struct packet_sock *po, sockptr_t data,\nnet/packet/af_packet.c-1606-\t\t\t\tunsigned int len)\n--\nnet/packet/af_packet.c-1625-\nnet/packet/af_packet.c:1626:static int fanout_set_data(struct packet_sock *po, sockptr_t data,\nnet/packet/af_packet.c-1627-\t\t\t unsigned int len)\n--\nnet/packet/af_packet.c=1661=static bool fanout_find_new_id(struct sock *sk, u16 *new_id)\n--\nnet/packet/af_packet.c-1677-\nnet/packet/af_packet.c:1678:static int fanout_add(struct sock *sk, struct fanout_args *args)\nnet/packet/af_packet.c-1679-{\n--\nnet/packet/af_packet.c=1855=static const struct proto_ops packet_ops_spkt;\nnet/packet/af_packet.c-1856-\nnet/packet/af_packet.c:1857:static int packet_rcv_spkt(struct sk_buff *skb, struct net_device *dev,\nnet/packet/af_packet.c-1858-\t\t\t struct packet_type *pt, struct net_device *orig_dev)\n--\nnet/packet/af_packet.c=1923=static void packet_parse_headers(struct sk_buff *skb, struct socket *sock)\n--\nnet/packet/af_packet.c-1947-\nnet/packet/af_packet.c:1948:static int packet_sendmsg_spkt(struct socket *sock, struct msghdr *msg,\nnet/packet/af_packet.c-1949-\t\t\t size_t len)\n--\nnet/packet/af_packet.c=2074=static unsigned int run_filter(struct sk_buff *skb,\n--\nnet/packet/af_packet.c-2088-\nnet/packet/af_packet.c:2089:static int packet_rcv_vnet(struct msghdr *msg, const struct sk_buff *skb,\nnet/packet/af_packet.c-2090-\t\t\t size_t *len, int vnet_hdr_sz)\n--\nnet/packet/af_packet.c-2115-\nnet/packet/af_packet.c:2116:static int packet_rcv(struct sk_buff *skb, struct net_device *dev,\nnet/packet/af_packet.c-2117-\t\t struct packet_type *pt, struct net_device *orig_dev)\n--\nnet/packet/af_packet.c-2228-\nnet/packet/af_packet.c:2229:static int tpacket_rcv(struct sk_buff *skb, struct net_device *dev,\nnet/packet/af_packet.c-2230-\t\t struct packet_type *pt, struct net_device *orig_dev)\n--\nnet/packet/af_packet.c=2511=static void tpacket_destruct_skb(struct sk_buff *skb)\n--\nnet/packet/af_packet.c-2530-\nnet/packet/af_packet.c:2531:static int __packet_snd_vnet_parse(struct virtio_net_hdr *vnet_hdr, size_t len)\nnet/packet/af_packet.c-2532-{\n--\nnet/packet/af_packet.c-2546-\nnet/packet/af_packet.c:2547:static int packet_snd_vnet_parse(struct msghdr *msg, size_t *len,\nnet/packet/af_packet.c-2548-\t\t\t\t struct virtio_net_hdr *vnet_hdr, int vnet_hdr_sz)\n--\nnet/packet/af_packet.c-2569-\nnet/packet/af_packet.c:2570:static int tpacket_fill_skb(struct packet_sock *po, struct sk_buff *skb,\nnet/packet/af_packet.c-2571-\t\tvoid *frame, struct net_device *dev, void *data, int tp_len,\n--\nnet/packet/af_packet.c-2649-\nnet/packet/af_packet.c:2650:static int tpacket_parse_header(struct packet_sock *po, void *frame,\nnet/packet/af_packet.c-2651-\t\t\t\tint size_max, void **data)\n--\nnet/packet/af_packet.c-2717-\nnet/packet/af_packet.c:2718:static int tpacket_snd(struct packet_sock *po, struct msghdr *msg)\nnet/packet/af_packet.c-2719-{\n--\nnet/packet/af_packet.c=2920=static struct sk_buff *packet_alloc_skb(struct sock *sk, size_t prepad,\n--\nnet/packet/af_packet.c-2945-\nnet/packet/af_packet.c:2946:static int packet_snd(struct socket *sock, struct msghdr *msg, size_t len)\nnet/packet/af_packet.c-2947-{\n--\nnet/packet/af_packet.c-3103-\nnet/packet/af_packet.c:3104:static int packet_sendmsg(struct socket *sock, struct msghdr *msg, size_t len)\nnet/packet/af_packet.c-3105-{\n--\nnet/packet/af_packet.c-3122-\nnet/packet/af_packet.c:3123:static int packet_release(struct socket *sock)\nnet/packet/af_packet.c-3124-{\n--\nnet/packet/af_packet.c-3195-\nnet/packet/af_packet.c:3196:static int packet_do_bind(struct sock *sk, const char *name, int ifindex,\nnet/packet/af_packet.c-3197-\t\t\t __be16 proto)\n--\nnet/packet/af_packet.c-3289-\nnet/packet/af_packet.c:3290:static int packet_bind_spkt(struct socket *sock, struct sockaddr_unsized *uaddr,\nnet/packet/af_packet.c-3291-\t\t\t int addr_len)\n--\nnet/packet/af_packet.c-3311-\nnet/packet/af_packet.c:3312:static int packet_bind(struct socket *sock, struct sockaddr_unsized *uaddr, int addr_len)\nnet/packet/af_packet.c-3313-{\n--\nnet/packet/af_packet.c=3329=static struct proto packet_proto = {\n--\nnet/packet/af_packet.c-3338-\nnet/packet/af_packet.c:3339:static int packet_create(struct net *net, struct socket *sock, int protocol,\nnet/packet/af_packet.c-3340-\t\t\t int kern)\n--\nnet/packet/af_packet.c-3416-\nnet/packet/af_packet.c:3417:static int packet_recvmsg(struct socket *sock, struct msghdr *msg, size_t len,\nnet/packet/af_packet.c-3418-\t\t\t int flags)\n--\nnet/packet/af_packet.c-3581-\nnet/packet/af_packet.c:3582:static int packet_getname_spkt(struct socket *sock, struct sockaddr *uaddr,\nnet/packet/af_packet.c-3583-\t\t\t int peer)\n--\nnet/packet/af_packet.c-3601-\nnet/packet/af_packet.c:3602:static int packet_getname(struct socket *sock, struct sockaddr *uaddr,\nnet/packet/af_packet.c-3603-\t\t\t int peer)\n--\nnet/packet/af_packet.c-3638-\nnet/packet/af_packet.c:3639:static int packet_dev_mc(struct net_device *dev, struct packet_mclist *i,\nnet/packet/af_packet.c-3640-\t\t\t int what)\n--\nnet/packet/af_packet.c=3669=static void packet_dev_mclist_delete(struct net_device *dev,\n--\nnet/packet/af_packet.c-3683-\nnet/packet/af_packet.c:3684:static int packet_mc_add(struct sock *sk, struct packet_mreq_max *mreq)\nnet/packet/af_packet.c-3685-{\n--\nnet/packet/af_packet.c-3739-\nnet/packet/af_packet.c:3740:static int packet_mc_drop(struct sock *sk, struct packet_mreq_max *mreq)\nnet/packet/af_packet.c-3741-{\n--\nnet/packet/af_packet.c=3788=packet_setsockopt(struct socket *sock, int level, int optname, sockptr_t optval,\n--\nnet/packet/af_packet.c-4059-\nnet/packet/af_packet.c:4060:static int packet_getsockopt(struct socket *sock, int level, int optname,\nnet/packet/af_packet.c-4061-\t\t\t sockopt_t *opt)\n--\nnet/packet/af_packet.c-4185-\nnet/packet/af_packet.c:4186:static int packet_notifier(struct notifier_block *this,\nnet/packet/af_packet.c-4187-\t\t\t unsigned long msg, void *ptr)\n--\nnet/packet/af_packet.c-4246-\nnet/packet/af_packet.c:4247:static int packet_ioctl(struct socket *sock, unsigned int cmd,\nnet/packet/af_packet.c-4248-\t\t\tunsigned long arg)\n--\nnet/packet/af_packet.c=4392=static struct pgv *alloc_pg_vec(struct tpacket_req *req, int order)\n--\nnet/packet/af_packet.c-4416-\nnet/packet/af_packet.c:4417:static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u,\nnet/packet/af_packet.c-4418-\t\tint closing, int tx_ring)\n--\nnet/packet/af_packet.c-4587-\nnet/packet/af_packet.c:4588:static int packet_mmap(struct file *file, struct socket *sock,\nnet/packet/af_packet.c-4589-\t\tstruct vm_area_struct *vma)\n--\nnet/packet/af_packet.c=4717=static void packet_seq_stop(struct seq_file *seq, void *v)\n--\nnet/packet/af_packet.c-4722-\nnet/packet/af_packet.c:4723:static int packet_seq_show(struct seq_file *seq, void *v)\nnet/packet/af_packet.c-4724-{\n"
} |
| 21/2 | 2026/07/25 20:28 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 12321 output: 139 thoughts: 825 Thoughts: **Reasoning for Fuzzing Strategy** Okay, let's break this down. My goal is to determine the optimal fuzzing strategy for this patch, and I need to be precise. The patch modifies `packet_parse_headers` within `net/packet/af_packet.c`. This function is invoked during packet transmission on `AF_PACKET` sockets, specifically altering the behavior of how the MAC header is handled. The core change involves unconditionally resetting the MAC header using `skb_reset_mac_header(skb)`, which previously depended on a conditional check. This is a functional change deep within the packet transmission path, meaning it's prime fuzzing territory. My initial thought was to focus on `packet_sendmsg` and `packet_sendmsg_spkt` as the key entry points. But I had to confirm: are static functions like these viable focus symbols, considering they might be inlined? Syzkaller *can* handle static functions if they *aren't* inlined. Looking at the code, both `packet_sendmsg` and `packet_sendmsg_spkt` are assigned to `proto_ops` structs. Their addresses are taken, which means the compiler *won't* inline them. Perfect, they fit the criteria. The prompt, however, requires me to also identify the configuration options. The prompt also notes to omit "CONFIG_" prefix. So it looks like `CONFIG_PACKET` is what I'm after, and therefore, I should use `PACKET` as the relevant configuration. I've double-checked, and `CONFIG_PACKET` is the only relevant config here. I then did a quick audit to confirm that these two entrypoints cover all potential call paths. `packet_parse_headers` is called by `packet_sendmsg_spkt`, `tpacket_fill_skb`, and `packet_snd`. `tpacket_fill_skb` is called by `tpacket_snd`, and `packet_snd` is called by `packet_sendmsg`. Importantly, both `tpacket_snd` and `packet_sendmsg_spkt` are also called by `packet_sendmsg`. So, `packet_sendmsg` and `packet_sendmsg_spkt` do, indeed, cover the complete relevant execution flow. They're the `sendmsg` callbacks for the `AF_PACKET` protocol operations. So, I'm confident in my strategy: * **Focus Symbols:** `packet_sendmsg`, `packet_sendmsg_spkt` * **Enable Configs:** `PACKET` The patch itself is a functional change, so fuzzing these entrypoints will effectively exercise the modified code. Now, I'm ready to call `set-results`. |
| 22/2 | 2026/07/25 20:29 | tool | set-results |
0mArgs:{
"EnableConfigs": [
"PACKET"
],
"FocusSymbols": [
"packet_sendmsg",
"packet_sendmsg_spkt"
],
"Reasoning": "The patch modifies `packet_parse_headers` in `net/packet/af_packet.c`, which is called during packet transmission on AF_PACKET sockets. It moves `skb_reset_mac_header(skb)` out of an if-condition, ensuring the MAC header is always reset for all socket types. This is a functional change in the core networking packet transmission path and should be fuzzed.",
"WorthFuzzing": true
}Results: {
"EnableConfigs": [
"PACKET"
],
"FocusSymbols": [
"packet_sendmsg",
"packet_sendmsg_spkt"
],
"Reasoning": "The patch modifies `packet_parse_headers` in `net/packet/af_packet.c`, which is called during packet transmission on AF_PACKET sockets. It moves `skb_reset_mac_header(skb)` out of an if-condition, ensuring the MAC header is always reset for all socket types. This is a functional change in the core networking packet transmission path and should be fuzzed.",
"WorthFuzzing": true
} |
| Total Calls | Total Tokens | Avg Tokens | Total Duration (Seconds) | Avg Duration (Seconds) |
|---|
| Total Calls | Total Duration (Seconds) | Avg Duration (Seconds) |
|---|