avatar
神油极简化刷CFE的script# Hardware - 计算机硬件
a*o
1
根本不需要什么telnet,直接enable SSH就行,scp这两个文件上去/tmp:
mtd-write
new_cfe.bin
然后跑哥这个script:
#!/bin/sh
nvram get bl_version
cat /dev/mtd0 > ./old_cfe.bin
echo
echo Old CFE content:
strings old_cfe.bin | grep -e mac -e secret
echo
# Sanity checks
[ "`strings old_cfe.bin -o | grep t0mac | awk '{print $1}'`" != "2306" ] &&
(echo unsupported cfe rev;exit)
[ "`strings old_cfe.bin -o | grep 0:mac | awk '{print $1}'`" != "3132" ] &&
(echo unsupported cfe rev;exit)
[ "`strings old_cfe.bin -o | grep 1:mac | awk '{print $1}'`" != "5166" ] &&
(echo unsupported cfe rev;exit)
[ "`strings old_cfe.bin -o | grep secret | awk '{print $1}'`" != "11540" ] &
& (echo unsupported cfe rev;exit)
dd if=old_cfe.bin of=new_cfe.bin bs=1 count=17 conv=notrunc skip=1233 seek=
1233 2>/dev/null
dd if=old_cfe.bin of=new_cfe.bin bs=1 count=17 conv=notrunc skip=1636 seek=
1647 2>/dev/null
dd if=old_cfe.bin of=new_cfe.bin bs=1 count=17 conv=notrunc skip=2688 seek=
2710 2>/dev/null
dd if=old_cfe.bin of=new_cfe.bin bs=1 count=8 conv=notrunc skip=4972 seek=
5005 2>/dev/null
echo
echo New CFE content:
strings old_cfe.bin | grep -e mac -e secret
echo
echo Run this command to flash CFE:
echo ./mtd-write -i new_cfe.bin -d boot
echo mtd-erase2 nvram
echo reboot
echo
avatar
a*o
2
最下面几行哥弄成只是echo出来而不是直接执行,因为没试过 :)
谁来试试?

【在 a*o 的大作中提到】
: 根本不需要什么telnet,直接enable SSH就行,scp这两个文件上去/tmp:
: mtd-write
: new_cfe.bin
: 然后跑哥这个script:
: #!/bin/sh
: nvram get bl_version
: cat /dev/mtd0 > ./old_cfe.bin
: echo
: echo Old CFE content:
: strings old_cfe.bin | grep -e mac -e secret

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。