Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F108295232
D38361.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
948 B
Referenced Files
None
Subscribers
None
D38361.diff
View Options
diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c
--- a/sys/netinet/in_pcb.c
+++ b/sys/netinet/in_pcb.c
@@ -2242,6 +2242,10 @@
KASSERT((lookupflags & ~(INPLOOKUP_WILDCARD)) == 0,
("%s: invalid lookup flags %d", __func__, lookupflags));
+ KASSERT(faddr.s_addr != INADDR_ANY,
+ ("%s: invalid foreign address", __func__));
+ KASSERT(laddr.s_addr != INADDR_ANY,
+ ("%s: invalid local address", __func__));
INP_HASH_LOCK_ASSERT(pcbinfo);
/*
diff --git a/sys/netinet6/in6_pcb.c b/sys/netinet6/in6_pcb.c
--- a/sys/netinet6/in6_pcb.c
+++ b/sys/netinet6/in6_pcb.c
@@ -980,6 +980,10 @@
KASSERT((lookupflags & ~(INPLOOKUP_WILDCARD)) == 0,
("%s: invalid lookup flags %d", __func__, lookupflags));
+ KASSERT(!IN6_IS_ADDR_UNSPECIFIED(faddr),
+ ("%s: invalid foreign address", __func__));
+ KASSERT(!IN6_IS_ADDR_UNSPECIFIED(laddr),
+ ("%s: invalid local address", __func__));
INP_HASH_LOCK_ASSERT(pcbinfo);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Jan 24, 3:16 PM (7 h, 56 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16090288
Default Alt Text
D38361.diff (948 B)
Attached To
Mode
D38361: inpcb: Assert against wildcard addrs in in_pcblookup_hash_locked()
Attached
Detach File
Event Timeline
Log In to Comment