Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 setuptools, 6 pyopenssl, 7 tldextract, 8 pytestCheckHook, 9 pythonOlder, 10}: 11 12buildPythonPackage rec { 13 pname = "certauth"; 14 version = "1.3.0"; 15 pyproject = true; 16 17 disabled = pythonOlder "3.7"; 18 19 src = fetchFromGitHub { 20 owner = "ikreymer"; 21 repo = "certauth"; 22 # Repo has no git tags, https://github.com/ikreymer/certauth/issues/15 23 rev = "ad2bae5d40a9e45519fc1f2cd7678174bbc55b3d"; 24 hash = "sha256-Rso5N0jb9k7bdorjPIUMNiZZPnzwbkxFNiTpsJ9pco0="; 25 }; 26 27 postPatch = '' 28 substituteInPlace setup.py \ 29 --replace-fail "--cov certauth " "" 30 ''; 31 32 nativeBuildInputs = [ setuptools ]; 33 34 propagatedBuildInputs = [ 35 pyopenssl 36 tldextract 37 ]; 38 39 nativeCheckInputs = [ pytestCheckHook ]; 40 41 pythonImportsCheck = [ "certauth" ]; 42 43 disabledTests = [ 44 # https://github.com/ikreymer/certauth/issues/23 45 "test_ca_cert_in_mem" 46 "test_custom_not_before_not_after" 47 # Tests want to download Public Suffix List 48 "test_file_wildcard" 49 "test_file_wildcard_subdomains" 50 "test_in_mem_parent_wildcard_cert" 51 "test_in_mem_parent_wildcard_cert_at_tld" 52 "test_in_mem_parent_wildcard_cert_2" 53 ]; 54 55 meta = with lib; { 56 description = "Simple CertificateAuthority and host certificate creation, useful for man-in-the-middle HTTPS proxy"; 57 mainProgram = "certauth"; 58 homepage = "https://github.com/ikreymer/certauth"; 59 license = licenses.mit; 60 maintainers = with maintainers; [ Luflosi ]; 61 }; 62}