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