2020-11-25 10:51:59 -06:00
2020-11-23 06:44:39 -06:00
2020-11-08 11:41:05 -06:00
2020-11-25 08:27:15 -06:00
2020-11-08 11:06:38 -06:00
2020-11-25 08:27:15 -06:00
2020-11-25 08:57:18 -06:00
2020-11-25 08:57:18 -06:00
2020-11-25 08:27:15 -06:00

GoSquashfs

PkgGoDev

A PURE Go library to read and write squashfs.

Currently, you can read a squashfs and extract files (only files at the moment). Many things are public that shouldn't be, but you can use it by using NewSquashfsReader and subsequent ReadFile.

Special thanks to https://dr-emann.github.io/squashfs/ for some VERY important information in an easy to understand format. Thanks also to distri's squashfs library as I referenced it to figure some things out (and double check others).

Working

  • Extracting files from string paths
  • Reading the header
  • Reading metadata blocks (whether encrypted or not)
  • Reading inodes
  • Reading directories
  • Basic gzip compression (Shouldn't be too hard to implement other, but for right now, this works)
  • Listing all files via a string slice

Not Working (Yet). Not necessarily in order.

  • Rename repo so it's easier to import
  • Provide an easy interface to find and list files and their properties
    • Maybe squashfs.File
  • Extracting files
    • from inodes.
    • from file info.
  • Give a list of files
    • In io.FileStat (?) form
  • Reading the UID, GUID, Xatt, Compression Options, and Export tables.
  • Implement other compression types (Should be relatively easy)
  • Squashing
  • Threading processes to speed them up
  • Reasonable tests

TODO

  • Go over all documentation again (especially for exported structs and functions) to make sure it's easy to understand.

Where I'm at

  • v0.1 is the first working version!
S
Description
A Go library to read squashfs archives.
Readme MIT 15 MiB
2026-03-08 06:11:15 -05:00
Languages
Go 100%