1SASL_CALLBACKS(3) Cyrus SASL SASL_CALLBACKS(3)
2
3
4
6 sasl_callbacks - Cyrus SASL documentation
7
9 #include <sasl/sasl.h>
10
12 sasl_callbacks are used when the application needs some information
13 from the application. Common reasons are getting for getting user‐
14 names and passwords. A client MUST specify what callbacks they
15 support in the sasl_client_init(3)/sasl_server_init(3) or
16 sasl_client_new(3)/sasl_server_new(3) calls. If an authentication
17 mechanism needs a callback that the application does not state it
18 supports it cannot be used.
19
20 If a callback has an id parameter that should be checked to make sure
21 you are giving the appropriate value.
22
23 If an application is using the client side of the library functions to
24 handle the callbacks are not necessary. Instead the application
25 may deal with callbacks via SASL_INTERACT’s. See
26 sasl_client_start(3)/sasl_client_step(3) for more information.
27
28 Common Callbacks
29 sasl_getopt_t
30 Get an option value
31
32 sasl_log_t
33 Log message handler
34
35 sasl_getpath_t
36 Get path to search for plugins (e.g. SASL mechanisms)
37
38 sasl_verifyfile_t
39 Verify files for use by SASL
40
41 sasl_canon_user_t(3)
42 Username canonicalization function
43
44 Client-only Callbacks
45 sasl_getsimple_t
46 Get user/language list
47
48 sasl_getsecret_t
49 Get authentication secret
50
51 sasl_chalprompt_t(3)
52 Display challenge and prompt for response
53
54 sasl_getrealm_t
55 Get the realm for authentication
56
57 Server-only Callbacks
58 sasl_authorize_t(3)
59 Authorize policy callback
60
61 sasl_server_userdb_checkpass_t
62 verify plaintext password
63
64 sasl_server_userdb_setpass_t
65 set plaintext password
66
67 sasl_getconfpath_t
68 Get path to search for SASL configuration file (server side
69 only). New in SASL 2.1.22.
70
72 SASL callback functions should return SASL return codes. See
73 sasl_errors(3) for a complete list. SASL_OK typically indicates suc‐
74 cess.
75
77 RFC 4422
78
80 sasl(3), sasl_errors(3), sasl_authorize_t(3), sasl_log_t(3), sasl_get‐
81 path_t(3), sasl_getconfpath_t(3), sasl_verifyfile_t(3),
82 sasl_canon_user_t(3), sasl_getsimple_t(3), sasl_getsecret_t(3),
83 sasl_chalprompt_t(3), sasl_getrealm_t(3), sasl_server_userdb_check‐
84 pass_t(3), sasl_server_userdb_setpass_t(3)
85
87 The Cyrus Team
88
90 1993-2016, The Cyrus Team
91
92
93
94
952.1.28 February 18, 2022 SASL_CALLBACKS(3)