Home
last modified time | relevance | path

Searched full:ui (Results 1 – 25 of 376) sorted by relevance

12345678910>>...16

/freebsd/crypto/openssl/crypto/ui/
H A Dui_lib.c14 #include <openssl/ui.h>
18 UI *UI_new(void) in UI_new()
23 UI *UI_new_method(const UI_METHOD *method) in UI_new_method()
25 UI *ret = OPENSSL_zalloc(sizeof(*ret)); in UI_new_method()
73 void UI_free(UI *ui) in UI_free() argument
75 if (ui == NULL) in UI_free()
77 if ((ui->flags & UI_FLAG_DUPL_DATA) != 0) { in UI_free()
78 ui->meth->ui_destroy_data(ui, ui->user_data); in UI_free()
80 sk_UI_STRING_pop_free(ui->strings, free_string); in UI_free()
81 CRYPTO_free_ex_data(CRYPTO_EX_INDEX_UI, ui, &ui->ex_data); in UI_free()
[all …]
H A Dui_local.h13 # include <openssl/ui.h>
31 int (*ui_open_session) (UI *ui);
32 int (*ui_write_string) (UI *ui, UI_STRING *uis);
37 int (*ui_flush) (UI *ui);
38 int (*ui_read_string) (UI *ui, UI_STRING *uis);
39 int (*ui_close_session) (UI *ui);
42 * allows some backends to save away UI information for later use.
44 void *(*ui_duplicate_data) (UI *ui, void *ui_data);
45 void (*ui_destroy_data) (UI *ui, void *ui_data);
53 char *(*ui_construct_prompt) (UI *ui, const char *object_desc,
[all …]
H A Dui_util.c36 UI *ui; in UI_UTIL_read_pw() local
41 ui = UI_new(); in UI_UTIL_read_pw()
42 if (ui != NULL) { in UI_UTIL_read_pw()
43 ok = UI_add_input_string(ui, prompt, 0, buf, 0, size - 1); in UI_UTIL_read_pw()
45 ok = UI_add_verify_string(ui, prompt, 0, buff, 0, size - 1, buf); in UI_UTIL_read_pw()
47 ok = UI_process(ui); in UI_UTIL_read_pw()
48 UI_free(ui); in UI_UTIL_read_pw()
99 static int ui_open(UI *ui) in ui_open() argument
103 static int ui_read(UI *ui, UI_STRING *uis) in ui_read() argument
110 UI_method_get_ex_data(UI_get_method(ui), ui_method_data_index); in ui_read()
[all …]
H A Dui_openssl.c13 #include <openssl/ui.h>
189 static int read_string_inner(UI *ui, UI_STRING *uis, int echo, int strip_nl);
191 static int read_string(UI *ui, UI_STRING *uis);
192 static int write_string(UI *ui, UI_STRING *uis);
194 static int open_console(UI *ui);
195 static int echo_console(UI *ui);
196 static int noecho_console(UI *ui);
197 static int close_console(UI *ui);
203 static int write_string(UI *ui, UI_STRING *uis) in write_string() argument
220 static int read_string(UI *ui, UI_STRING *uis) in read_string() argument
[all …]
/freebsd/contrib/kyua/utils/cmdline/
H A Dui_test.cpp29 #include "utils/cmdline/ui.hpp"
101 cmdline::ui ui; in ATF_TEST_CASE_BODY() local
102 ATF_REQUIRE_EQ(4321 - 5, ui.screen_width().get()); in ATF_TEST_CASE_BODY()
112 cmdline::ui ui; in ATF_TEST_CASE_BODY() local
113 ATF_REQUIRE_EQ(4321 - 5, ui.screen_width().get()); in ATF_TEST_CASE_BODY()
123 cmdline::ui ui; in ATF_TEST_CASE_BODY() local
124 ATF_REQUIRE(!ui.screen_width()); in ATF_TEST_CASE_BODY()
134 cmdline::ui ui; in ATF_TEST_CASE_BODY() local
135 ATF_REQUIRE_EQ(columns, ui.screen_width().get()); in ATF_TEST_CASE_BODY()
145 cmdline::ui ui; in ATF_TEST_CASE_BODY() local
[all …]
/freebsd/crypto/openssl/doc/man3/
H A DUI_new.pod5 UI,
17 #include <openssl/ui.h>
19 typedef struct ui_st UI;
21 UI *UI_new(void);
22 UI *UI_new_method(const UI_METHOD *method);
23 void UI_free(UI *ui);
25 int UI_add_input_string(UI *ui, const char *prompt, int flags,
27 int UI_dup_input_string(UI *ui, const char *prompt, int flags,
29 int UI_add_verify_string(UI *ui, const char *prompt, int flags,
32 int UI_dup_verify_string(UI *ui, const char *prompt, int flags,
[all …]
H A DUI_create_method.pod18 #include <openssl/ui.h>
24 int UI_method_set_opener(UI_METHOD *method, int (*opener) (UI *ui));
26 int (*writer) (UI *ui, UI_STRING *uis));
27 int UI_method_set_flusher(UI_METHOD *method, int (*flusher) (UI *ui));
29 int (*reader) (UI *ui, UI_STRING *uis));
30 int UI_method_set_closer(UI_METHOD *method, int (*closer) (UI *ui));
32 void *(*duplicator) (UI *ui, void *ui_data),
33 void (*destructor)(UI *ui, void *ui_data));
35 char *(*prompt_constructor) (UI *ui,
41 int (*UI_method_get_opener(const UI_METHOD *method)) (UI *);
[all …]
H A DUI_STRING.pod14 #include <openssl/ui.h>
36 int UI_set_result(UI *ui, UI_STRING *uis, const char *result);
37 int UI_set_result_ex(UI *ui, UI_STRING *uis, const char *result, int len);
41 The B<UI_STRING> gets created internally and added to a B<UI> whenever
82 For B<UIT_PROMPT> and B<UIT_VERIFY> type UI strings, this sets the
86 For B<UIT_BOOLEAN> type UI strings, this sets the first character of
102 UI_get_string_type() returns the UI string type.
104 UI_get_input_flags() returns the UI string flags.
106 UI_get0_output_string() returns the UI string output string.
108 UI_get0_action_string() returns the UI string action description
[all …]
/freebsd/secure/lib/libcrypto/man/man3/
H A DUI_new.3152 \& #include <openssl/ui.h>
154 \& typedef struct ui_st UI;
156 \& UI *UI_new(void);
157 \& UI *UI_new_method(const UI_METHOD *method);
158 \& void UI_free(UI *ui);
160 \& int UI_add_input_string(UI *ui, const char *prompt, int flags,
162 \& int UI_dup_input_string(UI *ui, const char *prompt, int flags,
164 \& int UI_add_verify_string(UI *ui, const char *prompt, int flags,
167 \& int UI_dup_verify_string(UI *ui, const char *prompt, int flags,
170 \& int UI_add_input_boolean(UI *ui, const char *prompt, const char *action_desc,
[all …]
H A DUI_create_method.3153 \& #include <openssl/ui.h>
159 \& int UI_method_set_opener(UI_METHOD *method, int (*opener) (UI *ui));
161 \& int (*writer) (UI *ui, UI_STRING *uis));
162 \& int UI_method_set_flusher(UI_METHOD *method, int (*flusher) (UI *ui));
164 \& int (*reader) (UI *ui, UI_STRING *uis));
165 \& int UI_method_set_closer(UI_METHOD *method, int (*closer) (UI *ui));
167 \& void *(*duplicator) (UI *ui, void *ui_data),
168 \& void (*destructor)(UI *ui, void *ui_data));
170 \& char *(*prompt_constructor) (UI *ui,
176 \& int (*UI_method_get_opener(const UI_METHOD *method)) (UI *);
[all …]
H A DUI_STRING.3149 \& #include <openssl/ui.h>
171 \& int UI_set_result(UI *ui, UI_STRING *uis, const char *result);
172 \& int UI_set_result_ex(UI *ui, UI_STRING *uis, const char *result, int len);
176 The \fB\s-1UI_STRING\s0\fR gets created internally and added to a \fB\s-1UI\s0\fR whenever
217 For \fB\s-1UIT_PROMPT\s0\fR and \fB\s-1UIT_VERIFY\s0\fR type \s-1UI\s0 strings, this sets the
221 For \fB\s-1UIT_BOOLEAN\s0\fR type \s-1UI\s0 strings, this sets the first character of
236 \&\fBUI_get_string_type()\fR returns the \s-1UI\s0 string type.
238 \&\fBUI_get_input_flags()\fR returns the \s-1UI\s0 string flags.
240 \&\fBUI_get0_output_string()\fR returns the \s-1UI\s0 string output string.
242 \&\fBUI_get0_action_string()\fR returns the \s-1UI\s0 string action description
[all …]
/freebsd/contrib/kyua/cli/
H A Dcmd_about_test.cpp76 cmdline::ui_mock ui; in ATF_TEST_CASE_BODY() local
77 ATF_REQUIRE_EQ(EXIT_SUCCESS, cmd.main(&ui, args, engine::default_config())); in ATF_TEST_CASE_BODY()
79 ATF_REQUIRE(atf::utils::grep_string(PACKAGE_NAME, ui.out_log()[0])); in ATF_TEST_CASE_BODY()
80 ATF_REQUIRE(atf::utils::grep_string(PACKAGE_VERSION, ui.out_log()[0])); in ATF_TEST_CASE_BODY()
83 ui.out_log())); in ATF_TEST_CASE_BODY()
84 ATF_REQUIRE(atf::utils::grep_collection("\\* First author", ui.out_log())); in ATF_TEST_CASE_BODY()
85 ATF_REQUIRE(!atf::utils::grep_collection("garbage", ui.out_log())); in ATF_TEST_CASE_BODY()
86 ATF_REQUIRE(atf::utils::grep_collection("\\* Second author", ui.out_log())); in ATF_TEST_CASE_BODY()
89 ui.out_log())); in ATF_TEST_CASE_BODY()
91 ui.out_log())); in ATF_TEST_CASE_BODY()
[all …]
H A Dcmd_about.cpp39 #include "utils/cmdline/ui.hpp"
67 /// \param ui Object to interact with the I/O of the program.
74 cat_file(cmdline::ui* ui, const fs::path& file, in cat_file() argument
79 ui->err(F("Failed to open %s") % file); in cat_file()
86 ui->out(line); in cat_file()
92 ui->out(line); in cat_file()
114 /// \param ui Object to interact with the I/O of the program.
120 cmd_about::run(cmdline::ui* ui, const cmdline::parsed_cmdline& cmdline, in run() argument
131 ui->out(PACKAGE " (" PACKAGE_NAME ") " PACKAGE_VERSION); in run()
132 ui->out(""); in run()
[all …]
H A Dmain_test.cpp82 run(cmdline::ui* /* ui */, in run() argument
120 run(cmdline::ui* /* ui */, in run() argument
145 /// \param ui Object to interact with the I/O of the program.
149 run(cmdline::ui* ui, in run() argument
153 ui->out("stdout message from subcommand"); in run()
154 ui->err("stderr message from subcommand"); in run()
212 cmdline::ui_mock ui; in ATF_TEST_CASE_BODY() local
213 ATF_REQUIRE_EQ(3, cli::main(&ui, argc, argv)); in ATF_TEST_CASE_BODY()
214 ATF_REQUIRE(ui.out_log().empty()); in ATF_TEST_CASE_BODY()
216 ui.err_log())); in ATF_TEST_CASE_BODY()
[all …]
H A Dcmd_help_test.cpp80 run(cmdline::ui* /* ui */, in run() argument
111 run(cmdline::ui* /* ui */, in run() argument
144 /// \param ui The cmdline::mock_ui object to which to write the output.
148 cmdline::ui_mock& ui) in global_test() argument
157 ATF_REQUIRE_EQ(EXIT_SUCCESS, cmd.main(&ui, args, engine::default_config())); in global_test()
185 ATF_REQUIRE(expected == ui.out_log()); in global_test()
186 ATF_REQUIRE(ui.err_log().empty()); in global_test()
196 cmdline::ui_mock ui; in ATF_TEST_CASE_BODY() local
200 global_test(general_options, std::vector< std::string >(), ui); in ATF_TEST_CASE_BODY()
207 cmdline::ui_mock ui; in ATF_TEST_CASE_BODY() local
[all …]
H A Dcmd_help.cpp40 #include "utils/cmdline/ui.hpp"
92 /// \param ui Object to interact with the I/O of the program.
96 general_help(cmdline::ui* ui, const cmdline::options_vector* options, in general_help() argument
101 cli::write_version_header(ui); in general_help()
102 ui->out(""); in general_help()
103 ui->out_tag_wrap( in general_help()
142 ui->out_wrap(""); in general_help()
143 ui->out_wrap("Available general options:"); in general_help()
144 ui->out_table(options_table, formatter, " "); in general_help()
151 ui->out_wrap(""); in general_help()
[all …]
H A Dcmd_config_test.cpp84 cmdline::ui_mock ui; in ATF_TEST_CASE_BODY() local
85 ATF_REQUIRE_EQ(EXIT_SUCCESS, cmd.main(&ui, args, fake_config())); in ATF_TEST_CASE_BODY()
87 ATF_REQUIRE_EQ(6, ui.out_log().size()); in ATF_TEST_CASE_BODY()
88 ATF_REQUIRE_EQ("architecture = the-architecture", ui.out_log()[0]); in ATF_TEST_CASE_BODY()
89 ATF_REQUIRE_EQ("execenvs = the-env", ui.out_log()[1]); in ATF_TEST_CASE_BODY()
90 ATF_REQUIRE_EQ("parallelism = 128", ui.out_log()[2]); in ATF_TEST_CASE_BODY()
91 ATF_REQUIRE_EQ("platform = the-platform", ui.out_log()[3]); in ATF_TEST_CASE_BODY()
92 ATF_REQUIRE_EQ("test_suites.foo.bar = first", ui.out_log()[4]); in ATF_TEST_CASE_BODY()
93 ATF_REQUIRE_EQ("test_suites.foo.baz = second", ui.out_log()[5]); in ATF_TEST_CASE_BODY()
94 ATF_REQUIRE(ui.err_log().empty()); in ATF_TEST_CASE_BODY()
[all …]
H A Dcmd_list_test.cpp56 cmdline::ui_mock ui; in ATF_TEST_CASE_BODY() local
57 cli::detail::list_test_case(&ui, false, test_program, "abc"); in ATF_TEST_CASE_BODY()
58 ATF_REQUIRE_EQ(1, ui.out_log().size()); in ATF_TEST_CASE_BODY()
59 ATF_REQUIRE_EQ("the/test-program:abc", ui.out_log()[0]); in ATF_TEST_CASE_BODY()
60 ATF_REQUIRE(ui.err_log().empty()); in ATF_TEST_CASE_BODY()
72 cmdline::ui_mock ui; in ATF_TEST_CASE_BODY() local
73 cli::detail::list_test_case(&ui, true, test_program, "my_name"); in ATF_TEST_CASE_BODY()
74 ATF_REQUIRE_EQ(1, ui.out_log().size()); in ATF_TEST_CASE_BODY()
75 ATF_REQUIRE_EQ("hello/world:my_name (the-suite)", ui.out_log()[0]); in ATF_TEST_CASE_BODY()
76 ATF_REQUIRE(ui.err_log().empty()); in ATF_TEST_CASE_BODY()
[all …]
H A Dcmd_config.cpp35 #include "utils/cmdline/ui.hpp"
50 /// \param ui Object to interact with the I/O of the program.
56 print_all(cmdline::ui* ui, const config::properties_map& properties) in print_all() argument
60 ui->out(F("%s = %s") % (*iter).first % (*iter).second); in print_all()
67 /// \param ui Object to interact with the I/O of the program.
74 print_some(cmdline::ui* ui, const config::properties_map& properties, in print_some() argument
84 cmdline::print_warning(ui, F("'%s' is not defined.") % *iter); in print_some()
87 ui->out(F("%s = %s") % (*match).first % (*match).second); in print_some()
107 /// \param ui Object to interact with the I/O of the program.
114 cmd_config::run(cmdline::ui* ui, const cmdline::parsed_cmdline& cmdline, in run() argument
[all …]
H A Dcmd_list.cpp44 #include "utils/cmdline/ui.hpp"
59 /// The ui object to which to print the test cases.
60 cmdline::ui* _ui;
68 /// \param ui_ The ui object to which to print the test cases.
70 progress_hooks(cmdline::ui* ui_, const bool verbose_) : in progress_hooks()
95 /// \param [out] ui Object to interact with the I/O of the program.
100 cli::detail::list_test_case(cmdline::ui* ui, const bool verbose, in list_test_case() argument
108 ui->out(id); in list_test_case()
110 ui->out(F("%s (%s)") % id % test_program.test_suite_name()); in list_test_case()
126 ui->out(F(" %s = %s") % (*iter).first % (*iter).second); in list_test_case()
[all …]
/freebsd/crypto/openssl/apps/lib/
H A Dapps_ui.c12 #include <openssl/ui.h>
18 static int ui_open(UI *ui) in ui_open() argument
20 int (*opener)(UI *ui) = UI_method_get_opener(ui_base_method); in ui_open()
23 return opener(ui); in ui_open()
27 static int ui_read(UI *ui, UI_STRING *uis) in ui_read() argument
29 int (*reader)(UI *ui, UI_STRING *uis) = NULL; in ui_read()
32 && UI_get0_user_data(ui)) { in ui_read()
38 ((PW_CB_DATA *)UI_get0_user_data(ui))->password; in ui_read()
41 UI_set_result(ui, uis, password); in ui_read()
56 return reader(ui, uis); in ui_read()
[all …]
/freebsd/crypto/openssl/include/openssl/
H A Dui.h.in54 UI *UI_new(void);
55 UI *UI_new_method(const UI_METHOD *method);
56 void UI_free(UI *ui);
82 All of the functions in this group take a UI and a prompt string.
101 int UI_add_input_string(UI *ui, const char *prompt, int flags,
103 int UI_dup_input_string(UI *ui, const char *prompt, int flags,
105 int UI_add_verify_string(UI *ui, const char *prompt, int flags,
108 int UI_dup_verify_string(UI *ui, const char *prompt, int flags,
111 int UI_add_input_boolean(UI *ui, const char *prompt, const char *action_desc,
114 int UI_dup_input_boolean(UI *ui, const char *prompt, const char *action_desc,
[all …]
H A Dui.h3 * Generated by Makefile from include/openssl/ui.h.in
53 UI *UI_new(void);
54 UI *UI_new_method(const UI_METHOD *method);
55 void UI_free(UI *ui);
81 All of the functions in this group take a UI and a prompt string.
100 int UI_add_input_string(UI *ui, const char *prompt, int flags,
102 int UI_dup_input_string(UI *ui, const char *prompt, int flags,
104 int UI_add_verify_string(UI *ui, const char *prompt, int flags,
107 int UI_dup_verify_string(UI *ui, const char *prompt, int flags,
110 int UI_add_input_boolean(UI *ui, const char *prompt, const char *action_desc,
[all …]
/freebsd/crypto/openssl/test/
H A Duitest.c18 #include <openssl/ui.h>
28 * Test wrapping old style PEM password callback in a UI method through the
29 * use of UI utility functions
34 UI *ui = NULL; in test_old() local
41 || !TEST_ptr(ui = UI_new_method(ui_method))) in test_old()
44 /* The wrapper passes the UI userdata as the callback userdata param */ in test_old()
45 UI_add_user_data(ui, defpass); in test_old()
47 if (UI_add_input_string(ui, "prompt", UI_INPUT_FLAG_DEFAULT_PWD, in test_old()
51 switch (UI_process(ui)) { in test_old()
53 TEST_info("test_old: UI process interrupted or cancelled"); in test_old()
[all …]
/freebsd/contrib/tcpdump/
H A Dprint-tftp.c91 u_int ui; in tftp_print() local
121 ui = nd_printztn(ndo, bp, length, ndo->ndo_snapend); in tftp_print()
123 if (ui == 0) in tftp_print()
125 bp += ui; in tftp_print()
126 length -= ui; in tftp_print()
132 ui = nd_printztn(ndo, bp, length, ndo->ndo_snapend); in tftp_print()
133 if (ui == 0) in tftp_print()
135 bp += ui; in tftp_print()
136 length -= ui; in tftp_print()
142 ui = nd_printztn(ndo, bp, length, ndo->ndo_snapend); in tftp_print()
[all …]

12345678910>>...16