firmware_notes icon indicating copy to clipboard operation
firmware_notes copied to clipboard

这个教程是否可以用在thinkpad x240呢

Open gonghaiyang opened this issue 6 years ago • 20 comments

如题 是否可以用在thinkpad x240呢

gonghaiyang avatar Jul 22 '18 07:07 gonghaiyang

不知道。操作时记得备份固件(读取flash两次并比较是否相同,用UEFITool看看是不是真的是个Intel平台的固件)。以及X240有BootGuard,不知道会允许多大的修改。

mytbk avatar Jul 22 '18 12:07 mytbk

谢谢您 弄了两天 我认识的一些朋友 用您那个51论坛上的教程成功了 我还在研究 麻烦您了

发自我的 iPhone

在 2018年7月22日,下午8:35,Iru Cai (vimacs) [email protected] 写道:

不知道。操作时记得备份固件(读取flash两次并比较是否相同,用UEFITool看看是不是真的是个Intel平台的固件)。以及X240有BootGuard,不知道会允许多大的修改。

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

gonghaiyang avatar Jul 22 '18 13:07 gonghaiyang

不能整个LenovoWmaPolicyDxe直接删,直接删会导致BIOS进不去 开机无Lenovo图标直接进系统 仅修改MAC地址是可以的,但我第一次这么尝试后Enter的那个菜单进不去了(这是什么鬼?)进BIOS得F1 所以后来让BIOS-Mod论坛的人帮忙做了白名单删除+解锁高级菜单

但蜂鸣声始终没有解决,关闭Security Chip也不行,我估计他改的BIOS还是有点问题。。

打算自己重新再试试,但目前还没找到白名单删除+解锁高级菜单的教程

kevin335200 avatar Aug 15 '18 02:08 kevin335200

刚刚又看了一下,大概明白 LenovoWmaPolicyDxe 的工作原理了,大致是安装一个 Protocol,然后 LenovoWma{Pci,Usb}Dxe 调用了这个 Protocol 里面的一个过程来检测 PCI/USB 设备的 ID,要做一个细粒度的修改来跳过白名单检测应该也很简单了。

当然了,网上流传的用 UEFIPatch 修改固件的那个 txt 文件的 LenovoWmaPolicyDxe 就是这么修改的。

至于这个联想自定义的 Protocol,也就这3个模块用了..... GUID pattern "4212a9d4-4a92-....-....-............" found as "D4A91242924AFB4BB47F2734355F54AC" in PE32 image section at header-offset 334h GUID pattern "4212a9d4-4a92-....-....-............" found as "D4A91242924AFB4BB47F2734355F54AC" in PE32 image section at header-offset 384h GUID pattern "4212a9d4-4a92-....-....-............" found as "D4A91242924AFB4BB47F2734355F54AC" in PE32 image section at header-offset 494h

mytbk avatar Aug 15 '18 12:08 mytbk

网上流传的用 UEFIPatch 修改固件的那个 txt 文件的 LenovoWmaPolicyDxe 就是这么修改的

求地址,也想学习下 有兴趣研究怎样去除蜂鸣声吗?思路应该就是用自己的公钥和签名来替换,但实际咋做还不清楚。。 这里有X220设计的脚本 https://github.com/ValdikSS/thinkpad-shahash

kevin335200 avatar Aug 15 '18 13:08 kevin335200

我看了一下那个脚本,在UEFITool看我从一台X230里面备份出来的固件,可以找到一个含有IBMSECUR的文件,其实我觉得可能对其他机型的固件也是可以的。

不过我的思路是首先考虑删除某些模块,然后看缺少某模块对于机器功能的影响,这是我现在分析原厂UEFI固件的方法。我搜索另一个字符串"TCPA",可以发现在 LenovoTcgServicesDxe.efi, LenovoOemSecPei.efi (这个模块在我的X230的原厂固件里出现了2次) 里面有这个字符串,可以考虑删掉它们看看。

mytbk avatar Aug 15 '18 15:08 mytbk

刚刚写了篇后续的文章 https://github.com/mytbk/firmware_notes/blob/master/thinkpad/tp-whitelist.rst

mytbk avatar Aug 30 '18 15:08 mytbk

x240.zip 发一份我机器原来的编程器固件和网友改过的,解了白名单和高级选项 有空是想分析下他是怎么改的,不过现在完全没空。。有兴趣自取

kevin335200 avatar Aug 30 '18 17:08 kevin335200

白名单检测的那个模块的分析和我昨天写的一样。他的做法是把访问白名单数据之后的3个条件转移指令都改了,je改成jmp,jne改成nop(他的改法是改了转移目标为下条指令,相当于把指令变成了nop).

高级选项的修改是改了 SystemFormBrowserCoreDxe. 这个修改是把一个地方的16个字节替换成了另外16个字节,这16个字节有可能是GUID,也有可能是什么配置信息,而且我暂时没找到相关的交叉引用。

查看两个UEFI固件的差别可以用这个方法:

  1. 用UEFIExtract提取固件的所有内容
  2. 对其中所有的body.bin做个hash: find x240.bin.dump/ -name body.bin -exec md5sum {} + > md5sums.txt.1
  3. 对修改后的固件做同样的操作,然后vimdiff查看两份hash信息

mytbk avatar Aug 30 '18 23:08 mytbk

W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警

lzy0702 avatar Jan 20 '19 01:01 lzy0702

已经解锁了

发自我的 iPhone

在 2019年1月20日,上午9:26,lzy0702 [email protected] 写道:

W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

gonghaiyang avatar Jan 20 '19 10:01 gonghaiyang

已经解锁了 发自我的 iPhone 在 2019年1月20日,上午9:26,lzy0702 @.***> 写道: W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

请问您解锁后解决了蜂鸣声问题吗 如果解决的话能方便分享下解锁前后的固件或解决蜂鸣声的方式吗? 非常感谢

kevin335200 avatar Jan 20 '19 13:01 kevin335200

我的是x240 解锁后 一开始有蜂鸣 上好d壳 重启一遍就没了

发自我的 iPhone

在 2019年1月20日,下午9:55,Well Honey [email protected] 写道:

已经解锁了 发自我的 iPhone … 在 2019年1月20日,上午9:26,lzy0702 @.***> 写道: W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

请问您解锁后解决了蜂鸣声问题吗 如果解决的话能方便分享下解锁前后的固件或解决蜂鸣声的方式吗? 非常感谢

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

gonghaiyang avatar Jan 21 '19 00:01 gonghaiyang

我的是x240 解锁后 一开始有蜂鸣 上好d壳 重启一遍就没了 发自我的 iPhone 在 2019年1月20日,下午9:55,Well Honey @.> 写道: 已经解锁了 发自我的 iPhone … 在 2019年1月20日,上午9:26,lzy0702 @.> 写道: W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 请问您解锁后解决了蜂鸣声问题吗 如果解决的话能方便分享下解锁前后的固件或解决蜂鸣声的方式吗? 非常感谢 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

重启的确不一定会有,不过关机重开会蜂鸣

kevin335200 avatar Jan 21 '19 00:01 kevin335200

重启一遍之后就没有了 我的240 目前 用转街板 加白果网卡 黑mac ING

发自我的 iPhone

在 2019年1月21日,上午8:12,Well Honey [email protected] 写道:

我的是x240 解锁后 一开始有蜂鸣 上好d壳 重启一遍就没了 发自我的 iPhone … 在 2019年1月20日,下午9:55,Well Honey @.> 写道: 已经解锁了 发自我的 iPhone … 在 2019年1月20日,上午9:26,lzy0702 @.> 写道: W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 请问您解锁后解决了蜂鸣声问题吗 如果解决的话能方便分享下解锁前后的固件或解决蜂鸣声的方式吗? 非常感谢 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

重启的确不一定会有,不过关机重开会蜂鸣

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

gonghaiyang avatar Jan 21 '19 12:01 gonghaiyang

