I'm trying to extract a squashfs file from a .bin

What I did so far:

I used binwalk to locate the pointers: binwalk data.bin


512           0x200           LZMA compressed data, properties: 0x6D, dictionary 
                              size: 8388608 bytes, uncompressed size: 3420708 bytes
1134468       0x114F84        Squashfs filesystem, little endian, version 4.0, 
                              compression:xz, size: 13089146 bytes, 2102 inodes, 
                              blocksize: 262144 bytes, created: 2016-10-28 05:42:31`

How can I extract only the squashfs filesystem using dd or tail, so I can later get the content its by using the unsquashfs command.


  • dd if=data.bin of=somewhat ibs=4 skip=283617. skipmeans to skip n input blocks, each of size 4 Bytes (ìbs=4). This could be very slow, as the blocks have to be very small (4 Bytes) for skip to work. – ridgy Dec 8 '16 at 18:07
  • the skip=283617 is a wrong value I guess, here what I get after unsquashfs output.squashfs : Can't find a SQUASHFS superblock on output.squashfs – StruDJA Dec 8 '16 at 18:24
  • So I may be mistaken what the number "1134468" (=4*283617) in the binwalk output says. Maybe you can try binwalk -e to extract? – ridgy Dec 8 '16 at 20:01
  • @ridgy what can I say.. Thank you so much. I wasn't looking for that kind of files only for some specific bytes but anyway I can start from that ;) – StruDJA Dec 12 '16 at 14:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.