|
1 '\" te |
|
2 .\" Copyright (C) 1998-2003, Carnegie Mellon Univeristy. All Rights Reserved. |
|
3 .\" Portions Copyright (C) 2003, Sun Microsystems, Inc. All Rights Reserved |
|
4 .TH sasl_seterror 3SASL "14 Oct 2003" "SunOS 5.12" "Simple Authentication Security Layer Library Functions" |
|
5 .SH NAME |
|
6 sasl_seterror \- set the error string |
|
7 .SH SYNOPSIS |
|
8 .LP |
|
9 .nf |
|
10 \fBcc\fR [ \fIflag\fR ... ] \fIfile\fR ... \fB-lsasl\fR [ \fIlibrary\fR ... ] |
|
11 #include <sasl/sasl.h> |
|
12 |
|
13 \fBvoid\fR \fBsasl_seterror\fR(\fBsasl_conn_t *\fR\fIconn\fR, \fBunsigned\fR \fIflags\fR, |
|
14 \fBconst char *\fR\fIfmt\fR, ...); |
|
15 .fi |
|
16 |
|
17 .SH DESCRIPTION |
|
18 .sp |
|
19 .LP |
|
20 The \fBsasl_seterror()\fR interface sets the error string that will be returned by \fBsasl_errdetail\fR(3SASL). Use \fBsyslog\fR(3C) style formatting, that is, use \fBprintf()\fR\(emstyle with \fB%m\fR as the most recent \fBerrno\fR error. |
|
21 .sp |
|
22 .LP |
|
23 The \fBsasl_seterror()\fR interface is primarily used by server callback functions and internal plug-ins, for example, with the \fBsasl_authorize_t\fR callback. The \fBsasl_seterror()\fR interface triggers a call to the SASL logging callback, if any, with a level of \fBSASL_LOG_FAIL\fR, unless the \fBSASL_NOLOG\fR flag is set. |
|
24 .sp |
|
25 .LP |
|
26 Make the message string sensitive to the current language setting. If there is no \fBSASL_CB_LANGUAGE\fR callback, message strings must be \fBi-default\fR. Otherwise, UTF-8 is used. Use of \fIRFC 2482\fR for mixed-language text is encouraged. |
|
27 .sp |
|
28 .LP |
|
29 If the value of \fIconn\fR is \fINULL\fR, the \fBsasl_seterror()\fR interface fails. |
|
30 .SH PARAMETERS |
|
31 .sp |
|
32 .ne 2 |
|
33 .mk |
|
34 .na |
|
35 \fB\fIconn\fR\fR |
|
36 .ad |
|
37 .RS 9n |
|
38 .rt |
|
39 The \fBsasl_conn_t\fR for which the call to \fBsasl_seterror()\fR applies. |
|
40 .RE |
|
41 |
|
42 .sp |
|
43 .ne 2 |
|
44 .mk |
|
45 .na |
|
46 \fB\fIflags\fR\fR |
|
47 .ad |
|
48 .RS 9n |
|
49 .rt |
|
50 If set to \fBSASL_NOLOG\fR, the call to \fBsasl_seterror()\fR is not logged. |
|
51 .RE |
|
52 |
|
53 .sp |
|
54 .ne 2 |
|
55 .mk |
|
56 .na |
|
57 \fB\fIfmt\fR\fR |
|
58 .ad |
|
59 .RS 9n |
|
60 .rt |
|
61 A \fBsyslog\fR(3C) style format string. |
|
62 .RE |
|
63 |
|
64 .SH RETURN VALUES |
|
65 .sp |
|
66 .LP |
|
67 \fBsasl_seterror()\fR has no return values. |
|
68 .SH ATTRIBUTES |
|
69 .sp |
|
70 .LP |
|
71 See \fBattributes\fR(5) for descriptions of the following attributes: |
|
72 .sp |
|
73 |
|
74 .sp |
|
75 .TS |
|
76 tab() box; |
|
77 cw(2.75i) |cw(2.75i) |
|
78 lw(2.75i) |lw(2.75i) |
|
79 . |
|
80 ATTRIBUTE TYPEATTRIBUTE VALUE |
|
81 _ |
|
82 Availabilitysystem/library/security/libsasl |
|
83 _ |
|
84 Interface StabilityCommitted |
|
85 _ |
|
86 MT-LevelMT-Safe |
|
87 .TE |
|
88 |
|
89 .SH SEE ALSO |
|
90 .sp |
|
91 .LP |
|
92 \fBsasl_errdetail\fR(3SASL), \fBsyslog\fR(3C), \fBattributes\fR(5) |
|
93 .sp |
|
94 .LP |
|
95 Whistler, K. and Adams, G. \fIRFC 2482, Language Tagging in Unicode Plain Text\fR. Network Working Group. January 1999. |