首页 > 程序 > 解包kktv的MstarUpgrade.bin文件

作者:ghostry 发布时间:2015-06-03 浏览: 12893

转载注明出处: https://blog.ghostry.cn/program/609.html

kktv的MstarUpgrade.bin文件是用来升级系统的。
我想从里边提取apk文件出来,又不想刷机。于是就想解包它

首先

vi MstarUpgrade.bin

把前边几行复制出来。看起来类似这样

filepartload c0000000 MstarUpgrade.bin 4000 a00000 mmc erase.p
recovery mmc write.p c0000000 recovery a00000 1 filepartload c0000000
MstarUpgrade.bin a04000 39e9fe mmc erase.p boot mmc write.p c0000000
boot 39e9fe 1 mmc erase.p system filepartload c0000000
MstarUpgrade.bin e04000 a839890 mmc unlzo c0000000 a839890 system 1
filepartload c0000000 MstarUpgrade.bin b644000 b28ee4f mmc unlzo.cont
c0000000 b28ee4f system filepartload c0000000 MstarUpgrade.bin
168d4000 8583825 mmc unlzo.cont c0000000 8583825 system filepartload
c0000000 MstarUpgrade.bin 1ee64000 47c3fa9 mmc unlzo.cont c0000000
47c3fa9 system filepartload c0000000 MstarUpgrade.bin 23634000 7543d
mmc unlzo.cont c0000000 7543d system mmc erase.p userdata filepartload
c0000000 MstarUpgrade.bin 236b4000 9291f9 mmc unlzo c0000000 9291f9
userdata 1 mmc erase.p cache filepartload c0000000 MstarUpgrade.bin
23fe4000 24a428 mmc unlzo c0000000 24a428 cache 1 setenv
MstarUpgrade_complete 1 setenv UARTOnOff off saveenv printenv reset

主要是为了这些偏移。然后我用PartCopy 1.12-chs-th_sjy.7z复制对应偏移的内容出来。
我需要的文件在system分区。从上面可以看出来这分区分为5部分。把他们都复制出来命名为1.lzo,2.lzo。。。
然后

lzop -d 1.lzo

解包得到1 2 3 4 5 文件
然后合并文件

cat 1 2 3 4 5 >system

最后挂载

sudo mount -t ext4 system tmp

现在可以在tmp目录下复制需要的文件出来了。

标签: none

上一篇: 所有网站都需要维护呀
下一篇: 博客搬家啦

已有 14 条评论 »

  1. 博主,能否把这段(PartCopy 1.12-chs-th_sjy.7z复制对应偏移的内容出来)详细说说,谢谢
    我是海尔机器,只是打算提取这个ROM文件,请帮忙指出system每部分起始位置和偏移长度。
    mmc erase.p system
    filepartload c0000000 Haier818Upgrade.bin 4000 81e6cfa
    mmc unlzo c0000000 81e6cfa system 1
    filepartload c0000000 Haier818Upgrade.bin 81f4000 6b5731c
    mmc unlzo.cont c0000000 6b5731c system
    filepartload c0000000 Haier818Upgrade.bin ed54000 64b386c
    mmc unlzo.cont c0000000 64b386c system
    filepartload c0000000 Haier818Upgrade.bin 15214000 3897ad
    mmc unlzo.cont c0000000 3897ad system
    setenv MstarUpgrade_complete 1
    setenv UARTOnOff off
    saveenv
    printenv
    reset
    % <-this is end of file symbol

    1. 已经搞定,谢谢博主方法

      1. 请问起始位置和便宜长度怎么看

      2. 不错哦

        1. 博主请帮忙指出system每部分起始位置和偏移长度,谢谢了

          File Partition: system

          mmc erase.p system
          filepartload 0x20200000 $(UpgradeImage) 0x2145000 0x7262934
          mmc unlzo 0x20200000 0x7262934 system 1
          filepartload 0x20200000 $(UpgradeImage) 0x93a8000 0x5ee3a2b
          mmc unlzo.cont 0x20200000 0x5EE3A2B system 1
          filepartload 0x20200000 $(UpgradeImage) 0xf28c000 0x4981f2a
          mmc unlzo.cont 0x20200000 0x4981F2A system 1

          1. 太久没玩,忘了怎么看了。不过一行就两三个数字,试试应该能试出来。

  2. mmc slc 0 1
    mmc rmgpt
    mmc create misc 0x00080000
    mmc create recovery 0x00A00000
    mmc create boot 0x00400000
    mmc create system 0x019000000
    mmc create userdata 0x32000000
    mmc create cache 0x12C00000
    mmc create tvservice 0x05000000
    mmc create tvcustomer 0x01000000
    mmc create tvdatabase 0x00800000
    mmc create customercfg 0x00800000
    filepartload 50000000 MstarUpgrade.bin 4000 5d3d9d
    mmc erase.p recovery
    mmc write.p 50000000 recovery 5d3d9d 1
    filepartload 50000000 MstarUpgrade.bin a04000 3838c4
    mmc erase.p boot
    mmc write.p 50000000 boot 3838c4 1
    mmc erase.p system
    filepartload 50000000 MstarUpgrade.bin e04000 6400000
    mmc write.p.continue 50000000 system 0 6400000 1
    filepartload 50000000 MstarUpgrade.bin 7204000 6400000
    mmc write.p.continue 50000000 system 32000 6400000 1
    filepartload 50000000 MstarUpgrade.bin d604000 6400000
    mmc write.p.continue 50000000 system 64000 6400000 1
    filepartload 50000000 MstarUpgrade.bin 13a04000 6400000
    mmc write.p.continue 50000000 system 96000 6400000 1
    filepartload 50000000 MstarUpgrade.bin 19e04000 336665
    mmc erase.p userdata
    mmc unlzo 50000000 336665 userdata 1
    filepartload 50000000 MstarUpgrade.bin 1a144000 13467b
    mmc erase.p cache
    mmc unlzo 50000000 13467b cache 1
    filepartload 50000000 MstarUpgrade.bin 1a284000 5000000
    mmc erase.p tvservice
    mmc write.p 50000000 tvservice 5000000 1
    filepartload 50000000 MstarUpgrade.bin 1f284000 1000000
    mmc erase.p tvcustomer
    mmc write.p 50000000 tvcustomer 1000000 1
    filepartload 50000000 MstarUpgrade.bin 20284000 800000
    mmc erase.p tvdatabase
    mmc write.p 50000000 tvdatabase 800000 1
    filepartload 50000000 MstarUpgrade.bin 20a84000 800000
    mmc erase.p customercfg
    mmc write.p 50000000 customercfg 800000 1
    setenv MIU0_GROUP_SELMIU 0000:0000:0000:0000
    setenv MIU1_GROUP_SELMIU 4E00:0000:0000:0100
    setenv MS_MEM LX_MEM=0x9600000 EMAC_MEM=0x100000 DRAM_LEN=0x20000000 LX_MEM2=0x50E00000,0xD900000 LX_MEM3=0xB0000000,0x0000000
    setenv ROOT root=/dev/ram rw rootwait
    setenv bootargs console=ttyS0,115200 androidboot.console=ttyS0 $(ROOT) init=/init $(MS_MEM)
    setenv MstarUpgrade_complete 1
    setenv upgrade_mode 0
    setenv db_table 0
    setenv verify n
    saveenv
    setenv filesize 3838c4
    setenv bootcmd mmc read.p 0x45000000 boot 0x400000; bootm 0x45000000
    printenv
    setenv MstarUpgrade_complete 1
    saveenv
    printenv
    % <-this is end of file symbol

    这个我用notepad打开 前面看到的,然后你直接在7z打开能看里面的东西,用你的方法 我保存system分区bin 然后用rom助手 可以提取system 提取后只有app里面有apk文件 其他文件夹什么都没有。 还有如果把全部文件都分离出来之后,怎么再封包回去

    1. 封包我也不会。我只是要提取文件。

  3. 你好,使用你的方法通过linux 解压lzo文件太大了,有点不对,我是解压LetvUpgrade.bin这个文件

    1. letv的应该是不同的文件吧。这个是kktv的。

      1. 乐视的片段如下:
        filepartload 50000000 LetvUpgrade.bin 4000 961a5
        mmc unlzo 50000000 961a5 fastplay 1
        mmc erase.p recovery
        filepartload 50000000 LetvUpgrade.bin a4000 57a0de
        mmc write.p 50000000 recovery 57a0de 1
        mmc erase.p boot
        filepartload 50000000 LetvUpgrade.bin 10a4000 3b8d29
        mmc write.p 50000000 boot 3b8d29 1
        mmc erase.p system
        filepartload 50000000 LetvUpgrade.bin 20a4000 10000000
        mmc write.p 50000000 system 10000000 1
        filepartload 50000000 LetvUpgrade.bin 120a4000 10000000
        mmc write.p.continue 50000000 system 80000 10000000 1
        mmc erase.p userdata
        filepartload 50000000 LetvUpgrade.bin 220a4000 9615b4
        mmc unlzo 50000000 9615b4 userdata 1
        mmc erase.p cache
        filepartload 50000000 LetvUpgrade.bin 22a14000 13467b
        mmc unlzo 50000000 13467b cache 1
        mmc erase.p tvservice
        filepartload 50000000 LetvUpgrade.bin 22b54000 3c00000
        mmc write.p 50000000 tvservice 3c00000 1
        mmc erase.p tvcustomer
        filepartload 50000000 LetvUpgrade.bin 26754000 1000000
        mmc write.p 50000000 tvcustomer 1000000 1
        mmc erase.p tvdatabase
        filepartload 50000000 LetvUpgrade.bin 27754000 800000
        mmc write.p 50000000 tvdatabase 800000 1
        mmc erase.p inter_sdcard
        filepartload 50000000 LetvUpgrade.bin 27f54000 12705c9
        mmc unlzo 50000000 12705c9 inter_sdcard 1

        跟你的类似

        1. 的确很像 ,你可以试试看能不能解包后挂载。你这个看起来system分为两部分。就是不知道他是不是也用了分包压缩,如果压缩,用的什么压缩也不好说。kktv的用lzo压缩我是搜索了很多页面才知道的。

  4. 我也想解包修改里面的东西 然后再封包, 我在windows下7z能看到里面东西,然后百度查了好多,然后用你这个 出输入第一个代码 终端就没反应了 全是波浪线 然后一个提示什么新文件

    1. 解包之前需要先按照偏移把文件分离出来。

添加新评论 »

*
*

欢迎评论!歡迎評論!Comments welcome!komentoj bonvenaj!댓글 오신 것을 환영합니다!
:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen: :cold: :cryy: :cute: :shy: :sleep: :struggle: :tea: :yahou: