2018-08-16 10:36:01 +08:00
|
|
|
/*
|
2020-05-15 21:09:49 +08:00
|
|
|
* Copyright 2018-2020 The OpenSSL Project Authors. All Rights Reserved.
|
2018-08-16 10:36:01 +08:00
|
|
|
*
|
2020-04-27 12:59:50 +08:00
|
|
|
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
2018-08-16 10:36:01 +08:00
|
|
|
* 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
|
|
|
|
*/
|
|
|
|
|
2019-09-28 06:45:57 +08:00
|
|
|
#ifndef OSSL_APPS_UI_H
|
|
|
|
# define OSSL_APPS_UI_H
|
2018-08-16 10:36:01 +08:00
|
|
|
|
|
|
|
|
|
|
|
# define PW_MIN_LENGTH 4
|
|
|
|
typedef struct pw_cb_data {
|
|
|
|
const void *password;
|
|
|
|
const char *prompt_info;
|
|
|
|
} PW_CB_DATA;
|
|
|
|
|
|
|
|
int password_callback(char *buf, int bufsiz, int verify, PW_CB_DATA *cb_data);
|
|
|
|
|
|
|
|
int setup_ui_method(void);
|
|
|
|
void destroy_ui_method(void);
|
2020-11-25 21:10:29 +08:00
|
|
|
int set_base_ui_method(const UI_METHOD *ui_method);
|
|
|
|
const UI_METHOD *get_ui_method(void);
|
2018-08-16 10:36:01 +08:00
|
|
|
|
|
|
|
extern BIO *bio_err;
|
|
|
|
|
|
|
|
#endif
|