File python-pypykatz.spec of Package python-pypykatz
#
# spec file for package python-pypykatz
#
# Copyright (c) 2024, Martin Hauke <mardnh@gmx.de>
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: python-pypykatz
Version: 0.6.9
Release: 0
Summary: Python implementation of Mimikatz
License: MIT
URL: https://github.com/skelsec/pypykatz
Source: https://github.com/skelsec/pypykatz/archive/refs/tags/%{version}.tar.gz#/pypykatz-%{version}.tar.gz
BuildRequires: python-rpm-macros
BuildRequires: %{python_module pip}
BuildRequires: %{python_module setuptools >= 61.0.0}
BuildRequires: %{python_module wheel }
## SECTION test requirements
#BuildRequires: %%{python_module pytest}
#BuildRequires: %%{python_module pytest-asyncio}
#BuildRequires: %%{python_module aesedb >= 0.1.4}
#BuildRequires: %%{python_module aiosmb >= 0.4.8}
#BuildRequires: %%{python_module aiowinreg >= 0.0.10}
#BuildRequires: %%{python_module minidump >= 0.0.21}
#BuildRequires: %%{python_module minikerberos >= 0.4.1}
#BuildRequires: %%{python_module msldap >= 0.5.7}
#BuildRequires: %%{python_module tqdm}
#BuildRequires: %%{python_module unicrypto >= 0.0.10}
#BuildRequires: %%{python_module winacl >= 0.1.7}
## /SECTION
BuildRequires: fdupes
Requires: python-aesedb >= 0.1.4
Requires: python-aiosmb >= 0.4.8
Requires: python-aiowinreg >= 0.0.10
Requires: python-minidump >= 0.0.21
Requires: python-minikerberos >= 0.4.1
Requires: python-msldap >= 0.5.7
Requires: python-tqdm
Requires: python-unicrypto >= 0.0.10
Requires: python-winacl >= 0.1.7
Requires(post): update-alternatives
Requires(postun):update-alternatives
BuildArch: noarch
%python_subpackages
%description
Python implementation of Mimikatz
%prep
%autosetup -p1 -n pypykatz-%{version}
find pypykatz -name "*.py" -exec sed -i -e '/^#!\//, 1d' {} \;
%build
%pyproject_wheel
%install
%pyproject_install
%python_clone -a %{buildroot}%{_bindir}/pypykatz
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
#%%pytest
# disabled for now - testfiles are not public yet
# tests/config.py:TESTFILES_DIR = '/mnt/hgfs/!SHARED/test_dumps/ok'
%post
%python_install_alternative pypykatz
%postun
%python_uninstall_alternative pypykatz
%files %{python_files}
%license LICENSE
%doc README.md
%python_alternative %{_bindir}/pypykatz
%{python_sitelib}/pypykatz
%{python_sitelib}/pypykatz-%{version}.dist-info
%changelog