summaryrefslogtreecommitdiff
path: root/lib/libc/net
AgeCommit message (Collapse)Author
2011-04-19Fix spacing nit.Matthew Dempsky
ok jmc@
2011-04-05Add AI_FQDN flag to getaddrinfo(3). Prompted by discussions with djm@Matthew Dempsky
about cert checking in OpenSSH. Man page wording tweaks thanks to jmc@. ok henning@, jmc@; positive feedback from djm@, ajacoutat@ Committing now to reuse guenther@'s libc minor bump instead of cranking it again, as suggested by deraadt@.
2010-09-24Implement if_freenameindex() as a real function as required by posix.Claudio Jeker
OK deraadt@, millert@
2010-07-01getpeereid() can now be a library routine using getsockopt() withTheo de Raadt
SOL_SOCKET and SO_PEERCRED, only issue being that it cannot return EFAULT for a page fault. The kernel code will soon be put into compat, and then in 10 years or so tedu will delete it. ok guenther millert
2010-06-29use a union to align the dns answer buffer until gcc4 is fixedTheo de Raadt
2010-06-29use a union to align the dns answer buffer until gcc4 is fixedTheo de Raadt
2010-05-06Do not return success when the IPv6 address has a :: and 8 hex sections.Claudio Jeker
::1:2:3:4:5:6:7:8 for example. PR 6277, fix by Jun KAWAI (kwj at vlax net) OK henning, gilles, jsing (who also reminded me to remove the now wrong comment about superfluous ::)
2010-02-03Use MACHINE_CPU instead of MACHINE_ARCH to pick the correct machine dependentMiod Vallat
files or directories when applicable. The inspiration and name of MACHINE_CPU come from NetBSD, although the way to provide it to Makefiles is completely different. ok kettenis@
2009-12-29replace a few remaining UNIX terms with .Ux macros; this diffIgor Sobrado
completes the changes from Oct 22.
2009-11-18More shrinkage, a bit for ramdisks but mostly for static binaries:Philip Guenthe
- wrap with #ifndef NO_LOG_BAD_DNS_RESPONSES libc code that uses p_class() and p_type() for diagnostics, then add that define to libstub to avoid pulling in res_debug_syms.o - split rcmd() and ruserok() into separate files, as nothing uses both - split readdir_r() to its own file - split syslog_r() from syslog(), as the latter needs localtime(); many binaries no longer need to pull in all the time code after this; switch from usleep() to nanosleep() while we're at it (The profit of analysis of -Wl,-M,--cref output) Chops 888kB from /bin and /sbin on i386 ok deraadt@, miod@
2009-09-02make getaddrinfo(3) accept numeric servname when ai_socktype is notFederico G. Schwindt
specified in hint or hints is NULL. claudio@ ok
2009-08-13various MLINK fixes from Alan R. S. Bueno;Jason McIntyre
2009-07-09promote correct style for error checkingEric Faurot
ok tedu@ deraadt@ krw@
2009-06-05compare and shift buffer against a fixed length not strlen derived values.Pierre-Yves Ritschard
ok otto@
2009-06-04simplify the 'family' option parser and make it more evident what we'rePierre-Yves Ritschard
now doing. ok deraadt@
2009-06-04Add a resolv.conf option to specify the order in which getaddrinfoPierre-Yves Ritschard
PF_UNSPEC queries are made. While there change the default from inet6 first then inet4 to inet4 first then inet6, this prevents the many people with IPv4 only connectivity from constantly trying to contact IPv6 addresses, and also unbreaks many ports who don't use getaddrinfo right. ok deraadt@, plenty of cheering in the room wrt the idea, not loud enough complaining from the v6 crowd.
2009-06-02- define EAI_OVERFLOW, as per IEEE Std 1003.1-2001(Interpretation #13)Jasper Lievisse Adriaanse
hint from claudio@, ok millert@
2009-05-06Document AI_NUMERICSERV; feedback and ok millert@Jacek Masiulaniec
2009-03-17correct argument type for swap64(); from Thomas PfaffJason McIntyre
2008-12-22The example for detecting malicious PTR records could be easily misinterpreted.Jacek Masiulaniec
Make it less ambiguous; ok gilles@ claudio@
2008-12-09fix inet_ntop(3) prototype; ok millert@ libc to be bumbed very soonOtto Moerbeek
2008-12-07Document that ethers_aton returns NULL for invalid addresses.Paul de Weerd
Suggested by and ok claudio@, ok jmc@
2008-11-24Correctly jump over routing headers and calculate the size of the if_dataClaudio Jeker
struct in the if_msghdr instead of using sizeof() blindly. This allows us to grow if_data without causing issues for the getifaddrs() users. OK deraadt@ (who needs this for some cool upcomming stuff)
2008-09-01do not overflow for large prefix len (e.g. 2147483649)Markus Friedl
report Maksymilian Arciemowicz; ok djm, deraadt
2008-08-15Add resolv.conf(5) option to force lookups by TCP: "options tcp"Damien Miller
Also Extend "nameserver" declaration syntax to support port numbers. To avoid ambiguity these are only parsed when the address is enclosed in square brackets, e.g. "nameserver [127.0.0.1]:5353" Together these changes make forwarding DNS over a SSH tunnel very easy, but unfortunately some programs in ports/ implement their own resolvers (e.g. firefox). These will need to be modified to support these options separately. fixes jsing@ reyk@ ok deraadt@ millert@ krw@ + "I like it" from lots
2008-06-26First pass at removing clauses 3 and 4 from NetBSD licenses.Ray Lai
Not sure what's more surprising: how long it took for NetBSD to catch up to the rest of the BSDs (including UCB), or the amount of code that NetBSD has claimed for itself without attributing to the actual authors. OK deraadt@
2008-05-11garbage collect the portability bits for the removed select() support.Brad Smith
ok djm@ deraadt@
2008-04-18convert select() => poll(), saves a runtime malloc+free per retryDamien Miller
feedback deraadt@ drahn@; ok deraadt@
2008-04-16permit _ in the middle of a DNS name componentTheo de Raadt
2008-04-13Improve the libc DNS resolver ID generation algorithm to be moreDamien Miller
resistant to prediction atacks by wrapping the existing LCG in a random permutation generator based on a Luby-Rackoff block cipher. lots of discussion and final ok deraadt@
2007-10-11use RRSIG instead of SIG for DNSSEC. ok djm@Jakob Schlyter
2007-09-17Check snprintf(3) return value for error or truncation.Moritz Jodeit
Mostly path construction, where truncation could be bad. ok and input from deraadt@ millert@ ray@
2007-09-02use calloc() to avoid malloc(n * m) overflows; checked by djm canacar jsgTheo de Raadt
2007-08-05/*FALLTHRU*/ -> /* FALLTHROUGH */Ray Lai
2007-06-12``dot'' notationJason McIntyre
is more readable than `.' notation zap some silly .Tn whilst here;
2007-06-05remove ipx-related stuff. objections nobody. major bump by kurt in a fewHenning Brauer
2007-05-31convert to new .Dd format;Jason McIntyre
2007-05-20Typos.Ray Lai
OK jmc@.
2007-05-18Remove no-op code. From tbert.Ray Lai
OK moritz@ and jaredy@
2007-05-17Improve reentrancy by not using global variable. Removes twoRay Lai
wrappers around fopen/fclose. From tbert. OK millert@, tedu@, and itojun@.
2007-05-16Wrap some functions, labels, and variables in #ifdefs correspondingRay Lai
to #ifdefs where they are used. Found by lint by bret dot lambert at gmail. OK deraadt@.
2007-05-12Use size_t for strlen results.Ray Lai
OK moritz@.
2007-05-12Clean up macros according to style. From tbert <bret dot lambert at gmail>.Ray Lai
OK moritz@ and jaredy@.
2007-05-10Use syslog_r instead of syslog in getaddrinfo. Slowly makingRay Lai
getaddrinfo reentrant. OK millert@ and deraadt@.
2007-02-18strlen(3) returns size_t, not int.Ray Lai
Suggested by itojun@ in response to my getaddrinfo fixes. OK millert@.
2007-02-18strlen(3) returns size_t.Ray Lai
OK itojun@.
2007-02-17Remove duplicate code. No functional change.Ray Lai
OK itojun@, moritz@, and millert@.
2007-02-15Remove two mutexes by replacing getservbyname() and getservbyport()Ray Lai
calls with their reentrant versions. OK millert@.
2007-02-14correct a mistake concerning ifa_data;Jason McIntyre
found by Srebrenko Sehic, corrected by millert and claudio;
2007-02-14remove size_t and int mixup. same as getaddrinfo.c 1.30 -> 1.31.Jun-ichiro itojun Hagino