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