Bug 2167430
| Summary: | redhat-rpm-config: hardening does not enable PIC mode for assembler files | |||
|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Vladis Dronov <vdronov> | |
| Component: | redhat-rpm-config | Assignee: | Florian Weimer <fweimer> | |
| Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | |
| Severity: | medium | Docs Contact: | ||
| Priority: | unspecified | |||
| Version: | 38 | CC: | ajax, carl, ffesti, fweimer, igor.raits, jakub, j, maxwell, mhroncok, mpolacek, ngompa13, nickc, pmatilai, sipoyare, thoger, torsava | |
| Target Milestone: | --- | Flags: | fweimer:
needinfo?
(jakub) |
|
| Target Release: | --- | |||
| Hardware: | All | |||
| OS: | Linux | |||
| Whiteboard: | ||||
| Fixed In Version: | redhat-rpm-config-258-1.fc39 | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | ||
| Clone Of: | ||||
| : | 2208504 (view as bug list) | Environment: | ||
| Last Closed: | 2023-07-05 13:58:37 UTC | Type: | Bug | |
| Regression: | --- | Mount Type: | --- | |
| Documentation: | --- | CRM: | ||
| Verified Versions: | Category: | --- | ||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
| Cloudforms Team: | --- | Target Upstream Version: | ||
| Embargoed: | ||||
| Bug Depends On: | ||||
| Bug Blocks: | 2208504 | |||
|
Description
Vladis Dronov
2023-02-06 15:50:39 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 38 development cycle. Changing version to 38. Jakub, what's your recommendation to fix this? Thanks.
I tried this, and it appears to work:
*cc1_options:
+ %{!r:%{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}}
*cpp_options:
+ %{!r:%{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}}
(In reply to Florian Weimer from comment #2) > Jakub, what's your recommendation to fix this? Thanks. > > I tried this, and it appears to work: > > *cc1_options: > + %{!r:%{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}} > > *cpp_options: > + %{!r:%{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}} Rather than cpp_options, shouldn't it be asm_options? Otherwise I think it makes sense. (In reply to Marek Polacek from comment #3) > (In reply to Florian Weimer from comment #2) > > Jakub, what's your recommendation to fix this? Thanks. > > > > I tried this, and it appears to work: > > > > *cc1_options: > > + %{!r:%{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}} > > > > *cpp_options: > > + %{!r:%{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}} > > Rather than cpp_options, shouldn't it be asm_options? Otherwise I think it > makes sense. It doesn't work: as: invalid option -- 'P' GAS does not accept -fPIC etc., but the preprocessor does to set up __PIC__ etc. macros. Indeed, I just realized that asm_ isn't going to work. LGTM then. |