apps/openssl.c: Adapt to enable tracing output
authorRichard Levitte <levitte@openssl.org>
Fri, 14 Dec 2018 14:48:53 +0000 (15:48 +0100)
committerRichard Levitte <levitte@openssl.org>
Wed, 6 Mar 2019 10:15:13 +0000 (11:15 +0100)
commit682b444f8a78b8902a3521cd6486bdecb766e5e5
tree9ee3ace3f57a381e85a73f1c1874bcca262bf839
parent2390c573aa598b715eb592c9b4da50a71453347a
apps/openssl.c: Adapt to enable tracing output

Use the environment variables OPENSSL_TRACE to determine what's going
to be enabled.  The value of this variables is a comma separated list
of trace and debugging names, which correspond to the trace category
macros defined in include/openssl/trace.h.

For example, setting OPENSSL_DEBUG=TRACE,SSL will enable debugging output
for the types OSSL_TRACE_CATEGORY_TRACE and OSSL_TRACE_CATEGORY_SSL.

This also slightly changes the handling of the prefix method in
apps/apps.c.  This is for the better, as the prefix method pointer was
unneccessarily stored in two places.

Co-authored-by: Dr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/8198)
apps/apps.c
apps/openssl.c