git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #7189 from arno01/hardenpostfix
bed68eaPeter Simons
pkgs/servers/mail/postfix/2.11.nix+3−2
@@ -33,8 +33,9 @@ stdenv.mkDerivation rec {
33 export sendmail_path=$out/bin/sendmail
33 export sendmail_path=$out/bin/sendmail
34
34
35 make makefiles \
35 make makefiles \
36− CCARGS='-DUSE_TLS -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${cyrus_sasl}/include/sasl' \
36+ CCARGS='-DUSE_TLS -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${cyrus_sasl}/include/sasl \
37+ -fPIE -fstack-protector-all --param ssp-buffer-size=4 -O2 -D_FORTIFY_SOURCE=2' \
37− AUXLIBS='-ldb -lnsl -lresolv -lsasl2 -lcrypto -lssl'
38+ AUXLIBS='-ldb -lnsl -lresolv -lsasl2 -lcrypto -lssl -pie -Wl,-z,relro,-z,now'
38 '';
39 '';
39
40
40 installTargets = [ "non-interactive-package" ];
41 installTargets = [ "non-interactive-package" ];
pkgs/servers/mail/postfix/default.nix+1−1
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
34 export sample_directory=$out/share/postfix/doc/samples
34 export sample_directory=$out/share/postfix/doc/samples
35 export readme_directory=$out/share/postfix/doc
35 export readme_directory=$out/share/postfix/doc
36
36
37− make makefiles CCARGS='-DUSE_TLS -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${cyrus_sasl}/include/sasl' AUXLIBS='-lssl -lcrypto -lsasl2 -ldb -lnsl'
37+ make makefiles CCARGS='-DUSE_TLS -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${cyrus_sasl}/include/sasl -fPIE -fstack-protector-all --param ssp-buffer-size=4 -O2 -D_FORTIFY_SOURCE=2' AUXLIBS='-lssl -lcrypto -lsasl2 -ldb -lnsl -pie -Wl,-z,relro,-z,now'
38 '';
38 '';
39
39
40 installPhase = ''
40 installPhase = ''