2018-12-06 10:53:53 +01:00
|
|
|
{ stdenv, fetchurl, libcap, openssl, pam }:
|
2005-09-12 17:20:57 +02:00
|
|
|
|
2013-11-07 16:14:59 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2015-07-28 13:11:25 +02:00
|
|
|
name = "vsftpd-3.0.3";
|
2013-11-07 16:14:59 +01:00
|
|
|
|
2005-09-12 17:20:57 +02:00
|
|
|
src = fetchurl {
|
2012-12-29 12:22:20 +01:00
|
|
|
url = "https://security.appspot.com/downloads/${name}.tar.gz";
|
2015-07-28 13:11:25 +02:00
|
|
|
sha256 = "1xsyjn68k3fgm2incpb3lz2nikffl9by2safp994i272wvv2nkcx";
|
2005-09-12 17:20:57 +02:00
|
|
|
};
|
2011-04-29 20:18:56 +02:00
|
|
|
|
2018-12-06 10:53:53 +01:00
|
|
|
buildInputs = [ libcap openssl pam ];
|
|
|
|
|
2015-07-15 22:12:29 +02:00
|
|
|
patches = [ ./CVE-2015-1419.patch ];
|
|
|
|
|
2018-12-06 10:53:53 +01:00
|
|
|
postPatch = ''
|
2013-11-07 16:14:59 +01:00
|
|
|
sed -i "/VSF_BUILD_SSL/s/^#undef/#define/" builddefs.h
|
|
|
|
|
2018-12-06 10:53:53 +01:00
|
|
|
substituteInPlace Makefile \
|
|
|
|
--replace -dirafter "" \
|
|
|
|
--replace /usr $out \
|
|
|
|
--replace /etc $out/etc
|
2013-01-03 19:52:14 +01:00
|
|
|
|
2018-12-06 10:53:53 +01:00
|
|
|
mkdir -p $out/sbin $out/man/man{5,8}
|
|
|
|
'';
|
2011-04-23 08:58:57 +02:00
|
|
|
|
2018-12-06 10:53:53 +01:00
|
|
|
NIX_LDFLAGS = "-lcrypt -lssl -lcrypto -lpam -lcap";
|
2011-04-23 08:58:57 +02:00
|
|
|
|
2018-12-06 10:53:53 +01:00
|
|
|
enableParallelBuilding = true;
|
2016-08-02 18:06:29 +02:00
|
|
|
|
2018-12-06 10:53:53 +01:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A very secure FTP daemon";
|
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = with maintainers; [ peterhoeg ];
|
|
|
|
platforms = platforms.linux;
|
2016-08-02 18:06:29 +02:00
|
|
|
};
|
2013-11-07 16:14:59 +01:00
|
|
|
}
|