setsockopt

Jump to: navigation, search

Table of Contents >> Programmer's Reference


#include <trsocket.h>


int setsockopt (
int socketDescriptor,
int protocolLevel,
int optionName,
const char * optionValue,
int optionLength
);


Function Description

setsockopt() is used manipulate options associated with a socket. Options may exist at multiple protocol levels; they are always present at the uppermost socket level. When manipulating socket options, the level at which the option resides and the name of the option must be specified. To manipulate options at the socket level, protocolLevel is specified as SOL_SOCKET. To manipulate options at any other level, protocolLevel is the protocol number of the protocol that controls the option. For example, to indicate that an option is to be interpreted by the TCP protocol, protocolLevel is set to the TCP protocol number. The parameters optionValuePtr and optionlength are used to access option values for setsockopt(). optionName and any specified options are passed un-interpreted to the appropriate protocol module for interpretation. The include file <trsocket.h> contains definitions for the options described below. Most socket-level options take an (int *) for optionValuePtr. For setsockopt(), the integer value pointed to by the optionValuePtr parameter should be non-zero to enable a boolean option, or zero if the option is to be disabled. SO_LINGER uses a struct linger parameter that specifies the desired state of the option and the linger interval.

#include <trsocket.h>
 
/*
 * Structure used for manipulating linger option.
 */
struct linger
{
    int l_onoff;        /* option on/off; 1=>on, 0=>off */
    int l_linger;       /* linger time */
};


Parameters

  • socketDescriptor
    The socket descriptor to set the options on.
  • protocolLevel
    The protocol to set the option on (see below).
  • optionName
    The name of the option to set (see below).
  • optionValue
    A pointer to a user variable from which the option value is set. User variable is of data type described below.
  • optionLength
    The size of the user variable. It is the size of the option data type (see below).


Returns

  • TM_ENOERROR
    Success
  • TM_SOCKET_ERROR
    Failure


Note Note: TM_SOCKET_ERROR means that this socket call has failed and the errorCode has been set on the socket itself.

To retrieve the socket error the user must call tfGetSocketError(socketDescriptor).


Possible socket errors

  • TM_EBADF
    The socket descriptor is invalid.
  • TM_EINVAL
    One of the parameters is invalid.
  • TM_ENOPROTOOPT
    The option is unknown at the level indicated.
  • TM_EPERM
    The option cannot be set after the connection has been established and the IPO_HDRINCL option cannot be set on non-raw sockets.
  • TM_ENETDOWN
    The specified interface is not yet configured.
  • TM_EADDRINUSE
    The multicast host group has already been added to the interface.
  • TM_ENOBUFS
    Insufficient memory to complete the operation.
  • TM_ENOENT
    Cannont delete the multicast entry because it does not exist on the specified interface.




Socket Level Options

The following options are recognized at the socket level:

SOL_SOCKET

protocolLevel Options Data Type Description
SO_BINDTODEVICE string The device name, as set with tfAddInterface(), will be stored as a null-terminated string in the buffer pointed to by optionValuePtr. A pointer to the size of the buffer must be passed in optionLengthPtr. The name can have a maximum length of IFNAMSIZ. If the buffer is too small to hold the full name, the name will be truncated. *optionLengthPtr will be set to the length of the returned string. If the socket is not bound to a device, both *optionLengthPtr and *optionValPtr will be set to 0.
SO_DONTROUTE int Enable/disable routing bypass for outgoing messages.

Default 0.

SO_ERROR int Retrieve the socket error. This option is for getsockopt() only!
SO_KEEPALIVE int Enable/disable keep connections alive.

Default 0 (disable).

SO_LINGER linger Linger on close if data is present.

Default ON with a linger time of 60 seconds.

SO_OOBINLINE int Enable/disable reception of out-of-band data in band.

Default is 0.

SO_RCVBUF unsigned long The buffer size for input.

Default is 8192 bytes.

SO_RCVLOWAT unsigned long The low water mark for receiving in bytes.

Default value is 1.

SO_REUSEADDR int Enable this socket option to bind the same port number to multiple sockets using different local IP addresses. Note that to use this socket option you also need to uncomment TM_USE_REUSEADDR_LIST in <trsystem.h>.

Default 0 (disable).

