diff options
author | archie <archie@FreeBSD.org> | 2000-05-04 17:54:37 +0000 |
---|---|---|
committer | archie <archie@FreeBSD.org> | 2000-05-04 17:54:37 +0000 |
commit | 44be3a44bdea737af82867ace4c1c49456b343e5 (patch) | |
tree | 3de7f3999eea8f252bfab2d528641cf4789815e8 /sys/modules/netgraph/ksocket | |
parent | e306b417ff4bae50658cdbeeef9128c894836842 (diff) | |
download | FreeBSD-src-44be3a44bdea737af82867ace4c1c49456b343e5.zip FreeBSD-src-44be3a44bdea737af82867ace4c1c49456b343e5.tar.gz |
Move netgraph node type man pages from section 8 to section 4.
Diffstat (limited to 'sys/modules/netgraph/ksocket')
-rw-r--r-- | sys/modules/netgraph/ksocket/Makefile | 2 | ||||
-rw-r--r-- | sys/modules/netgraph/ksocket/ng_ksocket.4 | 8 | ||||
-rw-r--r-- | sys/modules/netgraph/ksocket/ng_ksocket.8 | 187 |
3 files changed, 5 insertions, 192 deletions
diff --git a/sys/modules/netgraph/ksocket/Makefile b/sys/modules/netgraph/ksocket/Makefile index db07926..055b7fc 100644 --- a/sys/modules/netgraph/ksocket/Makefile +++ b/sys/modules/netgraph/ksocket/Makefile @@ -2,6 +2,6 @@ KMOD= ng_ksocket SRCS= ng_ksocket.c -MAN8= ng_ksocket.8 +MAN4= ng_ksocket.4 .include "${.CURDIR}/../../../conf/kmod.mk" diff --git a/sys/modules/netgraph/ksocket/ng_ksocket.4 b/sys/modules/netgraph/ksocket/ng_ksocket.4 index 9e5d132a..c35a7f6 100644 --- a/sys/modules/netgraph/ksocket/ng_ksocket.4 +++ b/sys/modules/netgraph/ksocket/ng_ksocket.4 @@ -35,7 +35,7 @@ .\" $FreeBSD$ .\" .Dd November 15, 1999 -.Dt NG_KSOCKET 8 +.Dt NG_KSOCKET 4 .Os FreeBSD .Sh NAME .Nm ng_ksocket @@ -51,7 +51,7 @@ node type allows one to open a socket inside the kernel and have it appear as a Netgraph node. The .Nm node type is the reverse of the socket node type (see -.Xr ng_socket 8 ) : +.Xr ng_socket 4 ) : whereas the socket node type enables the user-level manipulation (via a socket) of what is normally a kernel-level entity (the associated Netgraph node), the @@ -176,8 +176,8 @@ Shutdown of the node closes the associated socket. .Sh SEE ALSO .Xr socket 2 , .Xr netgraph 4 , -.Xr ng_socket 8 , -.Xr ngctl 8 . +.Xr ng_socket 4 , +.Xr ngctl 8 .Sh HISTORY The .Nm diff --git a/sys/modules/netgraph/ksocket/ng_ksocket.8 b/sys/modules/netgraph/ksocket/ng_ksocket.8 deleted file mode 100644 index 9e5d132a..0000000 --- a/sys/modules/netgraph/ksocket/ng_ksocket.8 +++ /dev/null @@ -1,187 +0,0 @@ -.\" Copyright (c) 1999 Whistle Communications, Inc. -.\" All rights reserved. -.\" -.\" Subject to the following obligations and disclaimer of warranty, use and -.\" redistribution of this software, in source or object code forms, with or -.\" without modifications are expressly permitted by Whistle Communications; -.\" provided, however, that: -.\" 1. Any and all reproductions of the source or object code must include the -.\" copyright notice above and the following disclaimer of warranties; and -.\" 2. No rights are granted, in any manner or form, to use Whistle -.\" Communications, Inc. trademarks, including the mark "WHISTLE -.\" COMMUNICATIONS" on advertising, endorsements, or otherwise except as -.\" such appears in the above copyright notice or in the software. -.\" -.\" THIS SOFTWARE IS BEING PROVIDED BY WHISTLE COMMUNICATIONS "AS IS", AND -.\" TO THE MAXIMUM EXTENT PERMITTED BY LAW, WHISTLE COMMUNICATIONS MAKES NO -.\" REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, REGARDING THIS SOFTWARE, -.\" INCLUDING WITHOUT LIMITATION, ANY AND ALL IMPLIED WARRANTIES OF -.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT. -.\" WHISTLE COMMUNICATIONS DOES NOT WARRANT, GUARANTEE, OR MAKE ANY -.\" REPRESENTATIONS REGARDING THE USE OF, OR THE RESULTS OF THE USE OF THIS -.\" SOFTWARE IN TERMS OF ITS CORRECTNESS, ACCURACY, RELIABILITY OR OTHERWISE. -.\" IN NO EVENT SHALL WHISTLE COMMUNICATIONS BE LIABLE FOR ANY DAMAGES -.\" RESULTING FROM OR ARISING OUT OF ANY USE OF THIS SOFTWARE, INCLUDING -.\" WITHOUT LIMITATION, ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, -.\" PUNITIVE, OR CONSEQUENTIAL DAMAGES, PROCUREMENT OF SUBSTITUTE GOODS OR -.\" SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER ANY -.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF -.\" THIS SOFTWARE, EVEN IF WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY -.\" OF SUCH DAMAGE. -.\" -.\" Author: Archie Cobbs <archie@whistle.com> -.\" -.\" $FreeBSD$ -.\" -.Dd November 15, 1999 -.Dt NG_KSOCKET 8 -.Os FreeBSD -.Sh NAME -.Nm ng_ksocket -.Nd kernel socket netgraph node type -.Sh SYNOPSIS -.Fd #include <netgraph/ng_ksocket.h> -.Sh DESCRIPTION -A -.Nm ksocket -node is both a netgraph node and a BSD socket. The -.Nm -node type allows one to open a socket inside the kernel and have -it appear as a Netgraph node. The -.Nm -node type is the reverse of the socket node type (see -.Xr ng_socket 8 ) : -whereas the socket node type enables the user-level manipulation (via -a socket) of what is normally a kernel-level entity (the associated -Netgraph node), the -.Nm -node type enables the kernel-level manipulation (via a Netgraph node) of -what is normally a user-level entity (the associated socket). -.Pp -A -.Nm -node allows at most one hook connection. Connecting to the node is -equivalent to opening the associated socket. The name given to the hook -determines what kind of socket the node will open (see below). -When the hook is disconnected and/or the node is shutdown, the -associated socket is closed. -.Sh HOOKS -This node type supports a single hook connection at a time. -The name of the hook must be of the form -.Dv Em <family>/<type>/<proto> , -where the -.Dv Em family , -.Dv Em type , -and -.Dv Em proto -are the decimal equivalent of the same arguments to -.Xr socket 2 . -Alternately, aliases for the commonly used values are accepted as -well. For example -.Dv inet/dgram/udp -is a more readable but equivalent version of -.Dv 2/2/17 . -.Sh CONTROL MESSAGES -This node type supports the generic control messages, plus the following: -.Bl -tag -width foo -.It Dv NGM_KSOCKET_BIND -This functions exactly like the -.Xr bind 2 -system call. The -.Dv "struct sockaddr" -socket address parameter should be supplied as an argument. -.It Dv NGM_KSOCKET_LISTEN -This functions exactly like the -.Xr listen 2 -system call. The backlog paramter (a single 32 bit -.Dv int ) -should be supplied as an argument. -.It Dv NGM_KSOCKET_CONNECT -This functions exactly like the -.Xr connect 2 -system call. The -.Dv "struct sockaddr" -destination address parameter should be supplied as an argument. -.It Dv NGM_KSOCKET_ACCEPT -Currently unimplemented. -.It Dv NGM_KSOCKET_GETNAME -Equivalent to the -.Xr getname 2 -system call. The name is returned as a -.Dv "struct sockaddr" -in the arguments field of the reply. -.It Dv NGM_KSOCKET_GETPEERNAME -Equivalent to the -.Xr getpeername 2 -system call. The name is returned as a -.Dv "struct sockaddr" -in the arguments field of the reply. -.It Dv NGM_KSOCKET_SETOPT -Equivalent to the -.Xr setsockopt 2 -system call, except that the option name, level, and value are passed in a -.Dv "struct ng_ksocket_sockopt" . -.It Dv NGM_KSOCKET_GETOPT -Equivalent to the -.Xr getsockopt 2 -system call, except that the option is passed in a -.Dv "struct ng_ksocket_sockopt" . -When sending this command, the -.Dv value -field should be empty; upon return, it will contain the -retrieved value. -.El -.Pp -.Sh ASCII FORM CONTROL MESSAGES -For control messages that pass a -.Dv "struct sockaddr" -in the argument field, the normal -.Tn ASCII -equivalent of the C structure -is an acceptable form. For the -.Dv PF_INET -and -.Dv PF_LOCAL -address families, a more convenient form is also used, which is -the protocol family name, followed by a slash, followed by the actual -address. For -.Dv PF_INET , -the address is an IP address followed by an optional colon and port number. -For -.Dv PF_LOCAL , -the address is the pathname as a doubly quoted string. -.Pp -Examples: -.Bl -tag -width XXXXXXXXXX -.It Dv PF_LOCAL -local/"/tmp/foo.socket" -.It Dv PF_INET -inet/192.168.1.1:1234 -.It Other -.Dv "\&{ family=16 len=16 data=[0x70 0x00 0x01 0x23] \&}" -.El -.Pp -For control messages that pass a -.Dv "struct ng_ksocket_sockopt" , -the normal -.Tn ASCII -form for that structure is used. In the future, more -convenient encoding of the more common socket options may be supported. -.Sh SHUTDOWN -This node shuts down upon receipt of a -.Dv NGM_SHUTDOWN -control message, or when the hook is disconnected. -Shutdown of the node closes the associated socket. -.Sh SEE ALSO -.Xr socket 2 , -.Xr netgraph 4 , -.Xr ng_socket 8 , -.Xr ngctl 8 . -.Sh HISTORY -The -.Nm -node type was implemented in -.Fx 4.0 . -.Sh AUTHORS -.An Archie Cobbs Aq archie@whistle.com |