-
-
Notifications
You must be signed in to change notification settings - Fork 14.6k
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
[staging] {cc,binutils}-wrapper: fixes for PIE hardening #135619
Merged
Merged
Conversation
This file contains 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
r-burns
changed the title
{cc,binutils}-wrapper: fixes for PIE hardening
[staging] {cc,binutils}-wrapper: fixes for PIE hardening
Aug 25, 2021
ofborg
bot
added
10.rebuild-darwin-stdenv
This PR causes stdenv to rebuild
10.rebuild-linux-stdenv
This PR causes stdenv to rebuild
10.rebuild-darwin: 501+
10.rebuild-darwin: 5001+
10.rebuild-linux: 501+
10.rebuild-linux: 5001+
labels
Aug 25, 2021
nomeata
added a commit
to dfinity/motoko
that referenced
this pull request
Aug 25, 2021
in #2532 we added a patch related to static building of ocaml packages, submitted to nixpkgs as NixOS/nixpkgs#124498, but it was never merged upstream. Supposedly a patch from NixOS/nixpkgs#135619 fixes it as well (and maybe more properly). So let’s try that!
This was referenced Aug 25, 2021
r-burns
force-pushed
the
fpie-musl-fixes
branch
from
September 4, 2021 20:24
04ee46b
to
9336e63
Compare
cc @TredwellGit since it looks like you're running into some of these issues in #104091 |
11 tasks
ofborg
bot
added
the
2.status: merge conflict
This PR has merge conflicts with the target branch
label
Sep 17, 2021
r-burns
force-pushed
the
fpie-musl-fixes
branch
from
September 17, 2021 03:10
9d272e3
to
4831116
Compare
ofborg
bot
removed
the
2.status: merge conflict
This PR has merge conflicts with the target branch
label
Sep 17, 2021
veprbl
reviewed
Sep 20, 2021
fixes: pkgsMusl.bulletml pkgsMusl.proot pkgsMusl.python3 Debian explains this issue well in the dpkg-buildflags manpage: -fPIE Can be linked into any program, but not a shared library (recommended). -fPIC Can be linked into any program and shared library. On projects that build both programs and shared libraries you might need to make sure that when building the shared libraries -fPIC is always passed last (so that it overrides any previous -PIE) to compilation flags such as CFLAGS. (from https://manpages.debian.org/bullseye/dpkg-dev/dpkg-buildflags.1.en.html#hardening)
fixes e.g.: pkgsMusl.libfsm pkgsMusl.libiscsi pkgsMusl.nsjail pkgsMusl.pv match strings have whitespace on either side, which wasn't matching leading/trailing arguments previously
This is no longer needed with the previous PIE hardening fixes. This reverts commit 78d20f2.
This is no longer needed with the previous PIE hardening fixes. This reverts commit 74e0aaa.
This is no longer needed with the previous PIE hardening fixes. This reverts commit 2784f1b.
r-burns
force-pushed
the
fpie-musl-fixes
branch
from
September 21, 2021 00:25
4831116
to
a41b83c
Compare
veprbl
approved these changes
Sep 21, 2021
12 tasks
5 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
6.topic: python
10.rebuild-darwin: 501+
10.rebuild-darwin: 5001+
10.rebuild-darwin-stdenv
This PR causes stdenv to rebuild
10.rebuild-linux: 501+
10.rebuild-linux: 5001+
10.rebuild-linux-stdenv
This PR causes stdenv to rebuild
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.
Fixes a number of packages which were broken on musl (where PIE hardening is currently enabled). For example:
Motivation for this change
Fixes #124476
Things done
sandbox = true
set innix.conf
? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)