Tool to Insert/Replace SLIC in Phoenix / Insyde / Dell / EFI BIOSes

Discussion in 'MDL Projects and Applications' started by andyp, Nov 26, 2009.

  1. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    667
    10
    I have made a test file for this bug.
    Hope we can find a working method to separate EFI1.1 from Tiano without catching memory corruptions in poorly written 10 years old Intel code.
    View attachment 28137
     
  2. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    667
    10
    #3842 CodeRush, Apr 9, 2014
    Last edited by a moderator: Apr 20, 2017
    Found the source of the crash, it's in EfiDecompress.c, this part of MakeTable function :
    Code:
    if (Len <= TableBits) {
       for (Index = Start[Len]; Index < NextCode; Index++) {
          Table[Index] = Char;
       }
       ...
    
    Table array has 2^TableBits size (which can be 8 or 12), but writing to Table[256] or Table[4096] will corrupt the heap.
    Index variable above will become exactly 256 on that file, triggering the crash. It can be fixed by adding a check like this:
    Code:
       for (Index = Start[Len]; Index < NextCode; Index++) {
          // Check to prevent possible heap corruption
          if (Index >= (UINT16) (1U << TableBits))
             return (UINT16)BAD_TABLE;
          Table[Index] = Char;
       }
    
    It's not a good idea to make patches like that, I know, but it works. :)
     
  3. andyp

    andyp SLIC Tools Author

    Aug 8, 2008
    1,671
    2,536
    60
    #3843 andyp, Apr 9, 2014
    Last edited by a moderator: Apr 20, 2017
    (OP)
    Well done!!
    You are better at this than I am!

    A

     
  4. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    667
    10
    No, I'm not. Maybe a bit closer to low level, but nothing more.
    I think it must somehow be reported to TianoCore developers, because FFS files like that are like time bombs for BIOS.
    I bet no one knows now what Tiano algorithm is all about, because of that "//Ported from ASM routine" commentary. :)

    Thanks for finding this gem, Serg008.
     
  5. andyp

    andyp SLIC Tools Author

    Aug 8, 2008
    1,671
    2,536
    60
    New version - see first post
    A
     
  6. wpingo

    wpingo MDL Novice

    Apr 8, 2014
    6
    0
    0
    Acer xc600

    Dear all,

    I am trying to get Windows 7 Enterprise to install on an ACER XC600. The device was bought without windows, but I have enough licenses of windows lying around. I am trying to install Windows 7 Enterprise and activate it using KMS. KMS activation checks the SLIC table, I guess, and refuses to install because there is a table, but it does not have a value for any OEM license in it. I think I have two options: Either get rid of the SLIC table altogether. In that case, I understand, KMS activation should just work. Or get an SLIC table with a valid OEM entry in it.

    I can use this tool, and if I put in ACER SLIC and SLP files (containing the string "AcerSystem") as well as the "RW Everything report" and check "module", it will generate a BIOS for me. What I do not understand is why the field for "Key File" is greyed out. How can the resulting SLIC table have a valid entry for, say, Windows 7 Professional, if I do not put in a product key? What am I missing? Have not tried flashing the resulting BIOS yet. Any help is appreciated...

    Thx...
     
  7. Carlos Detweiller

    Carlos Detweiller MDL Spinning Tortoise

    Dec 21, 2012
    4,514
    4,543
    150
    SLIC tables do not carry keys. Only MSDM ones do, and MSDM is for Windows 8.
    All you need is a valid SLIC table (pubkey, marker).
     
  8. wpingo

    wpingo MDL Novice

    Apr 8, 2014
    6
    0
    0
    Thanks. So if I use the generated BIOS, and do not brick it, Win 7 Enterprise should activate via KMS? Thanks!
     
  9. Galane

    Galane MDL Junior Member

    Feb 11, 2013
    50
    5
    0
    I want to update the BIOS on an MPC laptop from SLIC 2.0 to 2.1. Can I do that and keep the data in the BIOS which identifies it as an MPC?

    I installed a multi-OEM detecting Win 7 and it saw it as an Acer, which is odd because it's made by Samsung and some of the identifying code in the BIOS is $SAMSUNGPC.

    So far I've yet to find a version of WinPhlash that will work on Win 7 Ultimate x64. Found a version that's supposed to work, but it quits with an error message about updating DXE drivers. I enabled the Administrator account and logged in with it. No difference in how it doesn't work.
     
  10. Galane

    Galane MDL Junior Member

    Feb 11, 2013
    50
    5
    0
    No luck at all with MPC BIOS modding. :wallbash: Seems like I'm the only person wanting to mod any MPC BIOS to SLIC 2.1.
     
  11. locarno

    locarno MDL Novice

    Apr 20, 2014
    22
    2
    0
    Hi
    This tool is compatibile with *.hdr bios file ?
    Dell bios is secured by Armadillo yes ? How to unpack hdr file ?
     
  12. DanielCollinet

    DanielCollinet MDL Novice

    Oct 4, 2009
    10
    0
    0
    Hello,

    I also get "error 5" or something "Invalid RW Everything report". Used Phoenixtool 2.52 and RW newest version. :(
     
  13. andyp

    andyp SLIC Tools Author

    Aug 8, 2008
    1,671
    2,536
    60
    Fixed in 2.53
    A

     
  14. Inge

    Inge MDL Member

    Apr 2, 2008
    194
    528
    10
    Dear Andy,

    please let me thank you for all your hard work since many years. Nice to have members
    like you who keep the real MDL spirit alive and don't register to request the latest iso file.


    Inge
     
  15. AcerBricked

    AcerBricked MDL Novice

    Apr 25, 2014
    1
    0
    0