nightly: remove unused BINARCHIVE
[unleashed.git] / share / man / man3sasl / sasl_client_new.3sasl
blob3352cead03698fb158d9fd99143bdd4a0c8ab50a
1 '\" te
2 .\" Copyright (C) 1998-2003, Carnegie Mellon Univeristy.  All Rights Reserved.
3 .\" Portions Copyright (C) 2003, Sun Microsystems,
4 .\" Inc. All Rights Reserved
5 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
6 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
7 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
8 .TH SASL_CLIENT_NEW 3SASL "Aug 27, 2003"
9 .SH NAME
10 sasl_client_new \- create a new client authentication object
11 .SH SYNOPSIS
12 .LP
13 .nf
14 \fBcc\fR [ \fIflag\fR ... ] \fIfile\fR ... \fB-lsasl\fR   [ \fIlibrary\fR ... ]
15 #include <sasl/sasl.h>
17 \fBint\fR \fBsasl_client_new\fR(\fBconst char *\fR\fIservice\fR, \fBconst char *\fR\fIserverFQDN\fR,
18      \fBconst char *\fR\fIiplocalport\fR, \fBconst char *\fR\fIipremoteport\fR,
19      \fBconst sasl_callback_t *\fR\fIprompt_supp\fR, \fBunsigned\fR \fIflags\fR,
20      \fBsasl_conn_t **\fR\fIpconn\fR);
21 .fi
23 .SH DESCRIPTION
24 .sp
25 .LP
26 Use the \fBsasl_client_new()\fR interface to create a new SASL context. This
27 SASL context will be used for all SASL calls for one connection. The context
28 handles both authentication and the integrity and encryption layers after
29 authentication.
30 .SH PARAMETERS
31 .sp
32 .ne 2
33 .na
34 \fB\fIservice\fR\fR
35 .ad
36 .RS 16n
37 The registered name of the service that uses SASL, usually the protocol name,
38 for example, IMAP.
39 .RE
41 .sp
42 .ne 2
43 .na
44 \fB\fIserverFQDN\fR\fR
45 .ad
46 .RS 16n
47 The fully qualified domain name of the server, for example, serverhost.cmu.edu.
48 .RE
50 .sp
51 .ne 2
52 .na
53 \fB\fIiplocalport\fR\fR
54 .ad
55 .RS 16n
56 .sp
57 .LP
58 The IP and port of the local side of the connection, or \fINULL\fR. If
59 \fIiplocalport\fR is \fINULL\fR, mechanisms that require IP address information
60 are disabled. The \fIiplocalport\fR string must be in one of the following
61 formats:
62 .RS +4
63 .TP
64 .ie t \(bu
65 .el o
66 \fBa.b.c.d:port\fR (IPv6)
67 .RE
68 .RS +4
69 .TP
70 .ie t \(bu
71 .el o
72 \fB[e:f:g:h:i:j:k:l]:port\fR (IPv6)
73 .RE
74 .RS +4
75 .TP
76 .ie t \(bu
77 .el o
78 \fB[e:f:g:h:i:j:a.b.c.d]:port\fR (IPv6)
79 .RE
80 .RS +4
81 .TP
82 .ie t \(bu
83 .el o
84 \fBa.b.c.d;port\fR (IPv4)
85 .RE
86 .RS +4
87 .TP
88 .ie t \(bu
89 .el o
90 \fBe:f:g:h:i:j:k:l;port\fR (IPv6)
91 .RE
92 .RS +4
93 .TP
94 .ie t \(bu
95 .el o
96 \fBe:f:g:h:i:j:a.b.c.d;port\fR (IPv6)
97 .RE
98 .RE
101 .ne 2
103 \fB\fIipremoteport\fR\fR
105 .RS 16n
106 The IP and port of the remote side of the connection, or \fINULL\fR.
110 .ne 2
112 \fB\fIprompt_supp\fR\fR
114 .RS 16n
115 A list of the client interactions supported that are unique to this connection.
116 If this parameter is \fINULL\fR, the global callbacks specified in
117 \fBsasl_client_init\fR(3SASL) are used.
121 .ne 2
123 \fB\fIflags\fR\fR
125 .RS 16n
126 Usage flags. For clients, the flag \fBSASL_NEED_PROXY\fR is available.
130 .ne 2
132 \fB\fIpconn\fR\fR
134 .RS 16n
135 The connection context allocated by the library. The \fIpconn\fR structure is
136 used for all future SASL calls for this connection.
139 .SH RETURN VALUES
142 \fBsasl_client_new()\fR returns an integer that corresponds to a SASL error
143 code.
144 .SH ERRORS
146 .ne 2
148 \fB\fBSASL_OK\fR\fR
150 .RS 17n
151 The call to \fBsasl_client_new()\fR was successful.
155 .ne 2
157 \fB\fBSASL_NOMECH\fR\fR
159 .RS 17n
160 No mechanishm meets the requested properties.
164 .ne 2
166 \fB\fBSASL_BADPARAM\fR\fR
168 .RS 17n
169 There is an error in the configuration file or passed parameters.
173 .ne 2
175 \fB\fBSASL_NOMEM\fR\fR
177 .RS 17n
178 There is not enough memory to complete the operation.
183 All other error codes indicate an error situation that must be handled, or the
184 authentication session should be quit. See \fBsasl_errors\fR(3SASL) for
185 information on SASL error codes.
186 .SH ATTRIBUTES
189 See \fBattributes\fR(5) for descriptions of the following attributes:
194 box;
195 c | c
196 l | l .
197 ATTRIBUTE TYPE  ATTRIBUTE VALUE
199 Interface Stability     Evolving
201 MT-Level        Safe
204 .SH SEE ALSO
207 \fBsasl_client_init\fR(3SASL), \fBsasl_errors\fR(3SASL), \fBattributes\fR(5)