diff options
Diffstat (limited to 'third_party/usrsctp/overrides/usrsctplib/netinet/sctp_sha1.h')
-rw-r--r-- | third_party/usrsctp/overrides/usrsctplib/netinet/sctp_sha1.h | 29 |
1 files changed, 24 insertions, 5 deletions
diff --git a/third_party/usrsctp/overrides/usrsctplib/netinet/sctp_sha1.h b/third_party/usrsctp/overrides/usrsctplib/netinet/sctp_sha1.h index 4000e41..006e920 100644 --- a/third_party/usrsctp/overrides/usrsctplib/netinet/sctp_sha1.h +++ b/third_party/usrsctp/overrides/usrsctplib/netinet/sctp_sha1.h @@ -40,11 +40,30 @@ __FBSDID("$FreeBSD$"); #define __SCTP_SHA1_h__ #include <sys/types.h> -#ifdef SCTP_USE_NSS_SHA1 + +#if !defined(SSL_USE_OPENSSL) && !defined(SSL_USE_NSS) +#if defined(WIN32) + +#define SCTP_USE_SCTP_SHA1 1 + +#else // defined(WIN32) + +#if defined(HAVE_OPENSSL_SSL_H) +#define SSL_USE_OPENSSL 1 +#elif defined(HAVE_NSS_SSL_H) +#define SSL_USE_NSS 1 +#else +#define SCTP_USE_SCTP_SHA1 +#endif + +#endif // !defined(WIN32) +#endif + +#if defined(SSL_USE_NSS) #include <netinet/sctp_nss_sha1.h> -#elif SCTP_USE_OPENSSL_SHA1 +#elif defined(SSL_USE_OPENSSL) #include <netinet/sctp_openssl_sha1.h> -#else // USE_SCTP_SHA1 +#else // SCTP_USE_SCTP_SHA1 struct sha1_context { unsigned int A; unsigned int B; @@ -99,5 +118,5 @@ void SHA1_Update(struct sha1_context *, const unsigned char *, int); void SHA1_Final(unsigned char *, struct sha1_context *); #endif /* _KERNEL */ -#endif -#endif +#endif /* !defined(SSL_USE_OPENSSL) && !defined(SSL_USE_NSS) */ +#endif /* __SCTP_SHA1_h__ */ |