2 * Copyright 2002-2016 The OpenSSL Project Authors. All Rights Reserved.
4 * Licensed under the OpenSSL license (the "License"). You may not use
5 * this file except in compliance with the License. You can obtain a copy
6 * in the file LICENSE in the source distribution or at
7 * https://www.openssl.org/source/license.html
17 int UI_UTIL_read_pw_string(char *buf, int length, const char *prompt,
24 UI_UTIL_read_pw(buf, buff, (length > BUFSIZ) ? BUFSIZ : length,
26 OPENSSL_cleanse(buff, BUFSIZ);
30 int UI_UTIL_read_pw(char *buf, char *buff, int size, const char *prompt,
41 ok = UI_add_input_string(ui, prompt, 0, buf, 0, size - 1);
42 if (ok >= 0 && verify)
43 ok = UI_add_verify_string(ui, prompt, 0, buff, 0, size - 1, buf);