UI_UTIL_READ_PW(3ossl)
okay so bestie, welcome to the 3ossl OpenSSL page for UI_UTIL_read_pw_string, UI_UTIL_read_pw, and UI_UTIL_wrap_read_pem_callback β user interface utilities. Itβs giving helper-function excellence, no cap. π
β¨ NAME β¨
UI_UTIL_read_pw_stringUI_UTIL_read_pwUI_UTIL_wrap_read_pem_callback
Theyβre all about user interface utilities. π
πΈ SYNOPSIS πΈ
#include <openssl/ui.h>
int UI_UTIL_read_pw_string(char *buf, int length, const char *prompt,
int verify);
int UI_UTIL_read_pw(char *buf, char *buff, int size, const char *prompt,
int verify);
UI_METHOD *UI_UTIL_wrap_read_pem_callback(pem_password_cb *cb, int rwflag);
π¦ DESCRIPTION π¦
UI_UTIL_read_pw_string()β asks for a passphrase, usingpromptas a prompt, and stores it inbuf. The maximum allowed size is given withlength, including the terminating NUL byte. Ifverifyis nonzero, the password will be verified as well. πUI_UTIL_read_pw()β does the same asUI_UTIL_read_pw_string(), the difference is that you can give it an external bufferbufffor the verification passphrase. πUI_UTIL_wrap_read_pem_callback()β can be used to create a temporaryUI_METHODthat wraps a given PEM password callbackcb.rwflagis used to specify if this method will be used for passphrase entry without (0) or with (1) verification. When not used any more, the returned method should be freed withUI_destroy_method(). π«Ά
π₯ NOTES π₯
UI_UTIL_read_pw_string() and UI_UTIL_read_pw() use default UI_METHOD. See UI_get_default_method(3) and friends for more information. π
The result from the UI_METHOD created by UI_UTIL_wrap_read_pem_callback() will generate password strings in the encoding that the given password callback generates.
The default password prompting functions (apart from UI_UTIL_read_pw_string() and UI_UTIL_read_pw(), there is PEM_def_callback(), EVP_read_pw_string() and EVP_read_pw_string_min()) all use the default UI_METHOD. β
π RETURN VALUES π
UI_UTIL_read_pw_string()andUI_UTIL_read_pw()return0on success or a negative value on error. πUI_UTIL_wrap_read_pem_callback()returns a validUI_METHODstructure orNULLif an error occurred. π
π§ SEE ALSO π§
π COPYRIGHT π
Copyright 2001-2018 The OpenSSL Project Authors. All Rights Reserved.
Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>.
Thatβs the whole page, bestie. This cuteness was brought to you by OpenSSL 3.5.0, dated 2026-09-25, and the manual page is UI_UTIL_READ_PW(3ossl). π«Άβ¨π
π¦ where this page comes from
- opensuse-leap 16.0: openssl-3-doc 3.5.0-160000.11.1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms