VirtualBox: Multiple CustomTables?

Discussion in 'Virtualization' started by jcap511, Feb 6, 2014.

  1. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    Hey all,

    Been a lurker here for quite a while, usually don't want to contribute to floods of noob questions. Enough browsing and searching typically will lead me to answers on here. But I've been trying to figure this out for a couple days now and can't, so I'm finally posting :p

    So... VirtualBox can load an SLIC table easily with the VBoxManage tool using
    VBoxManage setextradata "vm name" "VBoxInternal/Devices/acpi/0/Config/CustomTable" "path to slic.bin"

    This works great for the purposes of Windows 7 OEM Licenses, etc.
    The Windows 8 generation uses the MSDM table, this can also be loaded via VBoxManage.

    However as far as I can tell, VBox only allows for one "CustomTable" (slic OR msdm). In certain cases, specifically Windows Server 2012 R2, it would be ideal to have both SLIC and MSDM tables as it seems this may help the 1058 event problem.

    So I'm thinking either there is some configuration method in VBox that would allow me to load a "SLIC.bin" and a "MSDM.bin" separately or some way to combine them together into a single "SLIC&MSDM.bin" file.

    I've tried smashing them together with a Hex Editor, but I don't have much of an understanding of how ACPI tables are defined or separated. When I try to just append the data from one to the other in a single file, it seems only the first table gets passed through. (So if I take SLIC.bin data and append it to a MSDM.bin, I only get a MSDM table in the VM).

    Anyways, that is where I am stuck. Any thoughts?
    Thanks in advance.
     
  2. kelorgo

    kelorgo MDL Addicted

    Oct 29, 2012
    838
    1,499
    30
    #2 kelorgo, Feb 6, 2014
    Last edited by a moderator: Apr 20, 2017
    Unfortunately there are no standard configuration options that allow you to specify more than one ACPI table.

    There is an undocumented option that allows you to load an entire alternate BIOS:
    Code:
    VBoxMange setextradata <vm-name> "VBoxInternal/Devices/pcbios/0/Config/BiosRom" <pcbios.bin>
    where pcbios.bin is the path and name of an alternate BIOS. In theory, if you can get hold of the BIOS normally used by VirtualBox, you could mod it to include two or more ACPI tables. The difficulty with this approach is that it is not easy to get hold of the BIOS in the first place.
     
  3. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    Oh cool, I didn't know about the BiosRom option, thanks!
    Speaking in theory again, couldn't one dump the vbox bios from inside the vm with RW-Everything?
     
  4. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    I was able to dump the bios from inside virtualbox. It's only 64k and it seems there is a 64k limit on the size of the file that can be passed in with the BiosRom option. I really don't have the expertise to mod this myself and I'm not even sure it's possible because VBox seems to construct the ACPI tables separately? (sorry for being vague my understanding of this is not clear yet).

    I also found something else interesting. Looking into other ways to get an SLIC table into VBox, I made an SLIC rom with WindSLIC (the PCI Rom version) and loaded it using
    vboxmanage.exe setextradata VM_NAME VBoxInternal/Devices/pcbios/0/Config/LanBootRom windslic.bin
    I made the rom with the Dell SLIC 2.3 as I am trying this all out with a Windows 2012R2 VM. This sort of worked. With RW-Everything I can see the SLIC 2.3 table in the ACPI tables. However, Windows would no activate.

    In short, SLIC 2.3 in VBox via CustomTable will activate Win2012r2 via OEM:SLP but when passed in via LanBootRom, it does not. Even though with both methods I can see the SLIC table in RW-Everything. So I guess this means OEM:SLP activation with SLIC 2.3 is more sensitive about location and loaders than SLIC 2.1?
     
  5. kelorgo

    kelorgo MDL Addicted

    Oct 29, 2012
    838
    1,499
    30
    Well done for dumping the BIOS from inside the VM. Did you try to load that BIOS with the BiosRom option, and did it work? There are two alternative ways to get hold of it that I know of. One is to grab it out of the VirtualBox binaries, but I don't remember which file contains it and its location of course changes with every update. The other option is to try and compile it yourself. The entire source for the BIOS is included in the VirtualBox source that you can download, but it's complicated to set up a proper build environment so I never got as far as successfully compiling it.

    Interesting approach with WindSLIC and the LanBootRom option, thanks for pointing that out.

    I don't know enough about the structures of ACPI tables, but to me it would make sense for MS to try and make things as sensitive to location as possible. I am just guessing here as well.
     
  6. Tito

    Tito Super Mod / Adviser
    Staff Member

    Nov 30, 2009
    17,647
    15,576
    340
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  7. Daz

    Daz MDL Developer / Admin
    Staff Member

    Jul 31, 2009
    9,490
    66,580
    300
    With Windows Server 2012 and up if the RSDP is relocated to the EBDA then Windows won't pass as genuine.

    I think WindSLIC supports chipset lockpicking, so change the VM's chipset to ICH9.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  8. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    Thanks for the replies!

    I dumped the VBox bios using a Win98 bootdisk and the debug command.
    (found instructions here: hannacomputer.wordpress. com/tag/custom-virtualbox-bios/)
    The result is a 64k bin file, which I'll attach. If I take the bin file and use it via the BiosRom option it works just as if I was using the default bios. So theoretically if this bios file could be SLIC and/or MSDM modded, one might not even need to use CustomTable at all! But bios modding is way outside my skill-set as of now o_O. Perhaps a modder would be interested?


    Hey Daz, I tried out your suggestion, switched the VM to ICH9 and enabled lock-picking for WindSLIC, but I don't think it worked. Windows doesn't activate for sure. I think the SLIC table ended up at the same address as without lock-pick.
    How can I tell which memory space (EBDA, etc.) the table is in?

    In case anyone is interested I'll attach a RW-Everything export of the acpi tables, maybe I'm missing something dumb. :p
     

    Attached Files:

  9. Daz

    Daz MDL Developer / Admin
    Staff Member

    Jul 31, 2009
    9,490
    66,580
    300
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  10. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    Some more experiments...
    After switching WindSLIC to a verbose mode I could see more of what is happening. Turns out when I switched the chipset to ICH9, the windslic lock-pick failed to "Recognize PCI Root Dev for Lockpick Attempt." When I leave it on the default PIIX3, it recognizes it as an "Intel 440-era chipset." However it still moves the RSDP into EBDA. So the normal address (no windslic) for the RSDP is 0x00000000000E0000, with windslic it moves to 0x000000000009FC10, and with lockpick enabled it still ends up at 0x000000000009FC10. So it seems the lockpick simply isn't doing anything.

    Btw, similarly to how you have it working with your unreleased loader, I can just use VBox's CustomTable option to get 2012r2 activated. But like others I get the 1058 event error. I know this doesn't seem to affect anything in terms of practical use, but many have said that having a msdm table will get rid of these events and I wanted to test this out. Since CustomTable only lets me load a single acpi table, my idea was to use an alternative method of getting an SLIC table, so that I could use CustomTable to load the MSDM table.

    I'm not asking for a copy. I can wait like everyone else :p. Just hypothetically speaking though, if I used your new loader for the slic injection then I could use CustomTable for the msdm and accomplish my goal.
    But I totally understand and agree with your reasons for not releasing it yet. Bob's tool-whose-name-shall-remain-unspoken has been both a gift and a curse.
     
  11. Daz

    Daz MDL Developer / Admin
    Staff Member

    Jul 31, 2009
    9,490
    66,580
    300
    That's true, but the reason I don't inject both with the loader is because it would then reduce the loaders compatibility. For example, I can activate most systems with an Intel chipset, but if you don't have an Intel chipset then your system needs to have an existing SLIC (any version) so that the RSDP doesn't require an update. So if I were to inject an MSDM too then the RSDP would require an update, which means that the loader would no longer be able to activate anyone who hasn't got an Intel chipset.

    You probably could do that with VirtualBox. Adding the MSDM via extra data doesn't adjust the RSDP as far as I know.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  12. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    That's my original issue though. Afaik, I can only add 1 CustomTable in extradata. So if I use it to add an MSDM table, then I don't have an SLIC table. :(
     
  13. Daz

    Daz MDL Developer / Admin
    Staff Member

    Jul 31, 2009
    9,490
    66,580
    300
    Yeah, that'd be the case until I release the loader. For the time being though you could just use the SLIC only as at least you'll be activated and there won't be any negative effects.

    I'd question if maybe the old DLL SLIC method could be applied here for you. You could patch in a Dell SLIC and load the MSDM as the custom table :g:

    You could try to contact this guy: http://forums.mydigitallife.net/members/109689-atreyu

    I'm not sure if the current patcher in his signature would work anymore. I doubt it.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  14. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    Good idea! I sent a pm to him, hopefully he is interested.

    So now it's a waiting game I guess, with a few possible resolutions...

    1) atreyu's patch method could pan out
    2) a real OEM SLP key for 2012R2 might be discovered, and the new loader could be released
    3) vbox could get updated with the capability to load multiple customtables
    4) vbox could get updated to allow modified bioses like VMWare
    5) This is a longshot I just thought of... vbox could improve/complete it's EFI option, which would then allow us to use the WindSLIC EFI Loader method.

    We shall see...
     
  15. kelorgo

    kelorgo MDL Addicted

    Oct 29, 2012
    838
    1,499
    30
    I may have misunderstood what you mean by this, but isn't this exactly what the BiosRom option is for that we mentioned on the last page?
     
  16. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    Well yeah, but there is a problem because of this... virtualbox. org/ticket/1929#comment:3

    The size of the BiosRom can't be more than 64k. I have tried using modified bios440 files for vmware, which are 512k and the 128k bochs bios (modded and unmodded). With those the vm won't even start and gives this error:
    Failed to open a session for the virtual machine win2012r2vbox.

    Attempt to register a RAM range of which parts are already covered by existing RAM ranges. (VERR_PGM_RAM_CONFLICT).


    Result Code: E_FAIL (0x80004005)
    Component: Console
    Interface: IConsole {8ab7c520-2442-4b66-8d74-4ff1e195d2b6}

    So I would need a 64k vbox bios with acpi tables to even try it out (not even sure this is possible to create). But, I'm pretty sure based on the comments on the ticket I mentioned above, that even if I had this, it would cause a conflict between the bios and how vbox normally creates the acpi tables.

    Anyways, I will keep investigating, I'm no computer scientist though so when it comes down to reading the src I get pretty lost. :p
    In the meantime I can still use 2012R2. I'll admit I feel a little silly going down this whole road because of a pet-peeve with the event log, sorry if I wasted anyone else's time. :eek:
     
  17. tommy_vercetti

    tommy_vercetti MDL Member

    Apr 3, 2008
    151
    15
    10
    Where you able to use MSDM table in Vbox to activate Windows 8?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  18. jcap511

    jcap511 MDL Novice

    Aug 10, 2013
    13
    2
    0
    If I understand OA 3.0 correctly, that wouldn't work. Haven't actually tried though.
     
  19. Daz

    Daz MDL Developer / Admin
    Staff Member

    Jul 31, 2009
    9,490
    66,580
    300
    It's not possible unless you can get an MSDM key that's not already activated a system. I think you still need to do phone activation though, but then that's a good way to get your key blocked since Windows 8 has WAT built into it.

    The reason there's no loader for Windows 8 is because the keys can't be shared. MSDM tables contain a unique non-sharable key.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...