3 .\" Copyright (c) 2001 Carnegie Mellon University. All rights reserved.
5 .\" Redistribution and use in source and binary forms, with or without
6 .\" modification, are permitted provided that the following conditions
9 .\" 1. Redistributions of source code must retain the above copyright
10 .\" notice, this list of conditions and the following disclaimer.
12 .\" 2. Redistributions in binary form must reproduce the above copyright
13 .\" notice, this list of conditions and the following disclaimer in
14 .\" the documentation and/or other materials provided with the
17 .\" 3. The name "Carnegie Mellon University" must not be used to
18 .\" endorse or promote products derived from this software without
19 .\" prior written permission. For permission or any other legal
20 .\" details, please contact
21 .\" Office of Technology Transfer
22 .\" Carnegie Mellon University
23 .\" 5000 Forbes Avenue
24 .\" Pittsburgh, PA 15213-3890
25 .\" (412) 268-4387, fax: (412) 268-7395
26 .\" tech-transfer@andrew.cmu.edu
28 .\" 4. Redistributions of any form whatsoever must retain the following
30 .\" "This product includes software developed by Computing Services
31 .\" at Carnegie Mellon University (http://www.cmu.edu/computing/)."
33 .\" CARNEGIE MELLON UNIVERSITY DISCLAIMS ALL WARRANTIES WITH REGARD TO
34 .\" THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
35 .\" AND FITNESS, IN NO EVENT SHALL CARNEGIE MELLON UNIVERSITY BE LIABLE
36 .\" FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
37 .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
38 .\" AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
39 .\" OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
41 .TH sasl_client_new "21 June 2001" SASL "SASL man pages"
43 sasl_client_new \- Create a new client authentication object
48 .B #include <sasl/sasl.h>
50 .BI "int sasl_client_new(const char " *service ", "
51 .BI " const char " *serverFQDN ", "
52 .BI " const char " *iplocalport ", "
53 .BI " const char " *ipremoteport ", "
54 .BI " const sasl_callback_t " *prompt_supp,
55 .BI " unsigned " flags ", "
56 .BI " sasl_conn_t ** " pconn ");"
62 creates a new SASL context. This context will be used for all SASL calls for one connection. It handles both authentication and integrity/encryption layers after authentication.
65 is the registered name of the service (usually the protocol name) using SASL (e.g. "imap").
68 is the fully qualified domain name of the server (e.g. "serverhost.cmu.edu").
71 is the IP and port of the local side of the connection, or NULL. If
72 iplocalport is NULL it will disable mechanisms that require IP address
73 information. This strings must be in one of the following formats:
74 "a.b.c.d;port" (IPv4), "e:f:g:h:i:j:k:l;port" (IPv6),
75 or "e:f:g:h:i:j:a.b.c.d;port" (IPv6)
78 is the IP and port of the remote side of the connection, or NULL (see
82 is a list of client interactions supported that is unique to this connection. If this parameter is NULL the global callbacks (specified in sasl_client_init) will be used. See sasl_callback for more information.
85 are connection flags (see below)
88 is the connection context allocated by the library. This structure will be used for all future SASL calls for this connection.
92 Flags that may be passed to
97 The protocol supports a server-last send
100 Force the use of a mechanism that supports an authorization id that is
101 not the authentication id.
105 sasl_client_new returns an integer which corresponds to one of the
106 following codes. SASL_OK is the only one that indicates success. All
107 others indicate errors and should either be handled or the
108 authentication session should be quit.
116 Error in config file or passed parameters
119 No mechanism meets requested properties
122 Not enough memory to complete operation
127 sasl(3), sasl_client_init(3), sasl_client_start(3), sasl_client_step(3), sasl_setprop(3)