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

Failed to decrypt .sc file - Unknown Header exception #29

Closed
dancechart opened this issue Jun 5, 2024 · 6 comments
Closed

Failed to decrypt .sc file - Unknown Header exception #29

dancechart opened this issue Jun 5, 2024 · 6 comments

Comments

@dancechart
Copy link

Tried via VSCode terminal py dumpsc.py C:\Users\Admin\Main\resources\assets\sc\boats.sc. Got Unknown Header exception. Adding --old doesn't change anything.

@123456abcdef
Copy link
Owner

Most likely that file does not contain assets. Please try a *_tex.sc file.

@dancechart
Copy link
Author

dancechart commented Jun 12, 2024

Still shows the same exception, tried multiple *_tex.sc files... All libraries are downloaded, VSCode doesn't show any issues.
cr-sc-dump-issue

That's what data[0], data[:2] and data[:4] contains when trying to read *_tex.sc file.
cr-sc-dump-issue-1

For *.sc file output is different.
cr-sc-dump-issue-2

Adding or removing --old doesn't affect that in both cases.

@123456abcdef
Copy link
Owner

@dancechart Which game do the files come from?

@CharlieeChaser The first sprite you attached does not match emotes_rascals_lovegum_dl.sc. You can extract the png from it using python dumpsc.py emotes_rascals_lovegum_dl.sc --old.
To get an animated version you would need to parse the file further. After the image there is additional info in the file. I assume it tells you how to cut the sprites, rotate, transform, and overlap to get an animated image.
sc_decode tried to parse these information. I don't know if there is public script you could use.

@dancechart
Copy link
Author

@123456abcdef from Boom Beach. If you need an archive with all .sc files I could find there after unpacking an .apk, let me know.

@123456abcdef
Copy link
Owner

123456abcdef commented Jun 16, 2024

@dancechart Works just fine for me. If you look in <apk-root>/assets/fingerprint.json at the end of the file. sha: 4aac756f2f41dc68fd7552a91005f55065b6afd, version: 52.103.1. Is your version newer or older? sha1 of the file I used is 38ede3081542ecc02077b7301cbfbdb48c41e6d6 boats_tex.sc. First to bytes of the file should be 0x53 0x43 in hex or SC in ASCII. Seems to be not the case for your file.

@CharlieeChaser Getting the *_tex.sc files seems to me more complicated than running a Python script. Please try yourself using this script. I won't share copyrighted data.

@dancechart
Copy link
Author

@123456abcdef my version is older, "sha":"9227415f159f7ff0ad1df05e03b172d1cc11227c","version":"50.101.1". Will try out the latest version, thank you for the help.

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

No branches or pull requests

2 participants