Import OpenSSL 1.1.1l

This commit is contained in:
Steve Dower
2021-08-26 19:30:20 +01:00
parent b439f09b29
commit b123b12c0d
104 changed files with 2011 additions and 524 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
* Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -34,6 +34,9 @@
#if defined(__OpenBSD__)
# include <sys/param.h>
#endif
#if defined(__APPLE__)
# include <CommonCrypto/CommonRandom.h>
#endif
#if defined(OPENSSL_SYS_UNIX) || defined(__DJGPP__)
# include <sys/types.h>
@@ -378,6 +381,11 @@ static ssize_t syscall_random(void *buf, size_t buflen)
if (errno != ENOSYS)
return -1;
}
# elif defined(__APPLE__)
if (CCRandomGenerateBytes(buf, buflen) == kCCSuccess)
return (ssize_t)buflen;
return -1;
# else
union {
void *p;