aboutsummaryrefslogtreecommitdiff
path: root/lib/libsdp
diff options
context:
space:
mode:
authorMaksim Yevmenkin <emax@FreeBSD.org>2004-02-26 20:44:55 +0000
committerMaksim Yevmenkin <emax@FreeBSD.org>2004-02-26 20:44:55 +0000
commit0d60ad30ca6d9e71aeaca783266b22ea711979f3 (patch)
tree7ca01c942fd62cbbffb4181891ee7ede1761b5c5 /lib/libsdp
parentf97e834b0271a1faffd1c29aff764379ee8a4c5c (diff)
downloadsrc-0d60ad30ca6d9e71aeaca783266b22ea711979f3.tar.gz
src-0d60ad30ca6d9e71aeaca783266b22ea711979f3.zip
Add extra sanity check for SDP packets in libsdp(3)
Fix yet another endianess bug in sdpd(8)
Notes
Notes: svn path=/head/; revision=126297
Diffstat (limited to 'lib/libsdp')
-rw-r--r--lib/libsdp/search.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/libsdp/search.c b/lib/libsdp/search.c
index 42f162daf831..20fc7e309a4a 100644
--- a/lib/libsdp/search.c
+++ b/lib/libsdp/search.c
@@ -167,6 +167,7 @@ sdp_search(void *xss,
if (xpdu.pdu.pid == SDP_PDU_ERROR_RESPONSE ||
xpdu.pdu.tid != ss->tid ||
+ xpdu.pdu.len > len ||
xpdu.len > xpdu.pdu.len) {
ss->error = EIO;
return (-1);