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

Disable ASLR to work around QEMU aarch64 issues #229

Merged
merged 1 commit into from
Feb 25, 2025

Conversation

agners
Copy link
Member

@agners agners commented Feb 20, 2025

It seems that QEMU and Address Space Layout Randomization do not work well toghether currently. Linux kernel security hardening efforts which make ASLR more random seem to cause SEGFAULTs randomly when building things for aarch64.

It seems that the QEMU for aarch64 made assumptions about how the memory layout is laid out, and/or has bugs in the implementation which are exarbated by the new ASLR scheme. In any case, disabling ASLR during build time avvoids hitting the QEMU bugs.

It seems that QEMU and Address Space Layout Randomization do not work
well toghether currently. Linux kernel security hardening efforts which
make ASLR more random seem to cause SEGFAULTs randomly when building
things for aarch64.

It seems that the QEMU for aarch64 made assumptions about how the memory
layout is laid out, and/or has bugs in the implementation which are
exarbated by the new ASLR scheme. In any case, disabling ASLR during
build time avvoids hitting the QEMU bugs.
@agners
Copy link
Member Author

agners commented Feb 20, 2025

This seem to effectively work around the QEMU issues we are seeing. Test run with Ubuntu 24.04 builder and the action with this modification: https://github.com/home-assistant/docker-base/actions/runs/13446504831/job/37573486076.

Copy link
Member

@sairon sairon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess we should be fine without ASLR at this stage, so 👍

@agners agners merged commit 919a224 into master Feb 25, 2025
11 checks passed
@agners agners deleted the disable-aslr-to-fix-qemu branch February 25, 2025 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants