Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F169807699
D27332.id79891.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
621 B
Referenced Files
None
Subscribers
None
D27332.id79891.diff
View Options
Index: lib/libc/rpc/getrpcport.c
===================================================================
--- lib/libc/rpc/getrpcport.c
+++ lib/libc/rpc/getrpcport.c
@@ -68,8 +68,8 @@
addr.sin_len = sizeof(struct sockaddr_in);
addr.sin_family = AF_INET;
addr.sin_port = 0;
- if (hp->h_length > addr.sin_len)
- hp->h_length = addr.sin_len;
+ if (hp->h_length > sizeof(addr.sin_addr.s_addr))
+ hp->h_length = sizeof(addr.sin_addr.s_addr);
memcpy(&addr.sin_addr.s_addr, hp->h_addr, (size_t)hp->h_length);
/* Inconsistent interfaces need casts! :-( */
return (pmap_getport(&addr, (u_long)prognum, (u_long)versnum,
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Sep 3, 3:18 PM (4 h, 49 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
38126419
Default Alt Text
D27332.id79891.diff (621 B)
Attached To
Mode
D27332: Fix buffer overrun in getrpcport(3)
Attached
Detach File
Event Timeline
Log In to Comment