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