OpenVPN
Functions | Variables
console.c File Reference
#include "syshead.h"
#include "console.h"
#include "error.h"
#include "buffer.h"
#include "misc.h"
Include dependency graph for console.c:

Go to the source code of this file.

Functions

void query_user_clear (void)
 Wipes all data put into all of the query_user structs. More...
 
void query_user_add (char *prompt, size_t prompt_len, char *resp, size_t resp_len, bool echo)
 Adds an item to ask the user for. More...
 

Variables

struct _query_user query_user [QUERY_USER_NUMSLOTS]
 Global variable, declared in console.c. More...
 

Function Documentation

◆ query_user_add()

void query_user_add ( char *  prompt,
size_t  prompt_len,
char *  resp,
size_t  resp_len,
bool  echo 
)

Adds an item to ask the user for.

Parameters
promptPrompt to display to the user
prompt_lenLength of the prompt string
respString containing the user response
resp_lenLength of the response string
echoShould the user input be echoed to the user? If False, input will be masked

Definition at line 59 of file console.c.

References ASSERT, _query_user::echo, _query_user::prompt, _query_user::prompt_len, query_user, QUERY_USER_NUMSLOTS, _query_user::response, and _query_user::response_len.

Referenced by get_user_pass_cr(), and query_user_SINGLE().

◆ query_user_clear()

void query_user_clear ( void  )

Wipes all data put into all of the query_user structs.

Definition at line 47 of file console.c.

References CLEAR, query_user, and QUERY_USER_NUMSLOTS.

Referenced by get_user_pass_cr(), and query_user_SINGLE().

Variable Documentation

◆ query_user

struct _query_user query_user[QUERY_USER_NUMSLOTS]

Global variable, declared in console.c.

Definition at line 43 of file console.c.

Referenced by query_user_add(), query_user_clear(), and query_user_exec_builtin().