summaryrefslogtreecommitdiff
path: root/sys/netinet6
AgeCommit message (Collapse)Author
2013-01-17Expand the socket splicing functionality from TCP to UDP. MergeAlexander Bluhm
the code relevant for UDP from sosend() and soreceive() into somove(). That allows the kernel to directly transfer the UDP data from one socket to another. OK claudio@
2013-01-15Flushing prefixes of autoconfigured IPv6 addresses with ndp -PAlexander Bluhm
caused an uvm fault. The function in6_purgeaddr() might already free the prefix before prelist_remove() is called. So call in6_purgeaddr() for all addresses first and then loop over the remaining prefixes and call prelist_remove(). OK claudio@
2012-12-28change the malloc(9) flags from M_DONTWAIT to M_NOWAIT; OK millert@Gleydson Soares
2012-11-30Fix typo in comment.Stefan Sperling
2012-11-11align ifaliasreq.ifra_addr similar to the way that ifreq is fixed --Theo de Raadt
a gruesome union, to block the compiler from placing the struct incorrectly aligned on stack frames ok guenther
2012-11-06backout csum diff for the moment, requested by theoHenning Brauer
2012-11-05Make sure that in[6]_proto_cksum_out() is called unconditinally and notClaudio Jeker
inside the NPF block. Fixes checksum issues seen on ramdisk kernels. Initial diff by naddy@, tested and OK by many
2012-11-02unbreak ramdisks, we need to include tcp/udp.h unconditionally now and notHenning Brauer
dependent on ipsec. puzzled how this went by since I did run full mkrs... pbly lost in my forest of trees :( report Amit Kulkarni <amitkulz at gmail.com>, fix me, ok kettenis beck krw
2012-11-01redo most of the protocol (tcp/udp/...) checksum handlingHenning Brauer
-assume we have hardware checksum offloading. stop mucking with the checksum in most of the stack -stop checksum mucking in pf, just set a "needs checksumming" flag if needed -in all output pathes, very late, if we figure out the outbound interface doesn't have hw cksum offloading, do the cksum in software. this especially makes the bridge path behave like a regular output path -little special casing for bridge still required until the broadcast path loses its disgusting shortcut hacks, but at least it's in one place now and not all over the stack in6_proto_cksum_out mostly written by krw@ started at k2k11 in iceland more than 1.5 years ago - yes it took that long, this stuff is everything but easy. this happens to fix the infamous pf rdr bug that made us turn off proto cksum offloading on almost all interface drivers. ok camield sthen claudio, testing by many, thanks!
2012-10-21Add the IP_DIVERTFL socket option on divert(4) sockets to controlSebastian Benoit
which packets (as in direction) of the traffic will be diverted through the divert socket. ok claudio@, henning@
2012-10-16As CMSG_ALIGN() can overflow the integer value, do the length checkAlexander Bluhm
with and without alignment. Bug found by Clement Lecigne <clemun AT gmail DOT com> OK claudio@
2012-10-05Point an interface directly to its bridgeport configuration, insteadCamiel Dobbelaar
of to the bridge itself. This is ok, since an interface can only be part of one bridge, and the parent bridge is easy to find from the bridgeport. This way we can get rid of a lot of list walks, improving performance and shortening the code. ok henning stsp sthen reyk
2012-09-26add M_ZEROIZE as an mbuf flag, so copied PFKEY messages (with embedded keys)Markus Friedl
are cleared as well; from hshoexer@, feedback and ok bluhm@, ok claudio@
2012-09-20spltdb() was really just #define'd to be splsoftnet(); replace the formerBret Lambert
with the latter no change in md5 checksum of generated files ok claudio@ henning@
2012-09-19ioctl requests are u_long not int, spotted via clangJonathan Gray
ok deraadt@ miod@
2012-09-19Use TAILQ_FOREACH macro for loops. No binary diff.Alexander Bluhm
OK henning@
2012-09-17add IPV6_RECVDSTPORT socket option, which enables us to get originalYASUOKA Masahiko
(= before divert) destination port of a UDP packet. The way to use this option is same as IP_RECVDSTPORT. from UMEZAWA Takeshi tweaks from jmc; ok henning bluhm
2012-09-15Improve POSIX/SUS compliance of <netdb.h>, <sys/socket.h>, and <sys/un.h>.Philip Guenthe
Much ports testing of various versions by naddy@ and jasper@ ok matthew@, miller@
2012-09-07Create IPv6 privacy addresses even if static IPv6 addresses are present.Stefan Sperling
Restores the ability to use privacy addresses for outgoing connections and static addresses for incoming connections, which was broken by r1.62. ok sperreault@
2012-09-04Raise IPL to IPL_SOFTNET in nd6_addr_add(). This code originally ran atStefan Sperling
IPL_SOFTNET before it was factored out into a work queue task. ok dlg
2012-08-28Do not add SLAAC or privacy addresses when a static address in the same prefixsperreault
already exists. 5.1 and older did the right thing. 5.2 did not (mea culpa). Now we're back to doing the right thing. spotted by naddy. ok stsp.
2012-08-21Reverse the name and meaning of the IFXF_INET6_PRIVACY interfaceAlexander Bluhm
flag. It is now called IFXF_INET6_NOPRIVACY. So IPv6 privacy addresses are on by default without resetting the flag during ifconfig down/up. OK stsp@, sperreault@ (who wrote the same diff)
2012-08-15Enable IPv6 autoconfprivacy by defaultsperreault
diff originally by stsp@ "please commit it" deraadt@ "don't care" stsp@ "don't like" bluhm@
2012-07-16add IP_IPSECFLOWINFO option to sendmsg() and recvmsg(), so npppd(4)Markus Friedl
can use this to select the IPsec tunnel for sending L2TP packets. this fixes Windows (always binding to 1701) and Android clients (negotiating wildcard flows); feedback mpf@ and yasuoka@; ok henning@ and yasuoka@; ok jmc@ for the manpage
2012-07-14Make IPv6 privacy addresses appear alongside regular SLAAC addresses.sperreault
Also fix a memory management problem that was made obvious by this diff. ok bluhm@, previous version ok @stsp
2012-07-10Instead of <arpa/inet.h> pulling in <netinet/in.h>, just copy in thePhilip Guenthe
three things that it needed from there: INET_ADDRSTRLEN, INET6_ADDRSTRLEN, and struct in_addr. Add protecting #ifndefs to netinet6?/in6?.h for those. ok deraadt@
2012-07-08Instead of casting interface address pointers, use the macroAlexander Bluhm
ifatoia6(). No binary diff. OK henning@
2012-06-26Improve compliance for <arpa/inet.h> and <netinet/in.h> to define/declarePhilip Guenthe
all the symbols that POSIX says they must and fewer that they can't and, most importantly, to not require a specific ordering of headers. ports testing by naddy@ ok millert@ deraadt@
2012-05-18rt6_flush should remove all routes configured via a specified gw,Mike Belopuhov
not only CONNECTED ones. It should also be called when RA with a RouterLifetime set to 0 is sent to clear a redirect. While here make sure we use correct priorities when installing routes acquired via redirects. comments & ok bluhm
2012-05-16rfc 4861 mandates that target link local address must be includedMike Belopuhov
with a neighbour advertisment sent to a multicast address; nits & ok bluhm
2012-04-13unneccessary casts to unsigned; ok claudioTheo de Raadt
2012-04-03According to the RFC 2460 and RFC 5095, ICMP Parameter Problem, Code 0Mike Belopuhov
should be sent in response to an IPv6 packet with RH0. Improve this a bit further by filling in an icmp error pointer. With sperreault, ok sperreault, sthen
2012-04-03bail if redirect destination is not unicast before doing otherMike Belopuhov
expensive checks; ok sperreault, todd, sthen
2012-03-15Direct IPv6 packets with Ethernet encapsulation into the appropriateMike Belopuhov
input routine allowing us to bridge two IPv4 networks over an IPv6 link with gif(4). ok henning, sthen, ok and tests phessler, "lets get this in!" todd
2012-02-14typo in comment.Stuart Henderson
2012-01-24Add a short cut for atomic IPv6 fragments. They will be processedAlexander Bluhm
immediately and not go through the fragment queue. See draft-gont-6man-ipv6-atomic-fragments-00.txt. tested and ok sperreault@
2012-01-23Do not keep state when dropping overlapping IPv6 fragments in pfAlexander Bluhm
and IPv6 stack. ok sperreault@
2012-01-17During IPv6 source address selection, give address scope higher priorityStefan Sperling
than the autoconfprivacy bit, as per by RFC3484. Prevents privacy addresses from being erroneously used as source address if the destination address is in a different scope. Privacy addresses are still preferred over other source addresses from the same scope. Problem found by sthen, fix suggested by sperreault; ok sperreault
2012-01-11Simplify the #if CARP and if (IFT_CARP) dance in nd6_ns_input().Alexander Bluhm
Fix a white space bug while there. No functional change. ok mikeb@ robert@ henning@
2012-01-10Implement RFC 5722 and drop all IPv6 fragments that belong to aAlexander Bluhm
packet with overlapping fragments. ok henning@
2012-01-10Flush the cached IPv6 forward route every 500 ms. This preventsAlexander Bluhm
wrong checks for local addresses and wrong packet forwarding in environments with only one communication partner and changing addresses or routes. Remove the #if 0 around the existing code to make IPv6 behave like IPv4. ok henning@
2012-01-09Remove the IPv6 fragment overlapping length adjustment code. ItAlexander Bluhm
was already #if 0 and will never come back. Remove unused fragment struct fields and sort the others. ok henning@
2012-01-09Replace the hand-crafted queue for IPv6 fragments with LIST.Alexander Bluhm
ok henning@
2012-01-05Remove dead code from #if 0: we do not have an ipsrcchk_rt anywhere else.Alexander Bluhm
from FreeBSD; ok henning@
2012-01-05Replace the hand-crafted queue for fragmented IPv6 packets with TAILQ.Alexander Bluhm
I forgot the header file containing struct ip6q in the last commit.
2012-01-05Replace the hand-crafted queue for fragmented IPv6 packets with TAILQ.Alexander Bluhm
ok henning@
2012-01-03To access the ifaddr of an in_ifaddr or in6_ifaddr struct, it isAlexander Bluhm
cleaner to access the first member via ia_ifa instead of casting. No binary change. ok henning@ krw@
2011-12-27Instead of hand crafted code, use the macros TAILQ_FOREACH(_SAFE)Alexander Bluhm
and TAILQ_EMPTY for accessing the nd_defrouter list. No funtional change. ok stsp@
2011-12-02Kill unused IFCAP_IPSEC and IFCAP_IPCOMP.Christiano F. Haesbaert
ok claudio@ henning@ mikeb@
2011-11-24rdomain support for IPv6sperreault
ok mikeb