Skip to content

Zephyr IP Stack Leaks in Promiscuous Mode #45758

Answered by jukkar
bob2oneil asked this question in General
Discussion options

You must be logged in to vote

Yeah, I was thinking a thread that would set the interface to promiscuous mode and have a while loop like you have above.
After some code digging there seems to be a simpler way. The promiscuous packets are processed in

if (IS_ENABLED(CONFIG_NET_PROMISCUOUS_MODE) &&
and if the interface is set to promiscuous mode but there is no handler i.e., the net_promisc_mode_on() is not called, then the packet should be unreffed properly and no leaks should happen.
So if you want to receive packets in promiscuous mode, but do not want to use the promiscuous mode API, you can enable promiscuous mode in config file, and then call net_i…

Replies: 8 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@bob2oneil
Comment options

@bob2oneil
Comment options

Answer selected by bob2oneil
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
4 participants
Converted from issue

This discussion was converted from issue #45365 on May 18, 2022 09:08.