SO_REUSEPORT int Enable this socket option to bind the same local IP address and port to multiple sockets. If multiple UDP sockets have the SO_REUSEPORT option set, then those sockets can bind to the same local IP address, and local UDP port. This is useful for multicast sockets that should all receive the same UDP multicast datagram. If multiple TCP sockets have the SO_REUSEPORT option set, then those sockets can bind to the same local IP address, and local TCP port. So we could have a listening socket, and a socket yet to be connected bound to the same local IP address, and local TCP port. Of course connected sockets would not be allowed to have the same 4-tuple, local IP address, local TCP port, remote IP address, remote TCP port, as that 4-tuple has to be unique for each connected TCP socket. Note that to use this socket option you also need to uncomment TM_USE_REUSEPORT in <trsystem.h>.

Default 0 (disable).

SO_SNDBUF unsigned long The buffer size for output.

Default is 8192 bytes.

SO_SNDLOWAT unsigned long The low water mark for sending in bytes.

Default value is 2048.

TM_SO_RCVCOPY unsigned int TCP socket: fraction use of a receive buffer below which we try and append to a previous receive buffer in the socket receive queue.

UDP socket: fraction use of a receive buffer below which we try and copy to a new receive buffer, if there is already at least a buffer in the receive queue. This is to avoid keeping large pre-allocated receive buffers, which the user has not received yet, in the socket receive queue.

Default value is 4 (25%).

TM_SO_SNDAPPEND unsigned int TCP socket only. Threshold in bytes of send buffer below, which we try and append to the previous send buffer in the TCP send queue. Only used with send(), not with tfZeroCopySend(). This is to try to regroup many partially empty small buffers in the TCP send queue waiting to be ACKED by the peer; otherwise we could run out of memory since the remote TCP will delay sending ACKs. Note that care should be taken not to use tfZeroCopySend() API when sending small buffers since we do not try to regroup small buffers with tfZeroCopySend().

Default value is 128 bytes.

TM_SO_SND_DGRAMS unsigned int The number of non-TCP datagrams that can be queued for send on a socket.

Default is 8 datagrams.

TM_SO_RCV_DGRAMS unsigned int The number of non-TCP datagrams that can be queued for receive on a socket.

Default is 8 datagrams.

SO_UNPACKEDDATA int TI C3x and C5x DSP platforms only. If this option is enabled, all socket data will be sent and received in byte unpacked format. If this option is disabled, all socket data will be sent in a byte packed format, as received from the network.

Default 0 (disable)

  • SO_REUSEADDR indicates that the rules used in validating addresses supplied in a bind() call should allow reuse of local addresses.
  • SO_KEEPALIVE enables the periodic transmission of messages (every 2 hours) on a connected socket. If the connected party fails to respond to these messages, the connection is considered broken.
  • SO_DONTROUTE indicates that outgoing messages should bypass the standard routing facilities. Instead, messages are directed to the appropriate network interface according to the network portion of the destination address.
  • SO_LINGER controls the action taken when unsent messages are queued on a socket and a close on the socket is performed. If the socket promises reliable delivery of data and SO_LINGER is set, the system will block the process on the close of the socket attempt until it is able to transmit the data or until it decides it is unable to deliver the information (a timeout period, termed the linger interval, is specified in the setsockopt() call when SO_LINGER is requested). If SO_LINGER is disabled and a close on the socket is issued, the system will process the close of the socket in a manner that allows the process to continue as quickly as possible.
  • The option SO_BROADCAST requests permission to send broadcast datagrams on the socket.
  • With protocols that support out-of-band data, the SO_OOBINLINE option requests that out-of-band data be placed in the normal data input queue as received; it will then be accessible with recv() call without the MSG_OOB flag.
  • SO_SNDBUF and SO_RCVBUF are options that adjust the normal buffer sizes allocated for output and input buffers, respectively. The buffer size may be increased for high volume connections or may be decreased to limit the possible backlog of incoming data. The Internet protocols place an absolute limit of 64 Kbytes on these values for UDP and TCP sockets (in the default mode of operation).
  • Treck allows multiple matching UDP sockets (which have set the SO_REUSEADDR, or SO_REUSEPORT option) to receive copies of the same multicast/broadcast datagram.
  • TM_USE_REUSEADDR_LIST needs to be defined to allow multiple sockets with different local IP addresses to share the same local UDP port. Also each socket has to have the SO_REUSEADDR option set.
  • TM_USE_REUSEPORT needs to be defined to allow multiple sockets with the same local IP address to share the same local UDP port. Also each socket has to have the SO_REUSEPORT option set.

