summaryrefslogtreecommitdiffstats
path: root/sys/netinet6/in6.c
Commit message (Collapse)AuthorAgeFilesLines
* Clean up VCS Ids.obrien2007-12-101-3/+5
|
* Remove more dup'd codejulian2007-12-061-21/+0
| | | | MFC After: 1 week
* remove duped codejulian2007-12-061-26/+1
| | | | | Reviewed By: gnn MRC after: 1 week
* Space cleanupdelphij2007-07-051-3/+3
| | | | Approved by: re (rwatson)
* ANSIfy[1] plus some style cleanup nearby.delphij2007-07-051-72/+30
| | | | | | Discussed with: gnn, rwatson Submitted by: Karl Sj?dahl - dunceor <dunceor gmail com> [1] Approved by: re (rwatson)
* fixed memory leak for IPv6 multicast membership information associatedjinmei2007-06-021-19/+16
| | | | | | | with interface addresses. Approved by: gnn (mentor) MFC after: 1 week
* simplified the fix in rev. 1.69 by replacing RT_REMREF+RT_UNLOCK withjinmei2007-06-021-6/+3
| | | | | | RTFREE_LOCKED. Approved by: gnn (mentor)
* do not directly call rtfree() to meet an assumption in the callee.jinmei2007-05-251-6/+9
| | | | | | | (this fix suppresses a warning message appearing in the boot time on IPv6-enabled systems) Approved by: gnn (mentor)
* Make IPv6 multicast forwarding dynamically loadable from a GENERIC kernel.bms2007-02-241-1/+1
| | | | | | It is built in the same module as IPv4 multicast forwarding, i.e. ip_mroute.ko, if and only if IPv6 support is enabled for loadable modules. Export IPv6 forwarding structs to userland netstat(1) via sysctl(9).
* In ip6_sprintf print the addresses in a more common/readablebz2006-12-161-4/+18
| | | | | | format eliminating leading zeros like in :0001 -> :1. Reviewed by: mlaier
* MFp4: 92972, 98913 + one more changebz2006-12-121-20/+21
| | | | | | | In ip6_sprintf no longer use and return one of eight static buffers for printing/logging ipv6 addresses. The caller now has to hand in a sufficiently large buffer as first argument.
* Sweep kernel replacing suser(9) calls with priv(9) calls, assigningrwatson2006-11-061-17/+41
| | | | | | | | | | | | | specific privilege names to a broad range of privileges. These may require some future tweaking. Sponsored by: nCircle Network Security, Inc. Obtained from: TrustedBSD Project Discussed on: arch@ Reviewed (at least in part) by: mlaier, jmg, pjd, bde, ceri, Alex Lyashkov <umka at sevcity dot net>, Skip Ford <skip dot ford at verizon dot net>, Antoine Brodin <antoine dot brodin at laposte dot net>
* fixed a bug that IPv6 packets arriving to stf are not accepted.suz2006-09-221-2/+6
| | | | | | | | (a degrade introduced in in6.c Rev 1.61) PR: kern/103415 Submitted by: JINMEI Tatuya MFC after: 1 week
* With exception of the if_name() macro, all definitions in net_osdep.hbrooks2006-08-041-2/+0
| | | | | | | | were unused or already in if_var.h so add if_name() to if_var.h and remove net_osdep.h along with all references to it. Longer term we may want to kill off if_name() entierly since all modern BSDs have if_xname variables rendering it unnecessicary.
* There is a consensus that ifaddr.ifa_addr should never be NULL,yar2006-06-291-6/+0
| | | | | | | | | | except in places dealing with ifaddr creation or destruction; and in such special places incomplete ifaddrs should never be linked to system-wide data structures. Therefore we can eliminate all the superfluous checks for "ifa->ifa_addr != NULL" and get ready to the system crashing honestly instead of masking possible bugs. Suggested by: glebius, jhb, ru
* Fix spurious warnings from neighbor discovery when working with IPv6 overgnn2006-06-081-8/+40
| | | | | | | | point to point tunnels (gif). PR: 93220 Submitted by: Jinmei Tatuya MFC after: 1 week
* Fix for an inappropriate bzero of the ICMPv6 stats. The code was zero'ing ↵gnn2006-02-081-1/+1
| | | | | | | | the wrong structure member but setting the correct one. Submitted by: James dot Juran at baesystems dot com Reviewed by: gnn MFC after: 1 week
* statically configured IPv6 address is properly added/deleted nowsuz2005-10-311-75/+51
| | | | | | Obtained from: KAME Reported in: freebsd-net@freebsd MFC after: 1 day
* fixed a compilation failure on amd64/sparc64/ia64suz2005-10-221-2/+2
| | | | | Submitted by: max MFC after: 2 month
* sync with KAME regarding NDPsuz2005-10-211-80/+322
| | | | | | | | | | | | - introduced fine-grain-timer to manage ND-caches and IPv6 Multicast-Listeners - supports Router-Preference <draft-ietf-ipv6-router-selection-07.txt> - better prefix lifetime management - more spec-comformant DAD advertisement - updated RFC/internet-draft revisions Obtained from: KAME Reviewed by: ume, gnn MFC after: 2 month
* added an ioctl option in kernel so that ndp/rtadvd can change some ↵suz2005-10-191-0/+1
| | | | | | | | NDP-related kernel variables based on their configurations (RFC2461 p.43 6.2.1 mandates this for IPv6 routers) Obtained from: KAME Reviewd by: ume, gnn MFC after: 2 weeks
* sync with KAME in the following points:suz2005-10-191-24/+19
| | | | | | | | | | | | - fixed typos - improved some comment descriptions - use NULL, instead of 0, to denote a NULL pointer - avoid embedding a magic number in the code - use nd6log() instead of log() to record NDP-specific logs - nuked an unnecessay white space Obtained from: KAME MFC after: 1 day
* IPv6 was improperly defining its malloc type the same as IPv4 (M_IPMADDR,obrien2005-09-071-4/+4
| | | | | M_IPMOPTS, M_MRTABLE). Thus we had conflicting instantiations. Create an IPv6-specific type to overcome this.
* Propagate rename of IFF_OACTIVE and IFF_RUNNING to IFF_DRV_OACTIVE andrwatson2005-08-091-2/+2
| | | | | | | | | | | | | | IFF_DRV_RUNNING, as well as the move from ifnet.if_flags to ifnet.if_drv_flags. Device drivers are now responsible for synchronizing access to these flags, as they are in if_drv_flags. This helps prevent races between the network stack and device driver in maintaining the interface flags field. Many __FreeBSD__ and __FreeBSD_version checks maintained and continued; some less so. Reviewed by: pjd, bz MFC after: 7 days
* scope cleanup. with this changeume2005-07-251-136/+187
| | | | | | | | | | | | | | | | | | | - most of the kernel code will not care about the actual encoding of scope zone IDs and won't touch "s6_addr16[1]" directly. - similarly, most of the kernel code will not care about link-local scoped addresses as a special case. - scope boundary check will be stricter. For example, the current *BSD code allows a packet with src=::1 and dst=(some global IPv6 address) to be sent outside of the node, if the application do: s = socket(AF_INET6); bind(s, "::1"); sendto(s, some_global_IPv6_addr); This is clearly wrong, since ::1 is only meaningful within a single node, but the current implementation of the *BSD kernel cannot reject this attempt. Submitted by: JINMEI Tatuya <jinmei__at__isl.rdc.toshiba.co.jp> Obtained from: KAME
* Use IFF_LOCKGIANT/IFF_UNLOCKGIANT around calls to the interfaceiedowse2005-06-021-4/+8
| | | | | | if_ioctl routine. This should fix a number of code paths through soo_ioctl() that could call into Giant-locked network drivers without first acquiring Giant.
* Add CARP (Common Address Redundancy Protocol), which allows multipleglebius2005-02-221-2/+35
| | | | | | | | | | | | | hosts to share an IP address, providing high availability and load balancing. Original work on CARP done by Michael Shalayeff, with many additions by Marco Pfatschbacher and Ryan McBride. FreeBSD port done solely by Max Laier. Patch by: mlaier Obtained from: OpenBSD (mickey, mcbride)
* /* -> /*- for license, minor formatting changes, separate for KAMEimp2005-01-071-2/+2
|
* Remove in6_prefix.[ch] and the contained router renumbering capability.rwatson2004-08-231-7/+0
| | | | | | | | | | | | The prefix management code currently resides in nd6, leaving only the unused router renumbering capability in the in6_prefix files. Removing it will make it easier for us to provide locking for the remainder of IPv6 by reducing the number of objects requiring synchronized access. This functionality has also been removed from NetBSD and OpenBSD. Submitted by: George Neville-Neil <gnn at neville-neil.com> Discussed with/approved by: suz, keiichi at kame.net, core at kame.net
* Remove advertising clause from University of California Regent'simp2004-04-071-4/+0
| | | | | | | license, per letter dated July 22, 1999 and email from Peter Wemm, Alan Cox and Robert Watson. Approved by: core, peter, alc, rwatson
* move in6_addmulti()/in6_delmulti() into mld6.cume2004-03-041-90/+0
| | | | Obtained from: KAME
* missing splx().ume2004-03-041-1/+3
| | | | | Obtained from: KAME MFC after: 3 days
* - stlye and commentsume2004-03-031-15/+16
| | | | | | | - variable name change (scopeid -> zoneid) - u_short -> u_int16_t, u_char -> u_int8_t Obtained from: KAME
* Bring eventhandler callbacks for pf.mlaier2004-02-261-0/+3
| | | | | | | | This enables pf to track dynamic address changes on interfaces (dailup) with the "on (<ifname>)"-syntax. This also brings hooks in anticipation of tracking cloned interfaces, which will be in future versions of pf. Approved by: bms(mentor)
* Fix array overflow: If len=128, don't access [16] of a 16-byte IPv6cperciva2004-02-241-1/+2
| | | | | | | | address, even if we subsequently ignore its value by applying a >>8 to it. Reported by: "Ted Unangst" <tedu@coverity.com> Approved by: rwatson (mentor), {ume, suz} (KAME)
* try rtinit() only when the route is not installed.ume2004-01-101-2/+5
| | | | | | | | this allows, e.g., duplicated attempts of 'ifconfig lo0 ::1' like for IPv4. Obtained from: KAME MFC after: 1 week
* replace explicit changes to rt_refcnt by RT_ADDREF and RT_REMREFsam2003-11-081-1/+1
| | | | | | | macros that expand to include assertions when the system is built with INVARIANTS Supported by: FreeBSD Foundation
* byebye in6_ifawithscope(). it was a function for old sourceume2003-11-051-282/+0
| | | | | | address selection. Obtained from: KAME
* use nd6log().ume2003-11-041-30/+24
| | | | Obtained from: KAME
* add management part of address selection policy described inume2003-10-301-0/+8
| | | | | | RFC3484. Obtained from: KAME
* correct LOR by using a local variable to hold resultsam2003-10-291-3/+5
| | | | | | instead of holding a lock while calling out of view Supported by: FreeBSD Foundation
* - change scope to zone.ume2003-10-211-7/+13
| | | | | | | | - change node-local to interface-local. - better error handling of address-to-scope mapping. - use in6_clearscope(). Obtained from: KAME
* correct linkmtu handling.ume2003-10-201-2/+5
| | | | Obtained from: KAME
* nuke duplicate function and unused function.ume2003-10-171-41/+3
| | | | Obtained from: KAME
* revert wrongly dropped null check by previous commit.ume2003-10-171-0/+2
|
* - add dom_if{attach,detach} framework.ume2003-10-171-32/+53
| | | | | | - transition to use ifp->if_afdata. Obtained from: KAME
* nuke SCOPEDROUTING. Though it was there for a long time,ume2003-10-101-19/+0
| | | | it was never enabled.
* - fix typo in comment.ume2003-10-071-111/+78
| | | | | | - style. Obtained from: KAME
* return(code) -> return (code)ume2003-10-061-61/+61
| | | | (reduce diffs against KAME)
* Locking for updates to routing table entries. Each rtentry gets a mutexsam2003-10-041-25/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | that covers updates to the contents. Note this is separate from holding a reference and/or locking the routing table itself. Other/related changes: o rtredirect loses the final parameter by which an rtentry reference may be returned; this was never used and added unwarranted complexity for locking. o minor style cleanups to routing code (e.g. ansi-fy function decls) o remove the logic to bump the refcnt on the parent of cloned routes, we assume the parent will remain as long as the clone; doing this avoids a circularity in locking during delete o convert some timeouts to MPSAFE callouts Notes: 1. rt_mtx in struct rtentry is guarded by #ifdef _KERNEL as user-level applications cannot/do-no know about mutex's. Doing this requires that the mutex be the last element in the structure. A better solution is to introduce an externalized version of struct rtentry but this is a major task because of the intertwining of rtentry and other data structures that are visible to user applications. 2. There are known LOR's that are expected to go away with forthcoming work to eliminate many held references. If not these will be resolved prior to release. 3. ATM changes are untested. Sponsored by: FreeBSD Foundation Obtained from: BSD/OS (partly)
OpenPOWER on IntegriCloud