fix: validate libcef.so architecture after extraction on Linux#25
Open
c8dhjp4tyv-bit wants to merge 1 commit into
Open
fix: validate libcef.so architecture after extraction on Linux#25c8dhjp4tyv-bit wants to merge 1 commit into
c8dhjp4tyv-bit wants to merge 1 commit into
Conversation
On aarch64 systems, the linux_arm64/libcef.so served by CCBlueX's download server was found to be an x86_64 binary, causing an UnsatisfiedLinkError crash at startup (issue #8412). This adds a post-extraction validation step that reads the ELF header of libcef.so and verifies the e_machine field matches the current platform architecture. If a mismatch is detected, a descriptive IOException is thrown instead of crashing with a cryptic UnsatisfiedLinkError deep in the JVM native loader. Affected platforms: Linux ARM64 (e.g. Raspberry Pi 5) ELF e_machine values: 0x3E = x86_64, 0xB7 = aarch64
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.
On aarch64 systems, the linux_arm64/libcef.so served by CCBlueX's download server was found to be an x86_64 binary, causing an UnsatisfiedLinkError crash at startup (issue #8412).
This adds a post-extraction validation step that reads the ELF header of libcef.so and verifies the e_machine field matches the current platform architecture. If a mismatch is detected, a descriptive IOException is thrown instead of crashing with a cryptic UnsatisfiedLinkError deep in the JVM native loader.
Affected platforms: Linux ARM64 (e.g. Raspberry Pi 5)
ELF e_machine values: 0x3E = x86_64, 0xB7 = aarch64