2021-03-25 10:28:57 +00:00
|
|
|
{ stdenv, lib, fetchFromGitHub, openssl, makeWrapper, python3, coreutils }:
|
2016-02-02 23:02:31 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "cipherscan";
|
2016-09-04 05:26:00 +00:00
|
|
|
version = "2016-08-16";
|
|
|
|
|
2016-02-02 23:02:31 +00:00
|
|
|
src = fetchFromGitHub {
|
2016-09-04 05:26:00 +00:00
|
|
|
owner = "mozilla";
|
2016-02-02 23:02:31 +00:00
|
|
|
repo = "cipherscan";
|
2016-09-04 05:26:00 +00:00
|
|
|
rev = "74dd82e8ad994a140daf79489d3bd1c5ad928d38";
|
|
|
|
sha256 = "16azhlmairnvdz7xmwgvfpn2pzw1p8z7c9b27m07fngqjkpx0mhh";
|
2016-02-02 23:02:31 +00:00
|
|
|
};
|
2016-09-04 05:26:00 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
2021-03-25 10:28:57 +00:00
|
|
|
buildInputs = [ python3 ];
|
|
|
|
|
|
|
|
strictDeps = true;
|
2016-09-04 05:26:00 +00:00
|
|
|
|
2016-02-02 23:02:31 +00:00
|
|
|
buildPhase = ''
|
2016-09-04 05:26:00 +00:00
|
|
|
substituteInPlace cipherscan --replace '$0' 'cipherscan'
|
2016-02-02 23:02:31 +00:00
|
|
|
'';
|
2016-09-04 05:26:00 +00:00
|
|
|
|
2016-02-02 23:02:31 +00:00
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
|
|
|
|
cp cipherscan $out/bin
|
|
|
|
cp openssl.cnf $out/bin
|
2016-09-04 05:26:00 +00:00
|
|
|
cp analyze.py $out/bin/cipherscan-analyze
|
2016-02-02 23:02:31 +00:00
|
|
|
|
2016-09-04 05:26:00 +00:00
|
|
|
wrapProgram $out/bin/cipherscan \
|
|
|
|
--set NOAUTODETECT 1 \
|
|
|
|
--set TIMEOUTBIN "${coreutils}/bin/timeout" \
|
|
|
|
--set OPENSSLBIN "${openssl}/bin/openssl"
|
2016-02-02 23:02:31 +00:00
|
|
|
'';
|
2016-09-04 05:26:00 +00:00
|
|
|
|
2016-02-02 23:02:31 +00:00
|
|
|
meta = with lib; {
|
2016-09-04 05:26:00 +00:00
|
|
|
inherit (src.meta) homepage;
|
2016-02-02 23:02:31 +00:00
|
|
|
description = "Very simple way to find out which SSL ciphersuites are supported by a target";
|
2016-02-03 18:10:34 +00:00
|
|
|
license = licenses.mpl20;
|
2016-02-02 23:02:31 +00:00
|
|
|
platforms = platforms.all;
|
2016-09-04 05:26:00 +00:00
|
|
|
maintainers = with maintainers; [ cstrahan fpletz ];
|
2016-02-02 23:02:31 +00:00
|
|
|
};
|
|
|
|
}
|