IP Level Options

The following options are recognized at the IP level:

IP_PROTOIP

protocolLevel Options Data Type Description
IPO_HDRINCL int This is a toggle option used on raw sockets only. If the value is non-zero, it instructs the Treck stack that the user is including the IP header when sending data.

Default 0

IPO_RCV_TOS unsigned char Received IP type of service on the connection (from the last IP datagram arrived on the connection.)
IPO_TOS unsigned char IP type of service.

Default 0

IPO_TTL unsigned char IP Time To Live in seconds.

Default 64

IPO_SRCADDR ttUserIpAddress Set the IP source address for the connection.

Default: The first multi-home IP address on the outgoing interface

IPO_MULTICAST_TTL unsigned char Change the default IP TTL for outgoing multicast datagrams.
IPO_MULTICAST_IF in_addr Specify a configured IP address that will uniquely identify the outgoing interface for multicast datagrams sent on this socket. A zero IP address parameter indicates that we want to reset a previously set outgoing interface for multicast packets sent on that socket.
IPO_ADD_MEMBERSHIP ip_mreq Add group multicast IP address to given interface (see struct ip_mreq data type).
IPO_DROP_MEMBERSHIP ip_mreq Delete group multicast IP address to given interface (see struct ip_mreq data type).
IP_BLOCK_SOURCE ip_mreq_source Block data from a given source to a given multicast group (mute) (see struct ip_mreq_source data type).
IP_UNBLOCK_SOURCE ip_mreq_source Unblock data from a given source to a given multicast group (un-mute) (see struct ip_mreq_source data type).
IP_ADD_SOURCE_MEMBERSHIP ip_mreq_source Join a source-specific group (see struct ip_mreq_source data type).
IP_DROP_SOURCE_MEMBERSHIP ip_mreq_source Leave a source-specific group (see struct ip_mreq_source data type).
MCAST_JOIN_GROUP group_req Add group multicast IP address to given interface (see struct group_req data type). This option also supports IPPROTO_IPV6.
MCAST_LEAVE_GROUP group_req Delete group multicast IP address to given interface (see struct group_req data type). This option also supports IPPROTO_IPV6.
MCAST_BLOCK_SOURCE group_source_req Block data from a given source to a given multicast group (mute) (see struct group_source_req data type). This option also supports IPPROTO_IPV6.
MCAST_UNBLOCK_SOURCE group_source_req Unblock data from a given source to a given multicast group (un-mute) (see struct group_source_req data type). This option also supports IPPROTO_IPV6.
MCAST_JOIN_SOURCE_GROUP group_source_req Join a source-specific group (see struct group_source_req data type). This option also supports IPPROTO_IPV6.
MCAST_LEAVE_SOURCE_GROUP group_source_req Leave a source-specific group (see struct group_source_req data type). This option also supports IPPROTO_IPV6.
IP_RCV_TOS unsigned char Retrieve the IP header TOS from a packet on a TCP connection, after the TCP connection has been established.

IPv6 Level Options

The following options are recognized at the IPv6 level:

IPPROTO_IPV6

protocolLevel Options Data Type Description
IPV6_V6ONLY int Force the socket to be IPv6-only. Normally, when running with both TM_USE_IPV4 and TM_USE_IPV6 defined, a socket created with AF_INET6 is able to communicate via both IPv4 and IPv6. Setting this socket option forces the socket to communicate via IPv6 only.
IPV6_JOIN_GROUP ipv6_mreq Join an IPv6 multicast group (see struct ipv6_mreq data type).
IPV6_LEAVE_GROUP ipv6_mreq Leave an IPv6 multicast group (see struct ipv6_mreq data type).
MCAST_JOIN_GROUP group_req Join an IPv6 multicast group (see struct group_req data type). This option also supports IPPROTO_IP.
MCAST_LEAVE_GROUP group_req Leave an IPv6 multicast group (see struct group_req data type). This option also supports IPPROTO_IP.
MCAST_BLOCK_SOURCE group_source_req Block data from a given source to a given IPv6 multicast group (mute) (see struct group_source_req data type). This option also supports IPPROTO_IP.
MCAST_UNBLOCK_SOURCE group_source_req Unblock data from a given source to a given IPv6 multicast group (un-mute) (see struct group_source_req data type). This option also supports IPPROTO_IP.
MCAST_JOIN_SOURCE_GROUP group_source_req Join a source-specific IPv6 group (see struct group_source_req data type). This option also supports IPPROTO_IP.
MCAST_LEAVE_SOURCE_GROUP group_source_req Leave a source-specific IPv6 group (see struct group_source_req data type). This option also supports IPPROTO_IP.
IPV6_MULTICAST_HOPS unsigned int This option allows the user to set the hop limit field in the IPv6 header for multicast packets sent via this socket.

