1.\" Copyright (c) 1983, 1991, 1993 2.\" The Regents of the University of California. All rights reserved. 3.\" 4.\" Redistribution and use in source and binary forms, with or without 5.\" modification, are permitted provided that the following conditions 6.\" are met: 7.\" 1. Redistributions of source code must retain the above copyright 8.\" notice, this list of conditions and the following disclaimer. 9.\" 2. Redistributions in binary form must reproduce the above copyright 10.\" notice, this list of conditions and the following disclaimer in the 11.\" documentation and/or other materials provided with the distribution. 12.\" 3. All advertising materials mentioning features or use of this software 13.\" must display the following acknowledgement: 14.\" This product includes software developed by the University of 15.\" California, Berkeley and its contributors. 16.\" 4. Neither the name of the University nor the names of its contributors 17.\" may be used to endorse or promote products derived from this software 18.\" without specific prior written permission. 19.\" 20.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 21.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 22.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 23.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 24.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 25.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 26.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 27.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30.\" SUCH DAMAGE. 31.\" 32.\" From: @(#)send.2 8.2 (Berkeley) 2/21/94 33.\" $FreeBSD$ 34.\" 35.Dd December 15, 2006 36.Dt SCTP_OPT_INFO 3 37.Os 38.Sh NAME 39.Nm sctp_opt_info 40.Nd get sctp socket information 41.Sh LIBRARY 42.Lb libc 43.Sh SYNOPSIS 44.In sys/types.h 45.In sys/socket.h 46.In netinet/sctp.h 47.Ft int 48.Fn sctp_opt_info "int s" "sctp_assoc_t" "int opt" "void *arg" "socklen_t *size" 49.Sh DESCRIPTION 50The 51.Fn sctp_opt_info 52call provides a multi-os compatible method for getting 53specific 54.Fn getsockopt 55data where an association identification needs to be passed 56into the operating system. For FreeBSD a direct 57.Fn getsockopt 58may be used, since FreeBSD has the ability to pass information 59into the operating system on a 60.Fn getsockopt 61call. Other operating systems may not have this ability. For those 62who wish to write portable code amongst multiple operating system 63this call should be used for the for the following sctp 64socket options. 65.Pp 66.Dv SCTP_RTOINFO 67.Pp 68.Dv SCTP_ASSOCINFO 69.Pp 70.Dv SCTP_PRIMARY_ADDR 71.Pp 72.Dv SCTP_SET_PEER_PRIMARY_ADDR 73.Pp 74.Dv SCTP_STATUS 75.Pp 76.Dv SCTP_GET_PEER_ADDR_INFO 77.Pp 78.Dv SCTP_AUTH_ACTIVE_KEY 79.Pp 80.Dv SCTP_PEER_AUTH_CHUNKS 81.Pp 82.Dv SCTP_LOCAL_AUTH_CHUNKS 83.Sh ERRORS 84The 85.Fn sctp_opt_info 86can return the following errors. 87.Bl -tag -width Er 88.It Bq Er EINVAL 89The argument 90.Fa arg 91value was invalid. 92.It Bq Er EOPNOTSUPP 93The argument 94.Fa opt 95was not one of the above listed SCTP socket 96options. 97.It Bq Er EBADF 98The argument 99.Fa s 100is not a valid descriptor. 101.It Bq Er ENOTSOCK 102The argument 103.Fa s 104is not a socket. 105.El 106.Sh SEE ALSO 107.Xr sctp 4 , 108.Xr getsockopt 2 , 109 110