VirtualBox

Changeset 105920 in vbox for trunk/src/libs


Ignore:
Timestamp:
Sep 2, 2024 5:00:53 PM (7 months ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
164651
Message:

openssl-3.3.1: making it build. bugref:10757

Location:
trunk/src/libs/openssl-3.3.1
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/libs/openssl-3.3.1/Config.kmk

    r105918 r105920  
    4242
    4343# Can't use relative paths when dealing with sub-makefiles.
    44 VBOX_PATH_OPENSSL           := $(PATH_ROOT)/src/libs/openssl-3.1.5
     44VBOX_PATH_OPENSSL           := $(PATH_ROOT)/src/libs/openssl-3.3.1
    4545VBOX_PATH_CRYPTO            := $(VBOX_PATH_OPENSSL)/crypto
    4646VBOX_PATH_CRYPTO_GENASM     := $(VBOX_PATH_CRYPTO)/genasm-$(VBOX_CRYPTO_ASM_SCHEME)
     
    5656VBOX_PATH_CRYPTO_DES        := $(VBOX_PATH_CRYPTO)/des
    5757VBOX_PATH_CRYPTO_CAMELLIA   := $(VBOX_PATH_CRYPTO)/camellia
    58 VBOX_INST_CRYPTO_HEADERS    := obj/$(if-expr "$(CURSUBDIR)" == ".",,$(CURSUBDIR)/)crypto-3.1.5-headers/include/openssl/
     58VBOX_INST_CRYPTO_HEADERS    := obj/$(if-expr "$(CURSUBDIR)" == ".",,$(CURSUBDIR)/)crypto-3.3.1-headers/include/openssl/
    5959VBOX_PATH_CRYPTO_HEADERS    := $(abspath $(PATH_OUT))/$(patsubst %/,%,$(VBOX_INST_CRYPTO_HEADERS))
    6060VBOX_PATH_CRYPTO_PROVIDERS  := $(VBOX_PATH_OPENSSL)/providers
  • trunk/src/libs/openssl-3.3.1/include/internal/cryptlib.h

    r105918 r105920  
    11/*
    2  * Copyright 1995-2022 The OpenSSL Project Authors. All Rights Reserved.
     2 * Copyright 1995-2023 The OpenSSL Project Authors. All Rights Reserved.
    33 *
    44 * Licensed under the Apache License 2.0 (the "License").  You may not use
     
    1414# endif                                                                                                 /* VBOX */
    1515
    16 # include <stdlib.h>
    17 # include <string.h>
    18 
    1916# ifdef OPENSSL_USE_APPLINK
    2017#  define BIO_FLAGS_UPLINK_INTERNAL 0x8000
     
    2421# endif
    2522
     23# include "internal/common.h"
     24
    2625# include <openssl/crypto.h>
    2726# include <openssl/buffer.h>
     
    2928# include <openssl/asn1.h>
    3029# include <openssl/err.h>
    31 # include "internal/nelem.h"
    32 
    33 #ifdef NDEBUG
    34 # define ossl_assert(x) ((x) != 0)
    35 #else
    36 __owur static ossl_inline int ossl_assert_int(int expr, const char *exprstr,
    37                                               const char *file, int line)
    38 {
    39     if (!expr)
    40         OPENSSL_die(exprstr, file, line);
    41 
    42     return expr;
    43 }
    44 
    45 # define ossl_assert(x) ossl_assert_int((x) != 0, "Assertion failed: "#x, \
    46                                          __FILE__, __LINE__)
    47 
    48 #endif
    49 
    50 /*
    51  * Use this inside a union with the field that needs to be aligned to a
    52  * reasonable boundary for the platform.  The most pessimistic alignment
    53  * of the listed types will be used by the compiler.
    54  */
    55 # define OSSL_UNION_ALIGN       \
    56     double align;               \
    57     ossl_uintmax_t align_int;   \
    58     void *align_ptr
    5930
    6031typedef struct ex_callback_st EX_CALLBACK;
     
    6334typedef struct mem_st MEM;
    6435DEFINE_LHASH_OF_EX(MEM);
    65 
    66 #define OPENSSLDIR "/usr/local/ssl"
    67 
    68 # define OPENSSL_CONF             "openssl.cnf"
    69 
    70 # ifndef OPENSSL_SYS_VMS
    71 #  define X509_CERT_AREA          OPENSSLDIR
    72 #  define X509_CERT_DIR           OPENSSLDIR "/certs"
    73 #  define X509_CERT_FILE          OPENSSLDIR "/cert.pem"
    74 #  define X509_PRIVATE_DIR        OPENSSLDIR "/private"
    75 #  define CTLOG_FILE              OPENSSLDIR "/ct_log_list.cnf"
    76 # else
    77 #  define X509_CERT_AREA          "OSSL$DATAROOT:[000000]"
    78 #  define X509_CERT_DIR           "OSSL$DATAROOT:[CERTS]"
    79 #  define X509_CERT_FILE          "OSSL$DATAROOT:[000000]cert.pem"
    80 #  define X509_PRIVATE_DIR        "OSSL$DATAROOT:[PRIVATE]"
    81 #  define CTLOG_FILE              "OSSL$DATAROOT:[000000]ct_log_list.cnf"
    82 # endif
    83 
    84 # define X509_CERT_DIR_EVP        "SSL_CERT_DIR"
    85 # define X509_CERT_FILE_EVP       "SSL_CERT_FILE"
    86 # define CTLOG_FILE_EVP           "CTLOG_FILE"
    87 
    88 /* size of string representations */
    89 # define DECIMAL_SIZE(type)      ((sizeof(type)*8+2)/3+1)
    90 # define HEX_SIZE(type)          (sizeof(type)*2)
    9136
    9237void OPENSSL_cpuid_setup(void);
     
    173118# define OSSL_LIB_CTX_BIO_CORE_INDEX                17
    174119# define OSSL_LIB_CTX_CHILD_PROVIDER_INDEX          18
    175 # define OSSL_LIB_CTX_MAX_INDEXES                   19
     120# define OSSL_LIB_CTX_THREAD_INDEX                  19
     121# define OSSL_LIB_CTX_DECODER_CACHE_INDEX           20
     122# define OSSL_LIB_CTX_MAX_INDEXES                   20
    176123
    177124OSSL_LIB_CTX *ossl_lib_ctx_get_concrete(OSSL_LIB_CTX *ctx);
     
    216163                                   const char sep);
    217164
    218 static ossl_inline int ossl_ends_with_dirsep(const char *path)
    219 {
    220     if (*path != '\0')
    221         path += strlen(path) - 1;
    222 # if defined __VMS
    223     if (*path == ']' || *path == '>' || *path == ':')
    224         return 1;
    225 # elif defined _WIN32
    226     if (*path == '\\')
    227         return 1;
    228 # endif
    229     return *path == '/';
    230 }
    231 
    232 static ossl_inline int ossl_is_absolute_path(const char *path)
    233 {
    234 # if defined __VMS
    235     if (strchr(path, ':') != NULL
    236         || ((path[0] == '[' || path[0] == '<')
    237             && path[1] != '.' && path[1] != '-'
    238             && path[1] != ']' && path[1] != '>'))
    239         return 1;
    240 # elif defined _WIN32
    241     if (path[0] == '\\'
    242         || (path[0] != '\0' && path[1] == ':'))
    243         return 1;
    244 # endif
    245     return path[0] == '/';
    246 }
    247 
    248165#endif
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette