Remove a host of incorrect OPENSSL_IS_BORINGSSL ifdefs

The <openssl/buf.h> include is neccessary in both OpenSSL and BoringSSL
because the file uses BUF_MEM (IWYU). It's just that OpenSSL spells it
<openssl/buffer.h>, not matching the type, so use the compatible
spelling.

Additionally all the CHECKED_CAST and manual STACK_OF(T) definitions are
calling into BoringSSL internals that we were only keeping around for
compatible with wpa_supplicant's incorrect use of the APIs. The correct
APIs are simply to just use the same code as OpenSSL and call the
DEFINE_STACK_OF macros.

(tls_openssl_ocsp.c needs to be rewritten entirely later, as the use of
<openssl/asn1t.h> is also quite dangerous, but I've left that alone for
now.)

Test: treehugger
Change-Id: Id923db6513f9e2833854322994aa3a113ee1579d
3 files changed