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