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

fix: support skipping entries with NO_ENTRY (-1) flag #3209

Merged
merged 1 commit into from
Jul 24, 2023
Merged

Conversation

iBotPeaches
Copy link
Owner

fixes: #1874

In a very old (5+ year) issue. We saw a specific version of Google Hangouts failed to decode. Turns out with some fresh eyes. We just missed an important note in the spec that we should skip entries if the key/offset resolve to -1 (NO_ENTRY)

We applied that to the entry reading as well as the offset reading and it worked great to resolve what used to be this crash:

Caused by: java.io.IOException: Expected: 0x00000008, got: 0x00000202
	at brut.util.ExtDataInput.skipCheckShort(ExtDataInput.java:49)
	at brut.androlib.res.decoder.ARSCDecoder.readValue(ARSCDecoder.java:422)
	at brut.androlib.res.decoder.ARSCDecoder.readEntryData(ARSCDecoder.java:347)
	at brut.androlib.res.decoder.ARSCDecoder.readTableType(ARSCDecoder.java:326)
	at brut.androlib.res.decoder.ARSCDecoder.readResourceTable(ARSCDecoder.java:99)
	at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:50)

@iBotPeaches iBotPeaches marked this pull request as ready for review July 23, 2023 23:58
@iBotPeaches iBotPeaches added this to the v2.8.2 milestone Jul 24, 2023
@iBotPeaches iBotPeaches merged commit 03c198c into master Jul 24, 2023
@iBotPeaches iBotPeaches deleted the issue-1874 branch July 24, 2023 10:06
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

Successfully merging this pull request may close these issues.

Can't decompile Hangouts v26
1 participant