X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=ssl%2Fssl_txt.c;h=06b86750fdb550b1929e91c665c46152bbcb53db;hb=4e319926d7cb80313d37105b5545fcce28fdddc1;hp=40b76b1b2692c21fbffc43c5ef4758d1d50ccddb;hpb=98fa4fe8c54a0f717829e894e8c8528c4a8dd4fe;p=oweals%2Fopenssl.git diff --git a/ssl/ssl_txt.c b/ssl/ssl_txt.c index 40b76b1b26..06b86750fd 100644 --- a/ssl/ssl_txt.c +++ b/ssl/ssl_txt.c @@ -61,7 +61,7 @@ #include "ssl_locl.h" #ifndef OPENSSL_NO_FP_API -int SSL_SESSION_print_fp(FILE *fp, SSL_SESSION *x) +int SSL_SESSION_print_fp(FILE *fp, const SSL_SESSION *x) { BIO *b; int ret; @@ -78,10 +78,10 @@ int SSL_SESSION_print_fp(FILE *fp, SSL_SESSION *x) } #endif -int SSL_SESSION_print(BIO *bp, SSL_SESSION *x) +int SSL_SESSION_print(BIO *bp, const SSL_SESSION *x) { unsigned int i; - char *s; + const char *s; if (x == NULL) goto err; if (BIO_puts(bp,"SSL-Session:\n") <= 0) goto err; @@ -151,9 +151,25 @@ int SSL_SESSION_print(BIO *bp, SSL_SESSION *x) if (BIO_printf(bp,"%02X",x->krb5_client_princ[i]) <= 0) goto err; } #endif /* OPENSSL_NO_KRB5 */ +#ifndef OPENSSL_NO_TLSEXT + if (x->tlsext_tick_lifetime_hint) + { + if (BIO_printf(bp, + "\n TLS session ticket lifetime hint: %ld (seconds)", + x->tlsext_tick_lifetime_hint) <=0) + goto err; + } + if (x->tlsext_tick) + { + if (BIO_puts(bp, "\n TLS session ticket:\n") <= 0) goto err; + if (BIO_dump_indent(bp, (char *)x->tlsext_tick, x->tlsext_ticklen, 4) <= 0) + goto err; + } +#endif +#ifndef OPENSSL_NO_COMP if (x->compress_meth != 0) { - SSL_COMP *comp; + SSL_COMP *comp = NULL; ssl_cipher_get_evp(x,NULL,NULL,&comp); if (comp == NULL) @@ -165,6 +181,7 @@ int SSL_SESSION_print(BIO *bp, SSL_SESSION *x) if (BIO_printf(bp,"\n Compression: %d (%s)", comp->id,comp->method->name) <= 0) goto err; } } +#endif if (x->time != 0L) { if (BIO_printf(bp, "\n Start Time: %ld",x->time) <= 0) goto err;