Skip to content

Conversation

@rlubos
Copy link
Contributor

@rlubos rlubos commented Dec 1, 2025

Verify that the interface is in operational UP state before attempting to send the packet with net_send_data() / net_try_send_data().

So far there's only been an NET_IF_LOWER_UP check in a lower level function, net_if_try_send_data(), however that didn't work well with interface like Wi-Fi, which could have carrier state set to ON, but was still not associated with the network (so the interface was not operational UP). Protocols like ICMP or DHCP, which use net_send_data() directly, should not be able to send packets in such case.

Verify that the interface is in operational UP state before attempting
to send the packet with net_send_data() / net_try_send_data().

So far there's only been an NET_IF_LOWER_UP check in a lower level
function, net_if_try_send_data(), however that didn't work well with
interface like Wi-Fi, whouch could have carrier state set to ON, but
was still not associated with the network (so the interface was no
operational UP). Protocols like ICMP or DHCP, which use net_send_data()
directly, should not be able to send packets in such case.

Signed-off-by: Robert Lubos <[email protected]>
@sonarqubecloud
Copy link

sonarqubecloud bot commented Dec 1, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants