summaryrefslogtreecommitdiffstats
path: root/net.h
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2009-02-28 08:59:48 +0000
committerRoy Marples <roy@marples.name>2009-02-28 08:59:48 +0000
commite103c79fca52c8f8eeb651e7f0e273000fe68819 (patch)
tree5e9fabd145e2fc05d04e5db152a60dabb51a261c /net.h
parente095a6ebb581216ef8369d1e468a6682332498a7 (diff)
downloaddhcpcd-e103c79fca52c8f8eeb651e7f0e273000fe68819.tar.xz
Validate UDP better by ensuring data len is not bigger than our struct
and that the claimed length by the header is not greater than our length. Thanks to Michael Olney.
Diffstat (limited to 'net.h')
-rw-r--r--net.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/net.h b/net.h
index b6ee44dd..3ebc454a 100644
--- a/net.h
+++ b/net.h
@@ -137,7 +137,7 @@ const size_t udp_dhcp_len;
ssize_t make_udp_packet(uint8_t **, const uint8_t *, size_t,
struct in_addr, struct in_addr);
ssize_t get_udp_data(const uint8_t **, const uint8_t *);
-int valid_udp_packet(const uint8_t *);
+int valid_udp_packet(const uint8_t *, size_t);
int open_socket(struct interface *, int);
ssize_t send_packet(const struct interface *, struct in_addr,