Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm making an unattended install of windows. Part of it is installing virtualbox guest additions, which is run by the installer due to the following entry in Autounattend.xml:

<?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend">
  ...
  <settings pass="oobeSystem">
    ...
    <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="x86" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="NonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
      ...
      <FirstLogonCommands>
        <SynchronousCommand>
          <Order>30</Order>
          <Description>VirtualBox Additions</Description>
          <CommandLine>F:\VBoxWindowsAdditions-x86.exe /S</CommandLine>
        </SynchronousCommand>
        ...

It runs fine, installing with no GUI. However, two windows pop up asking whether to install two device drivers. This does not bode well for an automated install. Is there any way to force win7 to accept the drivers, or a registry key I can set to make it trust them?

share|improve this question

1 Answer 1

Your best shot at avoiding those prompts is to grab the required certificates the device drivers are signed with and install those on the guest prior to installation. You can find a certificate for Sun and one for Oracle in the Local Computer -> Trusted Publisher certificate store. You can easily export them from there and then import them into the guest prior to installing the additions.

To extract the certificate from a machine that already has installed and trusted the certificate(s) used for signing the device drivers using PowerShell:

cd cert:\LocalMachine\TrustedPublisher
$cert = dir | where { $_.Subject -like "*Oracle*" }
$type = [System.Security.Cryptography.X509Certificates.X509ContentType]::Cert
$bytes = $cert.Export($type)
[System.IO.File]::WriteAllBytes("C:\Oracle.cer", $bytes)

You may want to run the above command and replace *Oracle* with *Sun Microsystems* and capture both certificates, so they can both be present so you can be a bit more version independent with VirtualBox. Just make sure these certificates are installed prior to your unattended installation of the guest additions.

share|improve this answer
    
More info about this approach at migee.com/2010/09/24/… –  John May 26 '12 at 8:39

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.