Simple Authentication Security Layer Library Functions
saslclientstart(3SASL)
NAME
saslclientstart - perform a step in the authentication
negotiation
SYNOPSIS
cc [ flag ... ] file ... -lsasl [ library ... ]
#include
int saslclientstart(saslconnt *conn, const char *mechlist,
saslinteractt **promptneed, const char **clientout,
unsigned *clientoutlen, const char **mech);
DESCRIPTION
Use the saslclientstart() interface to select a mechanism
for authentication and start the authentication session. The
mechlist parameter holds the list of mechanisms that the
client might like to use. The mechanisms in the list are not
necessarily supported by the client, nor are the mechanisms
necessarily valid. SASL determines which of the mechanisms
to use based upon the security preferences specified ear-
lier. The list of mechanisms is typically a list of mechan-
isms that the server supports, acquired from a capability
request.
If SASLINTERACT is returned, the library needs some values
to be filled in before it can proceed. The promptneed
structure is filled in with requests. The application
fullfills these requests and calls saslclientstart() again
with identical parameters. The promptneed parameter is the
same pointer as before, but it is filled in by the applica-
tion.
PARAMETERS
conn The SASL connection context.
mechlist A list of mechanism that the server has
available. Punctuation is ignored.
promptneed A list of prompts that are needed to con-
tinue, if necessary.
clientout clientout and clientoutlen are created. They
clientoutlen contain the initial client response to send
to the server. It is the job of the client
to send them over the network to the server.
Any protocol specific encodingthat is
SunOS 5.11 Last change: 26 Aug 2003 1
Simple Authentication Security Layer Library Functions
saslclientstart(3SASL)
necessary, for example base64 encoding, must
be done by the client.
If the protocol lacks client-send-first
capability, then set clientout to NUL. If
there is no initial client-send, then
*clientout will be set to NUL on return.
mech Contains the name of the chosen SASL mechan-
ism, upon success.
RETURN VALUES
saslclientstart() returns an integer that corresponds to a
SASL error code.
ERORS
SASLCONTINUE The call to saslclientstart() was suc-
cessful, and more steps are needed in the
authentication.
All other error codes indicate an error situation that must
be handled, or the authentication session should be quit.
See saslerrors(3SASL) for information on SASL error codes.
ATRIBUTES
See attributes(5) for descriptions of the following attri-
butes:
ATRIBUTE TYPE ATRIBUTE VALUE
Availablity SUNWlibsasl
Interface Stability Evolving
MT-Level Safe
SEE ALSO
saslerrors(3SASL), attributes(5)
SunOS 5.11 Last change: 26 Aug 2003 2
Simple Authentication Security Layer Library Functions
saslclientstart(3SASL)
SunOS 5.11 Last change: 26 Aug 2003 3
|