summaryrefslogtreecommitdiffstats
path: root/sys/netinet6
Commit message (Collapse)AuthorAgeFilesLines
* Lock the sysctl(8) knobs that turn ip{,6}fw(8) firewalling andcjc2002-08-251-3/+5
| | | | | | | | | | | firewall logging on and off when at elevated securelevel(8). It would be nice to be able to only lock these at securelevel >= 3, like rules are, but there is no such functionality at present. I don't see reason to be adding features to securelevel(8) with MAC being merged into 5.0. PR: kern/39396 Reviewed by: luigi MFC after: 1 week
* check packet length before fetching ESP crypto checksum.ume2002-08-241-0/+8
| | | | | Obtained from: KAME MFC after: 2 days
* Replace (ab)uses of "NULL" where "0" is really meant.archie2002-08-222-6/+6
|
* o Merge <machine/ansi.h> and <machine/types.h> into a new headermike2002-08-211-3/+3
| | | | | | | | | | | | | | | | | | | | | called <machine/_types.h>. o <machine/ansi.h> will continue to live so it can define MD clock macros, which are only MD because of gratuitous differences between architectures. o Change all headers to make use of this. This mainly involves changing: #ifdef _BSD_FOO_T_ typedef _BSD_FOO_T_ foo_t; #undef _BSD_FOO_T_ #endif to: #ifndef _FOO_T_DECLARED typedef __foo_t foo_t; #define _FOO_T_DECLARED #endif Concept by: bde Reviewed by: jake, obrien
* Create new functions in_sockaddr(), in6_sockaddr(), andtruckman2002-08-212-38/+58
| | | | | | | | | | | | | | | | | in6_v4mapsin6_sockaddr() which allocate the appropriate sockaddr_in* structure and initialize it with the address and port information passed as arguments. Use calls to these new functions to replace code that is replicated multiple times in in_setsockaddr(), in_setpeeraddr(), in6_setsockaddr(), in6_setpeeraddr(), in6_mapped_sockaddr(), and in6_mapped_peeraddr(). Inline COMMON_END in tcp_usr_accept() so that we can call in_sockaddr() with temporary copies of the address and port after the PCB is unlocked. Fix the lock violation in tcp6_usr_accept() (caused by calling MALLOC() inside in6_mapped_peeraddr() while the PCB is locked) by changing the implementation of tcp6_usr_accept() to match tcp_usr_accept(). Reviewed by: suz
* Enclose IPv6 addresses in brackets when they are displayed printable with ajmallett2002-08-191-1/+1
| | | | | | | | TCP/UDP port seperated by a colon. This is for the log_in_vain facility. Pointed out by: Edward J. M. Brocklesby Reviewed by: ume MFC after: 2 weeks
* Increase size of ifnet.if_flags from 16 bits (short) to 32 bits (int). To avoidsobomax2002-08-181-1/+1
| | | | | | | breaking application ABI use unused ifreq.ifru_flags[1] for upper 16 bits in SIOCSIFFLAGS and SIOCGIFFLAGS ioctl's. Reviewed by: -hackers, -net
* Introduce support for Mandatory Access Control and extensiblerwatson2002-08-021-0/+5
| | | | | | | | | | kernel access control. When generating nd6 output on an interface, label the packet appropriately. Obtained from: TrustedBSD Project Sponsored by: DARPA, NAI Labs
* correct comment for setsockopt arg size.ume2002-07-251-3/+3
| | | | | | Reported by: Martin Laabs <martin@martin.erfurt.thur.de> Obtained from: KAME MFC after: 1 week
* cleanup usage of ip6_mapped_addr_on and ip6_v6only. now,ume2002-07-252-4/+3
| | | | | | ip6_mapped_addr_on is unified into ip6_v6only. MFC after: 1 week
* Change the default setting of an IPv4-mapped IPv6 address to off.ume2002-07-251-1/+1
| | | | Requested by: many people
* make sure to set/unset INP_IPV4 according to a valueume2002-07-241-0/+4
| | | | | | of IN6P_IPV6_V6ONLY Reviewed by: Keiichi SHIMA <keiichi@iij.ad.jp>
* do not refer to IN6P_BINDV6ONLY anymore.ume2002-07-221-7/+1
| | | | | Obtained from: KAME MFC after: 1 week
* sin6_len is not an address family. I believe this doesn'tume2002-07-221-1/+1
| | | | break compatibility with POSIX.1-2001.
* fixed to make mbuf chain.ume2002-07-181-1/+1
| | | | | Obtained from: KAME MFC after: 1 week
* - fixed a bug that we can't send a packet to ipv4mapped ipv6 addressume2002-07-151-0/+2
| | | | | | | | | | using a udp6 socket without bind(2)ing. - fbsd4/430 reported from the FreeBSD team. - this fix is different from the fix reported in the above PR. i think this better, but we need some test. Obtained from: KAME MFC after: 3 weeks
* Notify functions can destroy the pcb, so they have to return anhsu2002-06-144-6/+8
| | | | | | | | indication of whether this happenned so the calling function knows whether or not to unlock the pcb. Submitted by: Jennifer Yang (yangjihui@yahoo.com) Bug reported by: Sid Carter (sidcarter@symonds.net)
* As a stop-gap measure, add one INP_LOCK_DESTROY() to in6_pcbdetach() tohsu2002-06-121-0/+1
| | | | get kernel compiled with INET6 to boot.
* Lock up inpcb.hsu2002-06-101-2/+3
| | | | Submitted by: Jennifer Yang <yangjihui@yahoo.com>
* __FreeBSD__ is not a compiler constant. We must useume2002-05-311-1/+1
| | | | | | __FreeBSD_version here. Submitted by: rwatson
* Back out my lats commit of locking down a socket, it conflicts with hsu's work.tanimura2002-05-317-151/+38
| | | | Requested by: hsu
* o Conditionalize sections for POSIX.1-2001 compatibility.mike2002-05-231-31/+49
| | | | | | | | | | o Use POSIX spelling for types, where possible. o Define size_t in the __BSD_VISIBLE case (this isn't really needed for standards conformance, but follows the tradition of not requiring <sys/types.h> as a prerequisite). o Use _BYTE_ORDER and friends instead of BYTE_ORDER and friends, since there may not be enough pollution in order for the latter to work. o Add an XXX note about the missing IPPROTO_IPV6 macro.
* Lock down a socket, milestone 1.tanimura2002-05-207-38/+151
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | o Add a mutex (sb_mtx) to struct sockbuf. This protects the data in a socket buffer. The mutex in the receive buffer also protects the data in struct socket. o Determine the lock strategy for each members in struct socket. o Lock down the following members: - so_count - so_options - so_linger - so_state o Remove *_locked() socket APIs. Make the following socket APIs touching the members above now require a locked socket: - sodisconnect() - soisconnected() - soisconnecting() - soisdisconnected() - soisdisconnecting() - sofree() - soref() - sorele() - sorwakeup() - sotryfree() - sowakeup() - sowwakeup() Reviewed by: alfred
* Recent zlib does not like Z_FLUSH at the end of inflate().ume2002-05-121-4/+7
| | | | | | | Reported by: quak@mydiax.ch Obtained from: KAME MFC after: 2 days and approved by re
* Revised MLD-related definitionsume2002-05-062-53/+54
| | | | | | | | | | | | - Used mld_xxx and MLD_xxx instead of mld6_xxx and MLD6_xxx according to the official defintions in rfc2292bis (macro definitions for backward compatibility were provided) - Changed the first member of mld_hdr{} from mld_hdr to mld_icmp6_hdr to avoid name space conflict in C++ This change makes ports/net/pchar compilable again under -CURRENT. Obtained from: KAME
* Revert the change of #includes in sys/filedesc.h and sys/socketvar.h.tanimura2002-04-304-35/+47
| | | | | | | | | | Requested by: bde Since locking sigio_lock is usually followed by calling pgsigio(), move the declaration of sigio_lock and the definitions of SIGIO_*() to sys/signalvar.h. While I am here, sort include files alphabetically, where possible.
* Correct timer management (deprecated) in nd6_timer.ume2002-04-241-2/+3
| | | | | Obtained from: KAME MFC after: 3 days
* just merged cosmetic changes from KAME to ease sync between KAME and FreeBSD.suz2002-04-1938-339/+375
| | | | | | | (based on freebsd4-snap-20020128) Reviewed by: ume MFC after: 1 week
* Unconditionalize the definition of INET_ADDRSTRLEN andmike2002-04-101-2/+0
| | | | | INET6_ADDRSTRLEN. Doing this helps expose bogus redefinitions in 3rd party software.
* Use <net/fddi.h> rather than <netinet/if_fddi.h>.mdodd2002-04-061-1/+1
|
* Change callers of mtx_init() to pass in an appropriate lock type name. Injhb2002-04-041-1/+1
| | | | | | | most cases NULL is passed, but in some cases such as network driver locks (which use the MTX_NETWORK_LOCK macro) and UMA zone locks, a name is used. Tested on: i386, alpha, sparc64
* Change the suser() API to take advantage of td_ucred as well as do ajhb2002-04-018-12/+16
| | | | | | | | | | | | general cleanup of the API. The entire API now consists of two functions similar to the pre-KSE API. The suser() function takes a thread pointer as its only argument. The td_ucred member of this thread must be valid so the only valid thread pointers are curthread and a few kernel threads such as thread0. The suser_cred() function takes a pointer to a struct ucred as its first argument and an integer flag as its second argument. The flag is currently only used for the PRISON_ROOT flag. Discussed on: smp@
* In nd6_lookup(), check if rt_llinfo is non-NULL to avoid returning anume2002-04-011-4/+9
| | | | | | | entry that has the LLINFO flag but is not a neighbor cache entry. Obtained from: KAME MFC after: 1 week
* Fix cached route problem.ume2002-03-291-0/+1
| | | | | | Submitted by: Keiichi SHIMA <keiichi@iij.ad.jp> (KAME) Reviewed by: JINMEI Tatuya <jinmei@isl.rdc.toshiba.co.jp> (KAME) MFC after: 1 week
* double m_free() - not critical. from niklas@openbsdume2002-03-291-3/+1
| | | | | Obtained from: KAME MFC after: 1 week
* Corrected arguments to key_allocsa called fromume2002-03-252-7/+11
| | | | | | | | {esp6, ah6}_ctlinput. Previous ones were uninitialized auto variables, which were completely bogus. Obtained from: KAME MFC after: 1 week
* 3rd arg to bcmp() was wrong. From: David Wang <dsw@juniper.net>ume2002-03-251-1/+1
| | | | | Obtained from: KAME MFC after: 1 week
* Remove references to vm_zone.h and switch over to the new uma API.jeff2002-03-201-2/+2
|
* Pacify gcc-3.1.peter2002-03-191-2/+1
|
* Remove duplicate extern declarations to silence warnings.alfred2002-03-194-9/+0
|
* put an extern for ip6_protox in here where it is only used for kernel compilingdarrenr2002-03-191-0/+1
|
* put an extern for inet6sw in here and make it active only for kernel compilingdarrenr2002-03-191-0/+4
|
* o Add INET_ADDRSTRLEN and INET6_ADDRSTRLEN defines to <arpa/inet.h>mike2002-03-101-0/+2
| | | | | | | for POSIX.1-2001 conformance. o Add magic to <netinet/in.h> and <netinet6/in6.h> to prevent redefining INET_ADDRSTRLEN and INET6_ADDRSTRLEN. o Add a note about missing typedefs in <arpa/inet.h>.
* - use des_ecb3_encrypt().ume2002-03-051-11/+9
| | | | | | | - style: added spaces after /* and before */ Obtained from: KAME MFC after: 2 weeks
* Oops, now, encription and decription are separate function.ume2002-03-051-2/+2
| | | | MFC after: 2 weeks
* - Speedup 3DES by using assembly code for i386.ume2002-03-051-2/+2
| | | | | | | - Sync des/blowfish to more recent openssl. Obtained from: KAME/NetBSD MFC after: 2 weeks
* - In nd6_rtrequest(), ignored a route when it is created by cloning andume2002-02-281-0/+21
| | | | | | | | | | is not a neighbor. see comments for the detailed reason. - Rejected the process of nd6_rtrequest() when the request is RESOLVE and the interface does not need neighbor caches. Obtained from: KAME MFC After: 1 week
* Fix another boatload of warnings (missing include) and a cosmeticpeter2002-02-282-0/+4
| | | | -Wuninitialized warning.
* Introduce a version field to `struct xucred' in place of one of thedd2002-02-271-5/+1
| | | | | | | | | | | | spares (the size of the field was changed from u_short to u_int to reflect what it really ends up being). Accordingly, change users of xucred to set and check this field as appropriate. In the kernel, this is being done inside the new cru2x() routine which takes a `struct ucred' and fills out a `struct xucred' according to the former. This also has the pleasant sideaffect of removing some duplicate code. Reviewed by: rwatson
* Fix warnings caused by discarding const.alfred2002-02-276-9/+11
| | | | Hairy Eyeball At: peter
OpenPOWER on IntegriCloud