fix: resolve signature collision using body pattern and backtracking - #9
Open
rbtt wants to merge 2 commits into
Open
fix: resolve signature collision using body pattern and backtracking#9rbtt wants to merge 2 commits into
rbtt wants to merge 2 commits into
Conversation
Author
|
Addresses issue #7 |
rbtt
force-pushed
the
fix/update-pattern-season-5
branch
from
August 25, 2026 15:22
9428023 to
bc8f58c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This pull request resolves an issue where the patcher fails to apply correctly due to pattern collisions in the latest game update.
The original 7-byte signature (
31 c0 48 85 f6 0f 84— corresponding to the prologuexor eax, eax; test rsi, rsi; je ...) is a common compiler-generated instruction sequence. In the current version of the binary, this sequence matches multiple locations in the executable segment oflibclient.so, causing the patcher to target an incorrect function.Proposed Changes
To address the pattern collisions, this change introduces a two-stage lookup mechanism:
c7 45 d4 ff ff ff ff c7 45 d8(mov DWORD PTR [rbp-0x2c], 0xffffffff; mov DWORD PTR [rbp-0x28], 0xffffffff).31 c0 48 85 f6 0f 84).Modified Files
PATTERN_LENandpattern_bytesto use the new unique 11-byte sequence.backwards_loopassembly block underfound_matchto backtrack to the function entry point before writing the patch byte.Verification and Testing
build.sh.