重启一遍之后就没有了 我的240 目前 用转街板 加白果网卡 黑mac ING 发自我的 iPhone 在 2019年1月21日,上午8:12,Well Honey @.> 写道: 我的是x240 解锁后 一开始有蜂鸣 上好d壳 重启一遍就没了 发自我的 iPhone … 在 2019年1月20日,下午9:55,Well Honey @.> 写道: 已经解锁了 发自我的 iPhone … 在 2019年1月20日,上午9:26,lzy0702 @.***> 写道: W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 请问您解锁后解决了蜂鸣声问题吗 如果解决的话能方便分享下解锁前后的固件或解决蜂鸣声的方式吗? 非常感谢 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 重启的确不一定会有,不过关机重开会蜂鸣 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

我是配DW1830

能分享下解锁前后的固件吗,非常感谢

kevin335200 avatar Jan 21 '19 13:01 kevin335200

在上班 家里电脑有存

发自我的 iPhone

在 2019年1月21日,下午9:27,Well Honey [email protected] 写道:

重启一遍之后就没有了 我的240 目前 用转街板 加白果网卡 黑mac ING 发自我的 iPhone … 在 2019年1月21日,上午8:12,Well Honey @.> 写道: 我的是x240 解锁后 一开始有蜂鸣 上好d壳 重启一遍就没了 发自我的 iPhone … 在 2019年1月20日,下午9:55,Well Honey @.> 写道: 已经解锁了 发自我的 iPhone … 在 2019年1月20日,上午9:26,lzy0702 @.***> 写道: W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 请问您解锁后解决了蜂鸣声问题吗 如果解决的话能方便分享下解锁前后的固件或解决蜂鸣声的方式吗? 非常感谢 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 重启的确不一定会有,不过关机重开会蜂鸣 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

我是配DW1830

能分享下解锁前后的固件吗,非常感谢

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

gonghaiyang avatar Jan 22 '19 01:01 gonghaiyang

在上班 家里电脑有存 发自我的 iPhone 在 2019年1月21日,下午9:27,Well Honey @.> 写道: 重启一遍之后就没有了 我的240 目前 用转街板 加白果网卡 黑mac ING 发自我的 iPhone … 在 2019年1月21日,上午8:12,Well Honey @.> 写道: 我的是x240 解锁后 一开始有蜂鸣 上好d壳 重启一遍就没了 发自我的 iPhone … 在 2019年1月20日,下午9:55,Well Honey @.> 写道: 已经解锁了 发自我的 iPhone … 在 2019年1月20日,上午9:26,lzy0702 @.> 写道: W540用户路过,现在解锁了白名单和高级菜单的BIOS刷进去会在启动时有2次5声短的蜂鸣。据BIOS-MOD论坛上的人说这是因为机器带有TPM芯片的缘故。不知有什么办法能让TPM芯片不对这个新的BIOS报警 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 请问您解锁后解决了蜂鸣声问题吗 如果解决的话能方便分享下解锁前后的固件或解决蜂鸣声的方式吗? 非常感谢 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 重启的确不一定会有,不过关机重开会蜂鸣 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread. 我是配DW1830 能分享下解锁前后的固件吗,非常感谢 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

不急,我也是打算放假了再研究 非常感谢 :)

kevin335200 avatar Jan 22 '19 05:01 kevin335200

我重启了一下,在BIOS里把security chip和intel AT都调成disable,然后再重启的时候蜂鸣声就神奇地没有了。不过我还是想知道如果需要TPM,怎么给修改过的BIOS签名

lzy0702 avatar Jan 22 '19 05:01 lzy0702

我重启了一下,在BIOS里把security chip和intel AT都调成disable,然后再重启的时候蜂鸣声就神奇地没有了。不过我还是想知道如果需要TPM,怎么给修改过的BIOS签名

照理来说是这样,我也都彻底关闭了,但还是有,很奇怪

kevin335200 avatar Jan 22 '19 05:01 kevin335200