VirtualBox

Changeset 41887 in vbox for trunk


Ignore:
Timestamp:
Jun 22, 2012 2:06:22 PM (13 years ago)
Author:
vboxsync
Message:

Runtime: introduced RTRandAdvCreateOpenssl()

Location:
trunk
Files:
2 added
5 edited

Legend:

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

    r41551 r41887  
    10211021# define RTRandAdvCreateSystemFaster                    RT_MANGLER(RTRandAdvCreateSystemFaster)
    10221022# define RTRandAdvCreateSystemTruer                     RT_MANGLER(RTRandAdvCreateSystemTruer)
     1023# define RTRandAdvCreateOpenssl                         RT_MANGLER(RTRandAdvCreateOpenssl)
    10231024# define RTRandAdvDestroy                               RT_MANGLER(RTRandAdvDestroy)
    10241025# define RTRandAdvRestoreState                          RT_MANGLER(RTRandAdvRestoreState)
  • trunk/include/iprt/rand.h

    r33540 r41887  
    151151
    152152/**
     153 * Create an instance of the openssl random number generator.
     154 *
     155 * @returns IPRT status code.
     156 * @retval  VERR_NOT_SUPPORTED on platforms which doesn't have this feature.
     157 *
     158 * @param   phRand      Where to store the handle to the generator.
     159 *
     160 */
     161RTDECL(int) RTRandAdvCreateOpenssl(PRTRAND phRand) RT_NO_THROW;
     162
     163/**
    153164 * Create an instance of the truer random number generator for the OS.
    154165 *
  • trunk/src/VBox/Runtime/Makefile.kmk

    r41549 r41887  
    364364        common/rand/randadv.cpp \
    365365        common/rand/randparkmiller.cpp \
     366        common/rand/randopenssl.cpp \
    366367        common/sort/RTSortIsSorted.cpp \
    367368        common/sort/RTSortApvIsSorted.cpp \
     
    10291030RuntimeBldProg_BLD_TRG_ARCH     := $(KBUILD_HOST_ARCH)
    10301031RuntimeBldProg_BLD_TRG_CPU      := $(KBUILD_HOST_CPU)
     1032RuntimeBldProg_SOURCES          := $(filter-out \
     1033        common/rand/randopenssl.cpp \
     1034        , $(RuntimeR3_SOURCES))
     1035RuntimeBldProg_SOURCES          += \
     1036        generic/RTRandAdvCreateOpenssl-generic.cpp
    10311037
    10321038
     
    10511057        common/checksum/RTSha1Digest.cpp \
    10521058        common/checksum/sha% \
     1059        common/rand/randopenssl.cpp \
    10531060        generic/RTLogWriteUser-generic.cpp \
    10541061        , $(RuntimeR3_SOURCES))
    10551062RuntimeGuestR3_SOURCES              += \
    10561063        common/time/timesysalias.cpp \
    1057         VBox/logbackdoor.cpp
     1064        VBox/logbackdoor.cpp \
     1065        generic/RTRandAdvCreateOpenssl-generic.cpp
    10581066RuntimeGuestR3_SOURCES.$(KBUILD_TARGET)      := $(RuntimeR3_SOURCES.$(KBUILD_TARGET))
    10591067RuntimeGuestR3_SOURCES.$(KBUILD_HOST)        := $(RuntimeR3_SOURCES.$(KBUILD_HOST))
  • trunk/src/VBox/Runtime/common/rand/rand.cpp

    r40798 r41887  
    6262{
    6363    RTRAND hRand;
    64     int rc = RTRandAdvCreateSystemFaster(&hRand);
     64    int rc = RTRandAdvCreateOpenssl(&hRand);
     65    if (RT_FAILURE(rc))
     66        rc = RTRandAdvCreateSystemFaster(&hRand);
    6567    if (RT_FAILURE(rc))
    6668        rc = RTRandAdvCreateParkMiller(&hRand);
  • trunk/src/VBox/Storage/testcase/Makefile.kmk

    r41576 r41887  
    7777 vbox-img_TEMPLATE = VBOXR3STATIC
    7878 vbox-img_DEFS += IN_VBOXDDU IN_VBOXDDU_STATIC VBOX_HDD_NO_DYNAMIC_BACKENDS IN_RT_R3
     79 vbox-img_SDKS = VBOX_OPENSSL
    7980 vbox-img_SOURCES = \
    8081        vbox-img.cpp \
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