8014a2
Summary: A tool for generating SELinux security policies for containers
8014a2
Name: udica
8014a2
Version: 0.2.6
94e892
Release: 30%{?dist}
8014a2
Source0: https://github.com/containers/udica/archive/v%{version}.tar.gz
8014a2
Patch0: 0001-Make-sure-each-section-of-the-inspect-exists-before-.patch
8014a2
License: GPLv3+
8014a2
BuildArch: noarch
8014a2
Url: https://github.com/containers/udica
8014a2
%if 0%{?fedora} || 0%{?rhel} > 7
8014a2
BuildRequires: python3 python3-devel python3-setuptools
8014a2
Requires: python3 python3-libsemanage python3-libselinux
8014a2
%else
8014a2
BuildRequires: python2 python2-devel python2-setuptools
8014a2
Requires: python2 libsemanage-python libselinux-python
8014a2
%endif
8014a2
# container-selinux provides policy templates
8014a2
Requires: container-selinux >= 2.168.0-2
8014a2
8014a2
%description
8014a2
Tool for generating SELinux security profiles for containers based on
8014a2
inspection of container JSON file.
8014a2
8014a2
%prep
8014a2
%autosetup -p 1
8014a2
8014a2
%build
8014a2
%if 0%{?fedora} || 0%{?rhel} > 7
8014a2
%{__python3} setup.py build
8014a2
%else
8014a2
%{__python2} setup.py build
8014a2
%endif
8014a2
8014a2
%install
8014a2
%if 0%{?fedora} || 0%{?rhel} > 7
8014a2
%{__python3} setup.py install --single-version-externally-managed --root=%{buildroot}
8014a2
%else
8014a2
%{__python2} setup.py install --single-version-externally-managed --root=%{buildroot}
8014a2
%endif
8014a2
8014a2
install --directory %{buildroot}%{_mandir}/man8
8014a2
install -m 0644 udica/man/man8/udica.8 %{buildroot}%{_mandir}/man8/udica.8
8014a2
8014a2
%files
8014a2
%{_mandir}/man8/udica.8*
8014a2
%{_bindir}/udica
8014a2
%dir %{_datadir}/udica
8014a2
%dir %{_datadir}/udica/ansible
8014a2
%{_datadir}/udica/ansible/*
8014a2
8014a2
%if 0%{?fedora} || 0%{?rhel} > 7
8014a2
%license LICENSE
8014a2
%{python3_sitelib}/udica/
8014a2
%{python3_sitelib}/udica-*.egg-info
8014a2
%else
8014a2
%{_datarootdir}/licenses/udica/LICENSE
8014a2
%{python2_sitelib}/udica/
8014a2
%{python2_sitelib}/udica-*.egg-info
8014a2
%endif
8014a2
8014a2
%changelog
94e892
* Fri Jan 27 2023 Vit Mojzis <vmojzis@redhat.com> - 0.2.6-30
94e892
- Bump release to preserve upgrade path (#2160401)
94e892
8014a2
* Wed Dec 01 2021 Vit Mojzis <vmojzis@redhat.com> - 0.2.6-4
8014a2
- Make sure each section of the inspect exists before accessing (#2027656)
8014a2
8014a2
* Tue Sep 21 2021 Vit Mojzis <vmojzis@redhat.com> - 0.2.6-3
8014a2
- Require container-selinux shipping policy templates (#2000051)
8014a2
8014a2
* Fri Sep 17 2021 Jindrich Novy <jnovy@redhat.com> - 0.2.6-2
8014a2
- use RHEL-9 product version for gating
8014a2
- Related: #2000051
8014a2
8014a2
* Thu Sep 16 2021 Jindrich Novy <jnovy@redhat.com> - 0.2.6-1
8014a2
- update to https://github.com/containers/udica/releases/tag/v0.2.6
8014a2
- Related: #2000051
8014a2
8014a2
* Fri Sep 03 2021 Jindrich Novy <jnovy@redhat.com> - 0.2.5-2
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.2.5 (#1995041)
8014a2
- Replace capability dictionary with str.lower()
8014a2
- Enable udica to generate policies with fifo class
8014a2
- Sort container inspect data before processing
8014a2
- Update templates to work properly with new cil parser
8014a2
- Related: #2000051
8014a2
8014a2
* Wed Aug 25 2021 Vit Mojzis <vmojzis@redhat.com> - 0.2.5-1
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.2.5 (#1995046)
8014a2
- Replace capability dictionary with str.lower()
8014a2
- Enable udica to generate policies with fifo class
8014a2
- Sort container inspect data before processing
8014a2
- Update templates to work properly with new cil parser
8014a2
8014a2
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 0.2.4-9
8014a2
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
8014a2
  Related: rhbz#1991688
8014a2
8014a2
* Mon Jun 14 2021 Jindrich Novy <jnovy@redhat.com> - 0.2.4-8
8014a2
- remove %%check again and all related BRs
8014a2
8014a2
* Mon Jun 14 2021 Jindrich Novy <jnovy@redhat.com> - 0.2.4-7
8014a2
- remove black from BR
8014a2
8014a2
* Mon Jun 14 2021 Jindrich Novy <jnovy@redhat.com> - 0.2.4-6
8014a2
- Add missing BR
8014a2
- Related: #1970747
8014a2
8014a2
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 0.2.4-5
8014a2
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
8014a2
8014a2
* Tue Mar 16 2021 Vit Mojzis <vmojzis@redhat.com> - 0.2.4-4
8014a2
- Remove %%check section
8014a2
8014a2
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.4-3
8014a2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
8014a2
8014a2
* Sun Dec 13 2020 Lukas Vrabec <lvrabec@redhat.com> - 0.2.4-2
8014a2
- Add %%check section to run basic tests during rpm build process
8014a2
8014a2
* Wed Nov 25 2020 Lukas Vrabec <lvrabec@redhat.com> - 0.2.4-1
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.2.4
8014a2
8014a2
* Thu Aug 13 2020 Lukas Vrabec <lvrabec@redhat.com> - 0.2.3-1
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.2.3
8014a2
8014a2
* Mon Aug 03 2020 Lukas Vrabec <lvrabec@redhat.com> - 0.2.2-1
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.2.2
8014a2
8014a2
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.1-4
8014a2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
8014a2
8014a2
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 0.2.1-3
8014a2
- Rebuilt for Python 3.9
8014a2
8014a2
* Fri Jan 31 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.1-2
8014a2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
8014a2
8014a2
* Fri Oct 25 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.2.1-1
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.2.1
8014a2
8014a2
* Wed Sep 25 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.2.0-1
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.2.0
8014a2
8014a2
* Wed Aug 28 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.9-1
8014a2
- Update tests test_basic.podman.cil, test_basic.docker.cil. Round 2
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.1.9
8014a2
8014a2
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 0.1.8-3
8014a2
- Rebuilt for Python 3.8
8014a2
8014a2
* Sat Jul 27 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.8-2
8014a2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
8014a2
8014a2
* Thu Jul 11 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.8-1
8014a2
- New rebase https://github.com/containers/udica/releases/tag/v0.1.8
8014a2
8014a2
* Wed Jun 12 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.7-1
8014a2
- New rebase with upstream adding new param --ansible, to generate ansible playbook for deploying policies. https://github.com/containers/udica/releases/tag/v0.1.7
8014a2
8014a2
* Thu May 16 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.6-1
8014a2
- New rebase with upstream adding new tests
8014a2
8014a2
* Tue Apr 30 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.5-2
8014a2
- Add allow rules for container_runtime_t to base_container.cil, Podman version 1.2.0 requires new allow rules.
8014a2
* Fri Apr 19 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.5-1
8014a2
- Create mock selinux and semanage module
8014a2
- Update testing section in README
8014a2
- Add travis file for Travis CI
8014a2
- Grammar fixes in the udica.8 manpage file
8014a2
- Support port ranges (Resolves: #16)
8014a2
- Test port ranges
8014a2
8014a2
* Mon Mar 11 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.4-1
8014a2
- Fix minor problems reported by pylint #11
8014a2
- Catch FileNotFoundError when inspecting containers #12
8014a2
- Create basic tests #13
8014a2
- Restore working directory #14
8014a2
- udica cannot use the container ID once it is provided #10
8014a2
8014a2
* Mon Feb 25 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.3-4
8014a2
- Update manpage with the latest known bug described in https://github.com/containers/udica/issues/8
8014a2
- Add check if runtimes are installed on the system
8014a2
8014a2
* Sun Feb 17 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.3-3
8014a2
- Improve capability parsing for docker containers
8014a2
- Update small changes in manpage, like issue with mandatory option '-c' for docker containers
8014a2
- Fix parsing Mountpoints in docker inspect JSON file
8014a2
8014a2
* Sun Feb 03 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.3-2
8014a2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
8014a2
8014a2
* Wed Jan 23 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.3-1
8014a2
- Fix capability allow rules when capabilities are specified in JSON file
8014a2
- Add additional SELinux allow rules to base container template to allow container to read proc_type types.
8014a2
8014a2
* Fri Jan 04 2019 Lukas Vrabec <lvrabec@redhat.com> - 0.1.2-1
8014a2
- Fix invalid syntax output when policy is using just one template
8014a2
Resolves: #6
8014a2
8014a2
* Tue Oct 23 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.1.1-2
8014a2
- Fix small issues in spec file like improve description and change files section.
8014a2
8014a2
* Mon Oct 22 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.1.1-1
8014a2
- Add proper shebang to all source files
8014a2
- Add License to all source files
8014a2
8014a2
* Sat Oct 13 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.1.0-1
8014a2
- Add support for docker containers
8014a2
8014a2
* Mon Oct 08 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.0.5-1
8014a2
- Update x_container template based on testing container related to Nvidia Cuda operations
8014a2
8014a2
* Mon Oct 08 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.0.4-2
8014a2
- Build udica on Red Hat Enterprise Linux 7 with python version 2
8014a2
8014a2
* Mon Oct 08 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.0.4-1
8014a2
- Add manpages
8014a2
- Add support for communicating with libvirt daemon
8014a2
- Add support for communicating with X server.
8014a2
- Add support for read/write to the controlling terminal
8014a2
8014a2
* Sun Oct 07 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.0.3-1
8014a2
- Remove required parameters -i or -j and added support for reading json file from stdin.
8014a2
- Remove "-n" or "--name" parameter. Name of the container will be required for this tool
8014a2
8014a2
* Tue Sep 25 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.0.2-1
8014a2
- Use subprocess.Popen instead of subprocess.run for inspecting to support also python2
8014a2
8014a2
* Thu Sep 20 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.0.1-3
8014a2
- Update readme and setup.py files after migration to github
8014a2
8014a2
* Sun Sep 16 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.0.1-2
8014a2
- Update LICENSE
8014a2
- Improve %%files section
8014a2
8014a2
* Sun Sep 16 2018 Lukas Vrabec <lvrabec@redhat.com> - 0.0.1-1
8014a2
- Initial build