Skip Navigation Links | |
Exit Print View | |
man pages section 3: Networking Library Functions Oracle Solaris 11.1 Information Library |
DNSServiceConstructFullName(3DNS_SD)
DNSServiceCreateConnection(3DNS_SD)
DNSServiceEnumerateDomains(3DNS_SD)
DNSServiceProcessResult(3DNS_SD)
DNSServiceQueryRecord(3DNS_SD)
DNSServiceReconfirmRecord(3DNS_SD)
DNSServiceRefDeallocate(3DNS_SD)
DNSServiceRegisterRecord(3DNS_SD)
DNSServiceRemoveRecord(3DNS_SD)
DNSServiceUpdateRecord(3DNS_SD)
gss_create_empty_oid_set(3GSS)
gss_inquire_cred_by_mech(3GSS)
gss_inquire_mechs_for_name(3GSS)
gss_inquire_names_for_mech(3GSS)
gss_process_context_token(3GSS)
ldap_enable_translation(3LDAP)
ldap_get_entry_controls(3LDAP)
ldap_get_lang_values_len(3LDAP)
ldap_init_getfilter_buf(3LDAP)
ldap_init_searchprefs_buf(3LDAP)
ldap_init_templates_buf(3LDAP)
ldap_parse_extended_result(3LDAP)
ldap_parse_sasl_bind_result(3LDAP)
ldap_sasl_interactive_bind_s(3LDAP)
ldap_set_string_translators(3LDAP)
ldap_translate_from_t61(3LDAP)
rpc_gss_get_principal_name(3NSL)
rpc_gss_svc_max_data_length(3NSL)
sasl_auxprop_add_plugin(3SASL)
sasl_canonuser_add_plugin(3SASL)
sasl_client_plug_init_t(3SASL)
sasl_server_plug_init_t(3SASL)
sasl_server_userdb_checkpass_t(3SASL)
sasl_server_userdb_setpass_t(3SASL)
sdp_add_connection(3COMMPUTIL)
sdp_add_information(3COMMPUTIL)
sdp_delete_all_field(3COMMPUTIL)
sdp_delete_all_media_field(3COMMPUTIL)
sdp_delete_attribute(3COMMPUTIL)
sdp_find_attribute(3COMMPUTIL)
sdp_find_media_rtpmap(3COMMPUTIL)
sdp_session_to_str(3COMMPUTIL)
sip_create_dialog_req_nocontact(3SIP)
sip_delete_header_by_name(3SIP)
sip_disable_dialog_logging(3SIP)
sip_disable_trans_logging(3SIP)
sip_enable_dialog_logging(3SIP)
sip_enable_trans_logging(3SIP)
sip_get_contact_display_name(3SIP)
sip_get_content_sub_type(3SIP)
sip_get_dialog_local_contact_uri(3SIP)
sip_get_dialog_local_cseq(3SIP)
sip_get_dialog_local_tag(3SIP)
sip_get_dialog_local_uri(3SIP)
sip_get_dialog_remote_cseq(3SIP)
sip_get_dialog_remote_tag(3SIP)
sip_get_dialog_remote_target_uri(3SIP)
sip_get_dialog_remote_uri(3SIP)
sip_get_dialog_route_set(3SIP)
sip_get_from_display_name(3SIP)
sip_get_passertedid_display_name(3SIP)
sip_get_passertedid_uri_str(3SIP)
sip_get_ppreferredid_display_name(3SIP)
sip_get_ppreferredid_uri_str(3SIP)
sip_get_proxy_authen_param(3SIP)
sip_get_proxy_authen_scheme(3SIP)
sip_get_proxy_author_param(3SIP)
sip_get_proxy_author_scheme(3SIP)
sip_get_replyto_display_name(3SIP)
sip_get_retry_after_cmts(3SIP)
sip_get_retry_after_time(3SIP)
sip_get_route_display_name(3SIP)
sip_get_via_sent_by_host(3SIP)
sip_get_via_sent_by_port(3SIP)
sip_get_via_sent_protocol_name(3SIP)
sip_get_via_sent_protocol_version(3SIP)
sip_get_via_sent_transport(3SIP)
sip_get_www_authen_param(3SIP)
sip_get_www_authen_scheme(3SIP)
sip_unregister_all_sent_by(3SIP)
- accept a connection request
#include <xti.h> int t_accept(int fd, int resfd, const struct t_call *call);
This routine is part of the XTI interfaces that evolved from the TLI interfaces. XTI represents the future evolution of these interfaces. However, TLI interfaces are supported for compatibility. When using a TLI routine that has the same name as an XTI routine, a different header file, tiuser.h, must be used. Refer to the TLI COMPATIBILITY section for a description of differences between the two interfaces.
This function is issued by a transport user to accept a connection request. The parameter fd identifies the local transport endpoint where the connection indication arrived; resfd specifies the local transport endpoint where the connection is to be established, and call contains information required by the transport provider to complete the connection. The parameter call points to a t_call structure which contains the following members:
struct netbuf addr; struct netbuf opt; struct netbuf udata; int sequence;
In call, addr is the protocol address of the calling transport user, opt indicates any options associated with the connection, udata points to any user data to be returned to the caller, and sequence is the value returned by t_listen(3NSL) that uniquely associates the response with a previously received connection indication. The address of the caller, addr may be null (length zero). Where addr is not null then it may optionally be checked by XTI.
A transport user may accept a connection on either the same, or on a different, local transport endpoint than the one on which the connection indication arrived. Before the connection can be accepted on the same endpoint (resfd==fd), the user must have responded to any previous connection indications received on that transport endpoint by means of t_accept() or t_snddis(3NSL). Otherwise, t_accept() will fail and set t_errno to TINDOUT.
If a different transport endpoint is specified (resfd!=fd), then the user may or may not choose to bind the endpoint before the t_accept() is issued. If the endpoint is not bound prior to the t_accept(), the endpoint must be in the T_UNBND state before the t_accept() is issued, and the transport provider will automatically bind it to an address that is appropriate for the protocol concerned. If the transport user chooses to bind the endpoint it must be bound to a protocol address with a qlen of zero and must be in the T_IDLE state before the t_accept() is issued.
Responding endpoints should be supplied to t_accept() in the state T_UNBND.
The call to t_accept() may fail with t_errno set to TLOOK if there are indications (for example connect or disconnect) waiting to be received on endpoint fd. Applications should be prepared for such a failure.
The udata argument enables the called transport user to send user data to the caller and the amount of user data must not exceed the limits supported by the transport provider as returned in the connect field of the info argument of t_open(3NSL) or t_getinfo(3NSL). If the len field of udata is zero, no data will be sent to the caller. All the maxlen fields are meaningless.
When the user does not indicate any option (call→opt.len = 0) the connection shall be accepted with the option values currently set for the responding endpoint resfd.
Upon successful completion, a value of 0 is returned. Otherwise, a value of –1 is returned and t_errno is set to indicate an error.
fd: T_INCON
resfd (fd!=resfd): T_IDLE, T_UNBND
On failure, t_errno is set to one of the following:
The user does not have permission to accept a connection on the responding transport endpoint or to use the specified options.
The specified protocol address was in an incorrect format or contained illegal information.
The amount of user data specified was not within the bounds allowed by the transport provider.
The file descriptor fd or resfd does not refer to a transport endpoint.
The specified options were in an incorrect format or contained illegal information.
Either an invalid sequence number was specified, or a valid sequence number was specified but the connection request was aborted by the peer. In the latter case, its T_DISCONNECT event will be received on the listening endpoint.
The function was called with fd==resfd but there are outstanding connection indications on the endpoint. Those other connection indications must be handled either by rejecting them by means of t_snddis(3NSL) or accepting them on a different endpoint by means of t_accept.
An asynchronous event has occurred on the transport endpoint referenced by fd and requires immediate attention.
This function is not supported by the underlying transport provider.
The communications endpoint referenced by fd or resfd is not in one of the states in which a call to this function is valid.
This error indicates that a communication problem has been detected between XTI and the transport provider for which there is no other suitable XTI error (t_errno).
The file descriptors fd and resfd do not refer to the same transport provider.
This transport provider requires both fd and resfd to be bound to the same address. This error results if they are not.
The endpoint referenced by resfd (where resfd != fd) was bound to a protocol address with a qlen that is greater than zero.
A system error has occurred during execution of this function.
The XTI and TLI interface definitions have common names but use different header files. This, and other semantic differences between the two interfaces are described in the subsections below.
The XTI interfaces use the header file, xti.h. TLI interfaces should not use this header. They should use the header:
#include <tiuser.h>
The t_errno values that can be set by the XTI interface and cannot be set by the TLI interface are:
The format of the options in an opt buffer is dictated by the transport provider. Unlike the XTI interface, the TLI interface does not specify the buffer format.
See attributes(5) for descriptions of the following attributes:
|
t_connect(3NSL), t_getinfo(3NSL), t_getstate(3NSL), t_listen(3NSL), t_open(3NSL), t_optmgmt(3NSL), t_rcvconnect(3NSL), t_snddis(3NSL), attributes(5)
There may be transport provider-specific restrictions on address binding.
Some transport providers do not differentiate between a connection indication and the connection itself. If the connection has already been established after a successful return of t_listen(3NSL), t_accept() will assign the existing connection to the transport endpoint specified by resfd.