VirtualBox

Changeset 100447 in vbox


Ignore:
Timestamp:
Jul 8, 2023 6:50:27 PM (17 months ago)
Author:
vboxsync
Message:

IPRT,OpenSSL: Support ECDSA for verficiation purposes when IPRT links with OpenSSL. This required quite a bit of cleanups, so not entirely no-risk. [build fix for older OpenSSL] bugref:10479 ticketref:21621

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/err.h

    r100442 r100447  
    22702270/** @name RTCr misc status codes.
    22712271 * @{ */
     2272/** The OpenSSL version is too old for the attempted operation. */
     2273#define VERR_CR_OPENSSL_VERSION_TOO_OLD             (-24395)
    22722274/** Failed to derivate key from password. */
    22732275#define VERR_CR_PASSWORD_2_KEY_DERIVIATION_FAILED   (-24396)
  • trunk/src/VBox/Runtime/common/crypto/key-openssl.cpp

    r100445 r100447  
    9595         *        with older openssl versions atm.  Fortunately we only really needs
    9696         *        it on Windows atm., so no problem. */
    97         rc = RTERRINFO_LOG_SET_F(pErrInfo, VERR_NOT_SUPPORTED,
     97        rc = RTERRINFO_LOG_SET_F(pErrInfo, VERR_CR_OPENSSL_VERSION_TOO_OLD,
    9898                                 "OpenSSL version %#x is too old for IPRTs ECDSA code", OPENSSL_VERSION_NUMBER);
     99        RT_NOREF(idKeyType, ppEvpNewKey);
    99100#endif
    100101    }
  • trunk/src/VBox/Runtime/common/crypto/pkix-signature-ossl.cpp

    r100446 r100447  
    151151    RT_NOREF_PV(pThis);
    152152
    153 #if 1
     153#if OPENSSL_VERSION_NUMBER >= 0x30000000 && !defined(LIBRESSL_VERSION_NUMBER)
    154154    PRTERRINFO const pErrInfo = NULL;
    155155
     
    220220#else
    221221    RT_NOREF(pDesc, pvState, hKey, hDigest, pvSignature, cbSignature);
    222     return VERR_NOT_IMPLEMENTED;
     222    return VERR_CR_OPENSSL_VERSION_TOO_OLD;
    223223#endif
    224224}
Note: See TracChangeset for help on using the changeset viewer.

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