VirtualBox

Changeset 95696 in vbox


Ignore:
Timestamp:
Jul 18, 2022 9:07:10 AM (2 years ago)
Author:
vboxsync
Message:

Installer/win/VBoxStub: Install the legacy windows timestamp CA if used by the build and needed by the install target. bugref:8691

Location:
trunk/src/VBox/Installer/win/Stub
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Installer/win/Stub/Makefile.kmk

    r94352 r95696  
    6767 VBoxStub.cpp_INCS += $(VBoxStub_0_OUTDIR)
    6868 VBoxStub.cpp_DEFS += VBOX_WITH_CODE_SIGNING
     69 ifdef VBOX_WITH_VBOX_LEGACY_TS_CA
     70  VBoxStub.cpp_DEFS += VBOX_WITH_VBOX_LEGACY_TS_CA
     71 endif
    6972
    7073 $$(VBoxStub_0_OUTDIR)/VBoxStubPublicCert.h:  | $$(dir $$@) $(VBOX_RTSIGNTOOL) $(PATH_STAGE_SYS)/VBoxSup.sys
     
    9295              "};"
    9396        $(RM) -f -- "[email protected]" "[email protected]" "[email protected]" "[email protected]"
     97 ifdef VBOX_WITH_VBOX_LEGACY_TS_CA
     98        $(VBOX_BIN2C) -ascii --append VBoxLegacyWinCA "$(VBOX_LEGACY_TS_CA_FILE)" $@
     99 endif
    94100
    95101 VBoxStubPublicCert.h:: $$(VBoxStub_0_OUTDIR)/VBoxStubPublicCert.h
  • trunk/src/VBox/Installer/win/Stub/VBoxStub.cpp

    r95030 r95696  
    4949#include <iprt/stream.h>
    5050#include <iprt/string.h>
     51#include <iprt/system.h>
    5152#include <iprt/thread.h>
    5253#include <iprt/utf16.h>
     
    822823            return ShowError("Failed to construct install certificate.");
    823824    }
     825
     826# ifdef VBOX_WITH_VBOX_LEGACY_TS_CA
     827    if (   RTSystemGetNtVersion() < RTSYSTEM_MAKE_NT_VERSION(10, 0, 0)
     828        || false /** @todo windows server 2016 and later */ )
     829    {
     830        if (!addCertToStore(CERT_SYSTEM_STORE_LOCAL_MACHINE, "Root", g_abVBoxLegacyWinCA, sizeof(g_abVBoxLegacyWinCA)))
     831            return ShowError("Failed to construct install certificate.");
     832    }
     833# endif
    824834    return RTEXITCODE_SUCCESS;
    825835}
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