Import OpenPAM Resedacea.
[dragonfly.git] / contrib / openpam / doc / man / pam_vprompt.3
1 .\" Generated from pam_vprompt.c by gendoc.pl
2 .\" $OpenPAM: pam_vprompt.c 938 2017-04-30 21:34:42Z des $
3 .Dd April 30, 2017
4 .Dt PAM_VPROMPT 3
5 .Os
6 .Sh NAME
7 .Nm pam_vprompt
8 .Nd call the conversation function
9 .Sh SYNOPSIS
10 .In sys/types.h
11 .In security/pam_appl.h
12 .Ft "int"
13 .Fn pam_vprompt "const pam_handle_t *pamh" "int style" "char **resp" "const char *fmt" "va_list ap"
14 .Sh DESCRIPTION
15 The
16 .Fn pam_vprompt
17 function constructs a string from the
18 .Fa fmt
19 and
20 .Fa ap
21 arguments using
22 .Xr vsnprintf 3 ,
23 and passes it to the given PAM context's
24 conversation function.
25 .Pp
26 The
27 .Fa style
28 argument specifies the type of interaction requested, and
29 must be one of the following:
30 .Bl -tag -width 18n
31 .It Dv PAM_PROMPT_ECHO_OFF
32 Display the message and obtain the user's response without
33 displaying it.
34 .It Dv PAM_PROMPT_ECHO_ON
35 Display the message and obtain the user's response.
36 .It Dv PAM_ERROR_MSG
37 Display the message as an error message, and do not wait
38 for a response.
39 .It Dv PAM_TEXT_INFO
40 Display the message as an informational message, and do
41 not wait for a response.
42 .El
43 .Pp
44 A pointer to the response, or
45 .Dv NULL
46 if the conversation function did
47 not return one, is stored in the location pointed to by the
48 .Fa resp
49 argument.
50 .Pp
51 The message and response should not exceed
52 .Dv PAM_MAX_MSG_SIZE
53 or
54 .Dv PAM_MAX_RESP_SIZE ,
55 respectively.
56 If they do, they may be truncated.
57 .Pp
58 .Sh RETURN VALUES
59 The
60 .Fn pam_vprompt
61 function returns one of the following values:
62 .Bl -tag -width 18n
63 .It Bq Er PAM_SUCCESS
64 Success.
65 .It Bq Er PAM_BUF_ERR
66 Memory buffer error.
67 .It Bq Er PAM_CONV_ERR
68 Conversation failure.
69 .It Bq Er PAM_SYSTEM_ERR
70 System error.
71 .El
72 .Sh SEE ALSO
73 .Xr pam 3 ,
74 .Xr pam_error 3 ,
75 .Xr pam_info 3 ,
76 .Xr pam_prompt 3 ,
77 .Xr pam_strerror 3 ,
78 .Xr pam_verror 3 ,
79 .Xr pam_vinfo 3 ,
80 .Xr vsnprintf 3
81 .Sh STANDARDS
82 The
83 .Fn pam_vprompt
84 function is an OpenPAM extension.
85 .Sh AUTHORS
86 The
87 .Fn pam_vprompt
88 function and this manual page were
89 developed for the
90 .Fx
91 Project by ThinkSec AS and Network Associates Laboratories, the
92 Security Research Division of Network Associates, Inc.\& under
93 DARPA/SPAWAR contract N66001-01-C-8035
94 .Pq Dq CBOSS ,
95 as part of the DARPA CHATS research program.
96 .Pp
97 The OpenPAM library is maintained by
98 .An Dag-Erling Sm\(/orgrav Aq Mt des@des.no .