Default 1

IPV6_MULTICAST_IF int Specify the interface index of the outgoing interface for multicast datagrams sent on this socket. An interface index of 0 indicates that we want to reset a previously set outgoing interface for multicast packets sent on this socket.
IPV6_UNITCAST_HOPS int This option allows the user to set the hop limit field in the IPv6 header for unicast packets sent via this socket.

TCP Level Options

The following options are recognized at the TCP level:

IP_PROTOTCP

protocolLevel Options Data Type Description
TCP_KEEPALIVE int Sets the idle time in seconds for a TCP connection before it starts sending keep alive probes. Note that keep alive probes will be sent only if the SO_KEEPALIVE socket option is enabled.

Default 7,200 seconds.

TCP_MAXRT int Sets the amount of time in seconds before the connection is broken once TCP starts retransmitting, or probing a zero window when the peer does not respond. A TCP_MAXRT value of 0 means the system default, and -1 means retransmit forever. If a positive value is specified, it may be rounded up to the connection next retransmission time. Note that unless the TCP_MAXRT value is -1 (transmit forever), the connection can also be broken if the number of maximum retransmission TM_TCP_MAX_REXMIT has been reached. See TM_TCP_MAX_REXMIT below.

Default 0. Meaning: use the system default of TM_TCP_MAX_REXMIT times network computed round trip time for an established connection. For a non-established connection, since there is no computed round trip time yet, the connection can be broken when either 75 seconds or when TM_TCP_MAX_REXMIT times default network round trip time have elapsed, whichever occurs first).

TCP_MAXSEG int Sets the maximum TCP segment size sent on the network. Note that the TCP_MAXSEG value is the maximum amount of data (including TCP options, but not the TCP header) that can be sent per segment to the peer. This means that the amount of user data sent per segment is the value given by the TCP_MAXSEG option minus any enabled TCP option (for example 12 bytes for a TCP time stamp option). The TCP_MAXSEG value can be decreased or increased prior to a connection establishment, but it is not recommended to set it to a value higher than the IP MTU minus 40 bytes (for example 1460 bytes on Ethernet), since this would cause fragmentation of TCP segments. Note: setting the TCP_MAXSEG option will inhibit the automatic computation of that value by the system based on the IP MTU (which avoids fragmentation), and will also inhibit Path MTU Discovery. After the connection has started, this value cannot be changed. Note also that the TCP_MAXSEG value cannot be set below 64 bytes. Default value is IP MTU minus 40 bytes.

Default is IP MTU minus 40 bytes.

TCP_NODELAY int Set this option value to a non-zero value, to disable the Nagle algorithm that buffers the sent data inside the TCP. Useful to allow client's TCP to send small packets as soon as possible (like mouse clicks).

Default 0.

TCP_NOPUSH int Set this option value to a non-zero value, to force TCP to delay sending any TCP data until a full sized segment is buffered in the TCP buffers. Useful for applications that send continuous big chunks of data like FTP, and know that more data is coming. (Normally the TCP code sends a non full-sized segment, only if it empties the TCP buffer).

Default 0.

TCP_STDURG int Set this option value to a zero value if the peer is a Berkeley system since Berkeley systems set the urgent data pointer to point to last byte of urgent data+1.

Default 1 (urgent pointer points to last byte of urgent data as specified in RFC 1122).

TM_TCP_2MSLTIME int Sets the maximum amount of time TCP will wait in the TIME WAIT state, once it has initiated a close of the connection.

Default 60 seconds.

TM_TCP_DELAY_ACK int Sets the TCP delay ack time in milliseconds.

Default 200 milliseconds.

TM_TCP_FINWT2TIME int Sets the maximum amount of time TCP will wait for the remote side to close, after it initiated a close.

Default 600 seconds.

TM_TCP_KEEPALIVE_CNT int Sets the maximum numbers of keep alive probes without any response from the remote, before TCP gives up and aborts the connection. See also TCP_KEEPALIVE.

Default 8.

