Skip to content

NickstaDB/xamarin-decompress

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

xamarin-decompress

Decompress Xamarin .NET compressed binaries so they can be decompiled.

This pull request on the xamarin-android project implemented compression for .NET assemblies inside Android .apk files: xamarin/xamarin-android#4686. This prevents those assemblies from being decompiled until they have been decompressed, which is where this script comes in.

The script checks for the XALZ header which indicates a compressed assembly and decompresses it using LZ4 block decompression so that the resulting file can be decompiled using your tool of choice.

Usage

To decompress a single file run the script as follows:

python3 xamarin-decompress.py target-assembly.dll

This will generate target-assembly.decompressed.dll which can be decompiled. To overwrite the original assembly file with the decompressed one, pass the -o flag e.g.

python3 xamarin-decompress.py -o target-assembly.dll

To scan a directory for all Xamarin .NET compressed .dll and .exe files, run the script as follows:

python3 xamarin-decompress.py dir-where-you-extracted-the-apk

Likewise, the -o flag can be used to replace the original files.

About

Decompress Xamarin .NET compressed binaries so they can be decompiled.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages