[UEFITool] UEFI firmware image viewer and editor

Discussion in 'MDL Projects and Applications' started by CodeRush, Oct 8, 2013.

  1. blakeniel

    blakeniel MDL Novice

    Jun 3, 2010
    11
    2
    0
    Thanks CodeRush. Will I be able to use a Bus Pirate to do this. If I can use BP, can you direct me to a detailed tutorial. I've seen some online, but non is detailed. As I have a very limited knowledge regarding usage of BP, a detailed tutorial would help greatly. Thanks a lot.
     
  2. blakeniel

    blakeniel MDL Novice

    Jun 3, 2010
    11
    2
    0
    Ok, I'll start on reading. Thanks.
     
  3. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    674
    10
    Serg008, there is no free space to fit the modified module. Try removing all useless version and unknown sections to save some space.
     
  4. Serg008

    Serg008 MDL BIOS/EFI Guru

    Feb 23, 2010
    23,347
    10,326
    390
    Open backup with Uefitool and just try rebuild it (without of any modifications):
    View attachment 30201

    add.
    Phoenixtool can't open this bios correctly too
    (with both - backup & original
     
  5. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    674
    10
    They used EFI1.1 compression, but GUID says that it's Tiano, that is why recompressed module appears too big to fit in.
    I hate the fool that changed EFI1.1 to Tiano and back without any change in compression type.
    Will try to debug it.
     
  6. Serg008

    Serg008 MDL BIOS/EFI Guru

    Feb 23, 2010
    23,347
    10,326
    390
    Perhaps it's protection against the BIOS modification ? :confused:
     
  7. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    674
    10
    I don't think so. What I can't really understand how they managed to compress it with Tiano/EFI11 and have the size of compressed data of about 0x220000, and can have no less then 0x2b0000 after recompression (this is the real source of that bug, BTW). They are using much better compression code or some interesting setups, but AFAIK, there is nothing to setup for Tiano algorithm. Weird as sh*t. o_O
     
  8. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    674
    10
    @adrian_p, thanks for report, I have seen your PM, just have no time to answer.
    Please explain why do you need to replace VTF and PeiCore, it's not a common task at all. I will try to make the mod manually then.
     
  9. adrian_p

    adrian_p MDL Novice

    Jan 13, 2009
    6
    0
    0
    I am doing some tests on that board with Xeon ES cpus

    Thx

    EDIT: Mine Idea was to swap VTF then reinsert PeiCore to fix path in newer bios (changing VTF)
    Or simply add older PeiCore to see will it go beyond instant reboot (changing PeiCore)
     
  10. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    674
    10
    How are VTF and PEI Core are linked to that?
    I know you need to insert a microcode for that CPU, but it has nothing to do with that 2 files.
     
  11. adrian_p

    adrian_p MDL Novice

    Jan 13, 2009
    6
    0
    0
    I have microcode for CPU in new and old bios.
    That is not problem to insert.

    I have found two bioses with minimal changes one: 813 (08.2013) and another 913 (09.2013)
    813 works
    913 goes instant reboot
    bouth bioses have cpumicrocode for Xeon ES

    after examining with diff some modules in DXE Volume are changed, but in Boot volume PeiCore and VTF.

    That is reason I am testing this.
     
  12. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    674
    10
    Ok. Now I clearly see where the bug is. I'm replacing or moving the PEI code, calculating it's new entry point and then trying to search that new value in old VTF, which of course fails. Will correct it ASAP.
     
  13. adrian_p

    adrian_p MDL Novice

    Jan 13, 2009
    6
    0
    0
    Thx for your time, I will update the progress here.

    I have dirty FTDI breakout board so flashing is done quickly and easy...
     
  14. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    674
    10
    0.18.6 is out.

    Changes:
    - solved a bug with unneeded recalculation of original PEI Core entry point, thanks adrian_p for reporting.
    - the name of opened file is now shown in window title.
    - compression type and decompressed size information added to compressed GUID-defined sections

    ---
    @adrian_p, I hope the problem with VTF is solved in 0.18.6, please check and report here.

    @il_gaby, SP5 can be modified, I think, but SP6 can't because of cryptographic sugnature check that occurs on every boot.
    Try posting a requiest on bios-mods.com/forum or here in BIOS Mods subforum, I don't familiar with HP systems and therefore don't know haw to flash modified BIOS there.
     
  15. CodeRush

    CodeRush MDL Member

    Jun 20, 2011
    221
    674
    10
    0.18.7 is out, code rush indeed. :)

    Changes:
    - EFI11/Tiano compression code reverted to 0.17.x version because of higher compression ratio, thanks Serg008 for reporting.
    - delete and backspace keys handled properly for GUID field of search dialog

    ---
    @Serg008, tested 0.18.7 on that crappy Lenovo BIOS - rebuild now works, but there are not much free space for any complex mods. You can try to remove all unknown sections (they are useless) to save some space, if needed.
     
  16. Serg008

    Serg008 MDL BIOS/EFI Guru

    Feb 23, 2010
    23,347
    10,326
    390