Bug 1289728

Summary: Harden all packages: git executables should use PIE and have RELRO enabled
Product: [Fedora] Fedora Reporter: Christian Stadelmann <fedora>
Component: gitAssignee: Todd Zullinger <tmz>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 23CC: chrisw, jbowes, moez.roy, pstodulk, tmz
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: git-2.7.4-2.fc24 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-07-12 15:04:05 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: 1199775    

Description Christian Stadelmann 2015-12-08 20:24:10 UTC
Description of problem:
According to [1] packages should be hardened. git executables are not, according to checksec:

Partial RELRO   Canary found      NX enabled    No PIE          No RPATH   No RUNPATH   /usr/bin/git
Partial RELRO   Canary found      NX enabled    No PIE          No RPATH   No RUNPATH   /usr/bin/git-receive-pack
Partial RELRO   Canary found      NX enabled    No PIE          No RPATH   No RUNPATH   /usr/bin/git-shell
Partial RELRO   Canary found      NX enabled    No PIE          No RPATH   No RUNPATH   /usr/bin/git-upload-archive
Partial RELRO   Canary found      NX enabled    No PIE          No RPATH   No RUNPATH   /usr/bin/git-upload-pack

Version-Release number of selected component (if applicable):
git-2.5.0-3.fc23.x86_64

[1] https://fedoraproject.org//wiki/Changes/Harden_All_Packages

Comment 1 Todd Zullinger 2016-04-11 20:52:22 UTC
I added 'LDFLAGS = %{__global_ldflags}' to the git config.mak we use for building.  That should resolve the issue.

Comment 2 Christian Stadelmann 2016-04-22 10:03:59 UTC
Can you please build F24 packages with these flags too?

Comment 3 Petr Stodulka 2016-07-01 11:41:17 UTC
Done. Can You test that everything is correct? I must go now, so I will let testing for karma.

Comment 4 Fedora Update System 2016-07-07 10:45:48 UTC
git-2.7.4-2.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-3cb435075f

Comment 5 Fedora Update System 2016-07-10 15:59:39 UTC
git-2.7.4-2.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-3cb435075f

Comment 6 Fedora Update System 2016-07-12 15:04:02 UTC
git-2.7.4-2.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.