TM_TCP_KEEPALIVE_INTV int Sets the interval between Keep Alive probes in seconds. See TM_TCP_KEEPALIVE_CNT. This value cannot be changed after a connection is established, and cannot be bigger than 120 seconds.

Default 75 seconds.

TM_TCP_MAX_REXMIT int Sets the maximum number of retransmissions without any response from the remote, before TCP gives up and aborts the connection. See also TCP_MAXRT.

Default 12.

TM_TCP_PACKET int Set this option value to a non-zero value to make TCP behave like a message-oriented protocol (i.e. respect packet boundaries) at the application level in both send and receive directions of data transfer. Note that for the receive direction to respect packet boundaries, the TCP peer which is sending must also implement similar functionality in its send direction. This is useful as a reliable alternative to UDP. Note that preserving packet boundaries with TCP will not work correctly if you use out-of-band data. TM_USE_TCP_PACKET must be defined in <trsystem.h> to use the TM_TCP_PACKET option.

Default 0.

TM_TCP_PEND_ACCEPT_RECV_WND unsigned long Specify the size (in bytes) of the listening socket's receive window. This size will override the default size or the size specified by setsockopt() with the SO_RCVBUF flag. Once accept() is called on the listening socket, the window size will return to the size specified by SO_RCVBUF (or the default). Note: This size may not be larger than the default window size to avoid shrinking of the receive window.
TM_TCP_PROBE_MAX unsigned long Sets the maximum window probe timeout interval in milliseconds. The network computed window probe timeout is bound by TM_TCP_PROBE_MIN and TM_TCP_PROBE_MAX.

Default 60,000 milliseconds.

TM_TCP_PROBE_MIN unsigned long Sets the minimum window probe timeout interval in milliseconds. The network computed window probe timeout is bound by TM_TCP_PROBE_MIN and TM_TCP_PROBE_MAX.

Default 500 milliseconds.

TM_TCP_PURE_ACK_SEGS int Option only available if TM_USE_TCP_PURE_ACK is deined. Sets the number of outstanding un-ACKed segments, before a pure ACK is sent (even if the recv window has not changed.) Default value is zero, in which case the stack will behave as if TM_USE_TCP_PURE_ACK had not been defined, and will only ACK every other segment provided that it is combined with a window update, or will ACK when the delay ACK timer expires regardless of the window update.

Default 0.

TM_TCP_REXMIT_CONTROL int Dynamically modify the behavior of the TCP retransmission timer for the specified socket. Valid values are 1 (Pause), 2 (Resume), and 3 (Reset). TM_USE_TCP_REXMIT_CONTROL must be defined in <trsystem.h> to make this option available. See the "Dynamically Control the TCP Retransmission Timer" section for more information.
TM_TCP_RTO_DEF unsigned long Sets the TCP default retransmission timeout value in milliseconds, used when no network round trip time has been computed yet.

Default 3,000 milliseconds.

TM_TCP_RTO_MAX unsigned long Sets the maximum retransmission timeout in milliseconds. The network computed retransmission timeout is bound by TM_TCP_RTO_MIN and TM_RTO_MAX.

Default 64,000 milliseconds.

TM_TCP_RTO_MIN unsigned long Sets the minimum retransmission timeout in milliseconds. The network computed retransmission timeout is bound by TM_TCP_RTO_MIN and TM_TCP_RTO_MAX.

Default 100 milliseconds.

TM_TCP_SEL_ACK int Set this option value to a non-zero value to enable sending the TCP selective Acknowledgment option.

Note: This option can only be changed prior to establishing a TCP connection.

Default 1.

TM_TCP_SLOW_START int Set this option value to zero, to disable the TCP slow start algorithm.

Default 1.

TM_TCP_SSL_CLIENT int Set this option to enable SSL client negotiation on this socket, optionLength must be sizeof(int), any non-zero value will enable SSL client
TM_TCP_SSL_SERVER int Set this option to enable SSL server negotiation on this socket, optionLength must be sizeof(int), any non-zero value will enable SSL server. Note that, if you set this option for a listening socket, all accepted sockets inherit this option value, you don’t have to set this option again on an accepted socket.
TM_TCP_SSLSESSION int Set the SSL session Id for this socket. The option length must be sizeof(int). Note that, if you set this option for a listening socket, all accepted sockets inherit this option value, you don’t have to set this option again on an accepted socket
TM_TCP_SSL_SEND_MIN_SIZE int Set the SSL send minimum size. If user's send data is less than this value, user data will be queued. Option length must be sizeof(int), and option value can not greater than 0xffff. Don’t set this value too big.

