Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to decompress these data streams ("brcm-lzma" method?) #25

Open
XVilka opened this issue Jan 22, 2020 · 5 comments
Open

Fail to decompress these data streams ("brcm-lzma" method?) #25

XVilka opened this issue Jan 22, 2020 · 5 comments

Comments

@XVilka
Copy link
Contributor

XVilka commented Jan 22, 2020

Unpacking the data, and noted that some streams can't be unpacked with lzma-rs, see the attached files of the compressed and uncompressed chunks.

lzma_alt_samples.zip

The chunks were successfully unpacked with this library instead: https://github.com/firmadyne/sasquatch/tree/master/LZMA/lzmalt

The algorithm itself seems came out of the Broadcom LZMA modification.

@XVilka XVilka changed the title Fail to decompress these data streams ("lzma-alt" method?) Fail to decompress these data streams ("brcm-lzma" method?) Jan 23, 2020
@gendx
Copy link
Owner

gendx commented Jan 24, 2020

Could you document how standard this "Broadcom modification" is?

I won't have much time to investigate this in the following weeks, but feel free to send a pull-request to support this variant of the algorithm (preferably using a decoding option if there's something non-standard involved).

@XVilka
Copy link
Contributor Author

XVilka commented Mar 10, 2020

I don't think it's a standard one, but quite common among compressed firmware images.

@voltagex
Copy link

@XVilka are you able to share how you decompressed these?

@XVilka
Copy link
Contributor Author

XVilka commented Dec 30, 2021

@voltagex
Copy link

@XVilka yes, this creates a library, not a program - did you write something to use this library to decompress the data?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants