2 .\" <!-- Copyright 2004-2008 Double Precision, Inc. See COPYING for -->
3 .\" <!-- distribution information. -->
5 .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author]
6 .\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/>
8 .\" Manual: Double Precision, Inc.
9 .\" Source: Double Precision, Inc.
12 .TH "AUTH_SASL" "3" "08/25/2013" "Double Precision, Inc." "Double Precision, Inc."
13 .\" -----------------------------------------------------------------
14 .\" * Define some portability stuff
15 .\" -----------------------------------------------------------------
16 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
17 .\" http://bugs.debian.org/507673
18 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
19 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
22 .\" -----------------------------------------------------------------
23 .\" * set default formatting
24 .\" -----------------------------------------------------------------
25 .\" disable hyphenation
27 .\" disable justification (adjust text to left margin only)
29 .\" -----------------------------------------------------------------
30 .\" * MAIN CONTENT STARTS HERE *
31 .\" -----------------------------------------------------------------
33 auth_sasl, auth_sasl_ex \- SASL implementation
37 #include <courierauthsasl\&.h>
39 .HP \w'int\ rc=auth_sasl('u
40 .BI "int rc=auth_sasl(const\ char\ *" "method" ", const\ char\ *" "initialresponse" ", char\ *" "(*conversation_func)" "(const\ char\ *,\ void\ *)), void\ *" "callback_arg" ", char\ **" "authtype_ret" ", char\ **" "authdata_ret" ");"
41 .HP \w'int\ rc=auth_sasl_ex('u
42 .BI "int rc=auth_sasl_ex(const\ char\ *" "method" ", const\ char\ *" "initialresponse" ", const\ char\ *" "externalauth" ", char\ *" "(*conversation_func)" "(const\ char\ *,\ void\ *)), void\ *" "callback_arg" ", char\ **" "authtype_ret" ", char\ **" "authdata_ret" ");"
48 server implementation\&.
52 method\&. At this time
54 knows how to handle the following SASL methods:
100 \fIinitialresponse\fR
101 is a base64\-encoded initial response provided in the client\*(Aqs
104 \fIinitialresponse\fR
107 if an initial response was not included in the client\*(Aqs
111 \fIconversation_func\fR
112 is the application\-implemented
114 conversation callback function\&.
115 \fIconversation_func\fR
116 receives a base64\-encoded
122 \fIconversation_func\fR
123 must return a buffer containing the base64\-encoded reply from the client\&.
127 this buffer when it\*(Aqs done\&.
128 \fIconversation_func\fR
140 method\&. It takes an extra parameter,
141 \fIexternalauth\fR\&. This parameter should be set to indicate an login that was authenticated via some other means, such as, perhaps, an
145 if no externally\-authenticated identity was established\&.
155 is ignored\&. Otherwise, if
165 AUTHSASL_OK, and sets
169 accordingly, so that the subsequent invocation of
170 \fBauth_generic\fR() returns authentication information for the login ID specified by
171 \fIexternalauth\fR\&.
176 conversation succesfully completes,
183 \fI*authdata_ret\fR\&. They will be set to a
184 \fBmalloc\fR(3)\-ed buffers that can be directly passed as arguments to
185 \m[blue]\fB\fBauth_generic\fR(3)\fR\m[]\&\s-2\u[1]\d\s+2\&. It is the application\*(Aqs responsibility to
187 these buffers when it\*(Aqs done with them\&.
196 conversation succesfully completes, and
200 are succesfully assembled\&. Any other return indicates an error condition\&. Right now two error conditions are defined:
206 conversation was aborted by the client\&.
211 General error (insufficient memory, or some other reason)\&. Check
217 \m[blue]\fB\fBauthlib\fR(3)\fR\m[]\&\s-2\u[2]\d\s+2,
218 \m[blue]\fB\fBauth_generic\fR(3)\fR\m[]\&\s-2\u[1]\d\s+2\&.
221 \fBauth_generic\fR(3)
223 \%[set $man.base.url.for.relative.links]/auth_generic.html
228 \%[set $man.base.url.for.relative.links]/authlib.html