soconfig - configure transport providers for use by sockets soconfig



  • System Administration Commands					  soconfig(1M)
    
    
    
    NAME
           soconfig	- configure transport providers	for use	by sockets
    
    SYNOPSIS
           /usr/sbin/soconfig -d dir
    
    
           /usr/sbin/soconfig -f file
    
    
           /usr/sbin/soconfig -F name [[-h hint] [-m modname]
    	    -t family:type:protocol[,...]]
    
    
           /usr/sbin/soconfig family type protocol [module | path]
    
    
           /usr/sbin/soconfig -l [-np]
    
    
    DESCRIPTION
           The  soconfig  utility configures the transport provider	driver for use
           with sockets. It	specifies how the family, type,	and  protocol  parame-
           ters  in	the socket(3SOCKET) call are mapped to the name	of a transport
           provider	such as	/dev/tcp. This utility can be used  to	add  an	 addi-
           tional mapping or remove	a previous mapping.
    
    
           The soconfig utility is also used to configure socket filters.
    
    
           The  init(1M) utility uses soconfig with	the sock2path.d(4) file	during
           the booting sequence.
    
    OPTIONS
           The following options are supported:
    
           -d dir
    
    	   Set up the soconfig configuration for each driver according to  the
    	   information stored in the files in dir.
    
    
           -f file
    
    	   Set	up the soconfig	configuration for each driver according	to the
    	   information stored in file. A soconfig file consists	of lines of at
    	   least the first three fields	listed below, separated	by spaces:
    
    	   family  type	 protocol [module | path]
    
    	   These fields	are described in the OPERANDS section below.
    
    	   An example of file can be found in the EXAMPLES section below.
    
    
           -F name [[-h hint] [-m modname] -t family:type:protocol[,...]]
    
    	   Update  socket filter configuration.	If only	the name is specified,
    	   then	the filter is unconfigured. Otherwise, the filter will be con-
    	   figured.
    
    	   The following are options associated	with the -F option.
    
    	   -h hint
    
    	       Placement  hint for the filter. If the placement	cannot be sat-
    	       isfied, then the	configuration request will fail. The hint  can
    	       be one of the following:
    
    	       top
    
    		   The filter should be	placed on top, closest to the socket.
    
    
    	       bottom
    
    		   The	filter	should be placed on the	bottom,	closest	to the
    		   protocol.
    
    
    	       above:name
    
    		   The filter should be	placed above the filter	 specified  by
    		   name. The filter will lie closer to the socket than name.
    
    
    	       below:name
    
    		   The	filter	should be placed below the filter specified by
    		   name. The filter will lie closer to the socket than name.
    
    
    
    	   -m modname
    
    	       Name of the filter module. The module must be  located  in  the
    	       socketmod  namespace.  If  unspecified, then the	module name is
    	       expected	to be the same as the filter name.
    
    
    	   -t family:type:protocol[,...]
    
    	       Socket tuple for	the filter. The	fields making up the tuple are
    	       described  in the OPERANDS section. The configuration will fail
    	       if any of the socket tuples refer  to  a	 socket	 that  uses  a
    	       transport  provider  that  does	not  support  socket  filters.
    	       STREAMS-based transport providers are not supported  by	socket
    	       filters.
    
    
    
           -l [-np]
    
    	   Dump	 the in-kernel socket configuration table. This	option has the
    	   following suboptions:
    
    	   -n
    
    	       Do not convert socket family, type, and protocol	to string rep-
    	       resentation.
    
    
    	   -p
    
    	       Display machine-parseable output.
    
    
    
    OPERANDS
           The following operands are supported:
    
           family
    
    	   The	protocol  family  as  listed  in the /usr/include/sys/socket.h
    	   file, expressed as an integer. This file is contained in  the  sys-
    	   tem/header package, which might not be part of your Solaris distri-
    	   bution.
    
    
           type
    
    	   The socket type as listed in	 the  /usr/include/sys/socket.h	 file,
    	   expressed  as  an  integer.	This  file  is	contained  in the sys-
    	   tem/header package, which might not be part of your Solaris distri-
    	   bution.
    
    
           protocol
    
    	   The	protocol  number  as  specified	in the family-specific include
    	   file, expressed as an integer. For example, for AF_INET this	number
    	   is  specified in /usr/include/netinet/in.h. An unspecified protocol
    	   number is denoted with the value zero.
    
    
           module |	path
    
    	   The module name or path name	of a device that  corresponds  to  the
    	   transport provider, such as tcp or /dev/tcp.	Modules	must reside in
    	   kernel/socketmod. A device name  must  begin	 with  /dev.  If  this
    	   parameter  is  specified,  the  configuration will be added for the
    	   specified family, type, and protocol.  If  this  parameter  is  not
    	   specified, the configuration	will be	removed.
    
    
    EXAMPLES
           Example 1 Setting Up a Module
    
    
           The  following  example	sets  up  a module for family AF_INET and type
           SOCK_STREAM:
    
    
    	 example# soconfig 2 2 0 tcp
    
    
    
    
           The following example sets up /dev/tcp  for  family  AF_INET  and  type
           SOCK_STREAM:
    
    
    	 example# soconfig 2 2 0 /dev/tcp
    
    
    
    
           The  following  is a sample file	used with the -f option. Comment lines
           begin with a hash mark (#):
    
    
    	 #   Family  Type  Protocol   Module | Path
    	       2       2       0	  tcp
    	       2       2       6	  tcp
    
    	       2       1       0	  udp
    	       2       1       17	  udp
    
    	       1       2       0	  /dev/ticotsord
    	       1       1       0	  /dev/ticlts
    
    	       2       4       0	  icmp
    
    
    
           Example 2 Configuring a Socket Filter
    
    
           The following command configures	a socket filter, foo,  which  has  the
           loadable	module named foomod. The filter	will automatically be attached
           to all AF_INET TCP sockets.
    
    
    	 example# soconfig -F foo -m foomod -t 2:2:0,2:2:6
    
    
    
    
           The following command unconfigures the filter foo.
    
    
    	 example# soconfig -F foo
    
    
    
    FILES
           /etc/sock2path.d
    
    	   Directory containing	files with mappings from sockets to  transport
    	   providers.
    
    
    ATTRIBUTES
           See attributes(5) for descriptions of the following attributes:
    
    
    
    
           +-----------------------------+-----------------------------+
           |      ATTRIBUTE	TYPE	     |	    ATTRIBUTE VALUE	   |
           +-----------------------------+-----------------------------+
           |Availability		     |system/core-os		   |
           +-----------------------------+-----------------------------+
    
    SEE ALSO
           init(1M), sock2path.d(4), attributes(5)
    
    
           Oracle Solaris 11.2 Programming Interfaces Guide
    
    
    
    SunOS 5.11			  3 May	2012			  soconfig(1M)
    


© Lightnetics 2024