Latest update, add TLS 1.3 session time configuration.

This commit is contained in:
2019-04-13 23:25:53 +09:00
parent 48ec086472
commit 704c3822e0
166 changed files with 3539 additions and 1083 deletions
+16 -4
View File
@@ -52,21 +52,33 @@ static int p_get_params(const OSSL_PROVIDER *prov, OSSL_PARAM params[])
if (strcmp(p->key, "greeting") == 0) {
static char *opensslv = NULL;
static char *provname = NULL;
static char *greeting = NULL;
static OSSL_PARAM counter_request[] = {
/* Known libcrypto provided parameters */
{ "openssl-version", OSSL_PARAM_UTF8_PTR,
&opensslv, sizeof(&opensslv), NULL },
{ "provider-name", OSSL_PARAM_UTF8_PTR,
&provname, sizeof(&provname), NULL},
/* This might be present, if there's such a configuration */
{ "greeting", OSSL_PARAM_UTF8_PTR,
&greeting, sizeof(&greeting), NULL },
{ NULL, 0, NULL, 0, NULL }
};
char buf[256];
size_t buf_l;
if (c_get_params(prov, counter_request)) {
const char *versionp = *(void **)counter_request[0].data;
const char *namep = *(void **)counter_request[1].data;
sprintf(buf, "Hello OpenSSL %.20s, greetings from %s!",
versionp, namep);
if (greeting) {
strcpy(buf, greeting);
} else {
const char *versionp = *(void **)counter_request[0].data;
const char *namep = *(void **)counter_request[1].data;
sprintf(buf, "Hello OpenSSL %.20s, greetings from %s!",
versionp, namep);
}
} else {
sprintf(buf, "Howdy stranger...");
}