mirror of
https://github.com/RGBCube/serenity
synced 2025-05-16 19:55:06 +00:00
Kernel: Do not reject broadcast UDP packets right away
This patch relaxes how we think about UDP packets being "for us" a bit; the proper way to handle this would be to also check if the matched socket has SO_BROADCAST set, but we don't have that :)
This commit is contained in:
parent
8780151155
commit
2ea934bcfd
1 changed files with 1 additions and 1 deletions
|
@ -288,7 +288,7 @@ void handle_udp(const IPv4Packet& ipv4_packet)
|
|||
}
|
||||
|
||||
auto adapter = NetworkAdapter::from_ipv4_address(ipv4_packet.destination());
|
||||
if (!adapter) {
|
||||
if (!adapter && ipv4_packet.destination() != IPv4Address(255, 255, 255, 255)) {
|
||||
klog() << "handle_udp: this packet is not for me, it's for " << ipv4_packet.destination().to_string().characters();
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue