2021-12-19 01:06:50 +00:00
|
|
|
{ lib
|
|
|
|
, olefile
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, poetry-core
|
|
|
|
, cryptography
|
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
|
|
|
, setuptools
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "msoffcrypto-tool";
|
2023-08-04 22:07:22 +00:00
|
|
|
version = "5.1.1";
|
2021-12-19 01:06:50 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
disabled = pythonOlder "3.8";
|
2021-12-19 01:06:50 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "nolze";
|
|
|
|
repo = pname;
|
2023-03-04 12:14:45 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2023-08-04 22:07:22 +00:00
|
|
|
hash = "sha256-A1TeTE4TMHAb+KtFxTi+b4yTfuEFya8iyzy92dzQ0Z4=";
|
2021-12-19 01:06:50 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
poetry-core
|
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
cryptography
|
|
|
|
olefile
|
|
|
|
setuptools
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-12-19 01:06:50 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# Test fails with AssertionError
|
|
|
|
"test_cli"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"msoffcrypto"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python tool and library for decrypting MS Office files with passwords or other keys";
|
|
|
|
homepage = "https://github.com/nolze/msoffcrypto-tool";
|
2023-03-04 12:14:45 +00:00
|
|
|
changelog = "https://github.com/nolze/msoffcrypto-tool/blob/v${version}/CHANGELOG.md";
|
2021-12-19 01:06:50 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|