Default value is defined as macro TM_SSL_SEND_DATA_MIN_SIZE (0)

TM_TCP_SSL_SEND_MAX_SIZE int Set the SSL record maximum size. Each record will at most have that much user data encapsulated. User data bigger than this size limit will be cut into two records, Option length must be sizeof(int), and option value can not greater than 0x4000 to enable reasonable encapsulate. Don’t set this value too small. (<100 value will be rejected)

Default value is defined as macro TM_SSL_SEND_DATA_MAX_SIZE (8000).

TM_TCP_TS int Set this option value to a non-zero value to enable sending the Time stamp option.

Note: This option can only be changed prior to establishing a TCP connection.

Default 1.

TM_TCP_WND_SCALE int Set this option value to a non-zero value to enable sending the TCP window scale option.

Note: This option can only be changed prior to establishing a TCP connection.

Default 1.

TM_TCP_STATE int Get the state of the TCP vector associated with the socket.

Note: Read only value.

TM_TCP_USER_PARAM ttUserGenericUnion Use this option to set/get user data for a specific TCP socket. To enable this feature, uncomment the TM_USE_USER_PARAM macro definition in your <trsystem.h>.
TM_TCP_CA_HYBLA int Set this option value to 1, to switch to the TCP Hybla Congestion Avoidance Algorithm. The TCP Hybla algorithm yields better performance for TCP connections with a long round trip time (such as on a high-latency terrestrial or satellite radio link). Set this option value to 0, to switch back to the TCP Reno Congestion Avoidance Algorithm. See Configuring TCP Congestion Avoidance Algorithm for more details.

Default 0.

TM_TCP_PACING int Set this option value to 1, to turn on TCP Pacing. With TCP Pacing turned on, the stack will attempt to send TCP segments within the congestion window and peer receive window over the Round Trip Time, instead of sending them all at once. For better performance, this option should be turned on, if the TCP HYBLA algorithm is switched on. Set this option value to 0, to turn off TCP Pacing. See Configuring TCP Congestion Avoidance Algorithm for more details.

Default 0.

TM_TCP_CA_WESTOOD int Set this option value to 1, to switch to the TCP Westwood+ Congestion Avoidance Algorithm. The TCP Westwood+ algorithm yields better performance on TCP connections over wireless lossy links. Set this option value to 0, to switch back to the TCP Reno Congestion Avoidance Algorithm. See Configuring TCP Congestion Avoidance Algorithm for more details.

Default 0.

SCTP Level Options

The following options are recognized at the SCTP level:

IPPROTO_SCTP

protocolLevel Options Data Type Description
SCTP_ADD_PATH struct sctp_setpath Add a new set of local and remote IP addresses to an existing SCTP connection, as defined by the sctp_setpath structure contents. Multiple routes between hosts is an inherent part of SCTP for failover support. This option implements the Dynamic Address Reconfiguration (ADD-IP) extension as described in RFC 5061. By default, Dynamic Address Reconfiguration is not supported. You must define TM_SCTP_ADDIP_ENABLE in your <trsystem.h> to use this option.
SCTP_DELETE_PATH struct sctp_setpath Remove an existing set of local and remote IP addresses from a SCTP connection, as defined by the sctp_setpath structure contents. Multiple routes between hosts is an inherent part of SCTP for failover support. This option implements the Dynamic Address Reconfiguration (ADD-IP) extension as described in RFC 5061. By default, Dynamic Address Reconfiguration is not supported. You must define TM_SCTP_ADDIP_ENABLE in your <trsystem.h> to use this option.
SCTP_SET_PEER_PRIMARY_ADDR struct sctp_setpath Identify an existing set of local and remote IP addresses for a SCTP connection as the primary path. The primary path is the favored route to use when it is not broken. By default, the path used during the initial connection to the remote host is the primary path. You must define TM_SCTP_ADDIP_ENABLE in your <trsystem.h> to use this option.
SCTP_AUTH_KEY struct sctp_authkey Set a shared key for use in authenticating data sent to and received from a SCTP remote endpoint. This option implements the Authenticated Chunks extension as described in RFC 4895. By default, the Authenticated Chunks support is not enabled. You must define TM_SCTP_AUTH_ENABLE in your <trsystem.h> to use this option.


Table of Contents >> Programmer's Reference