Hi Tetsuo,
On Wed, Jan 14, 2026 at 10:43 AM Tetsuo Handa
<
penguin...@i-love.sakura.ne.jp> wrote:
>
> Hello.
>
> I found that syz-prog2c ignores "-enable net_dev" option when "-enable net_reset"
> option is also specified.
>
> The syz reproducers include a comment line like
>
> #{"threaded":true,"repeat":true,"procs":5,"slowdown":1,"sandbox":"none","sandbox_arg":0,"tun":true,"netdev":true,"resetnet":true,"cgroups":true,"binfmt_misc":true,"close_fds":true,"usb":true,"vhci":true,"wifi":true,"ieee802154":true,"sysctl":true,"swap":true,"tmpdir":true,"segv":true,"callcomments":true}
>
> but this comment line is confusing.
>
> Are "netdev":true and "resetnet":true exclusive?
> What is "-enable net_reset" option for?
>
> $ ~/syzkaller/bin/syz-prog2c -sandbox none -enable net_dev -repeat 0 -enable net_reset -prog /dev/null | grep initialize_netdevices
Note that it should have been "-enable net_dev,net_reset". Then it works.
> $ ~/syzkaller/bin/syz-prog2c -sandbox none -enable net_dev -repeat 0 -prog /dev/null | grep initialize_netdevices
> static void initialize_netdevices(void)
> static void initialize_netdevices_init(void)
> initialize_netdevices_init();
> initialize_netdevices();
>
> Also, it would be nice if syz-prog2c accepts specifying arguments in JSON format, for the mapping between
> JSON parameters within syz reproducers and command line argument names for syz-prog2c differs. I had trouble
> with translating the "callcomments":true parameter to corresponding argument name for syz-prog2c program.
>
> $ syz-prog2c -options '{"threaded":true,"repeat":true,"procs":5,"slowdown":1,"sandbox":"none","sandbox_arg":0,"tun":true,"netdev":true,"resetnet":true,"cgroups":true,"binfmt_misc":true,"close_fds":true,"usb":true,"vhci":true,"wifi":true,"ieee802154":true,"sysctl":true,"swap":true,"tmpdir":true,"segv":true,"callcomments":true}' -prog file.syz
>
Yeah, that would have been way more convenient indeed, thanks for
pointing it out. I've filed
https://github.com/google/syzkaller/issues/6602.
--
Aleksandr