[DSE-Dev] Bug#980270: python3-setools: needs newer dependencies

Russell Coker russell at coker.com.au
Sat Jan 16 23:37:23 GMT 2021


Package: python3-setools
Version: 4.3.0-1.1+b1
Severity: normal

# sesearch -A -s httpd_t -d httpd_sys_content_t
Traceback (most recent call last):
  File "/usr/bin/sesearch", line 20, in <module>
    import setools
  File "/usr/lib/python3/dist-packages/setools/__init__.py", line 78, in <module>
    from .infoflow import InfoFlowAnalysis
  File "/usr/lib/python3/dist-packages/setools/infoflow.py", line 23, in <module>
    import networkx as nx
  File "/usr/lib/python3/dist-packages/networkx/__init__.py", line 114, in <module>
    import networkx.generators
  File "/usr/lib/python3/dist-packages/networkx/generators/__init__.py", line 14, in <module>
    from networkx.generators.intersection import *
  File "/usr/lib/python3/dist-packages/networkx/generators/intersection.py", line 13, in <module>
    from networkx.algorithms import bipartite
  File "/usr/lib/python3/dist-packages/networkx/algorithms/__init__.py", line 16, in <module>
    from networkx.algorithms.dag import *
  File "/usr/lib/python3/dist-packages/networkx/algorithms/dag.py", line 23, in <module>
    from fractions import gcd
ImportError: cannot import name 'gcd' from 'fractions' (/usr/lib/python3.9/fractions.py)

The above happens on a system that hasn't had a full dist-upgrade, just
upgrades of selected packages and their dependencies.

Firstly the package depends on libsepol1 (>= 2.9), if that was even possible
to install it probably wouldn't work.  Changing the dependencies to the latest
version of the SE Linux libraries every time is probably the best strategy.

It turns out that having python3-networkx version 2.2-1 installed (significantly
newer than the version 2.0 that python3-setools depends on) caused the problem.
Upgrading python3-networkx to 2.5+ds-2 made sesearch work correctly.

-- System Information:
Debian Release: 10.7
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 5.10.0-1-amd64 (SMP w/12 CPU cores)
Kernel taint flags: TAINT_FIRMWARE_WORKAROUND
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8), LANGUAGE=en_AU:en (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: SELinux: enabled - Mode: Enforcing - Policy name: default

Versions of packages python3-setools depends on:
ii  libc6                  2.31-9
ii  libselinux1            3.1-2+b2
ii  libsepol1              3.1-1
ii  python3                3.9.1-1
ii  python3-networkx       2.2-1
ii  python3-pkg-resources  40.8.0-1

python3-setools recommends no packages.

python3-setools suggests no packages.

-- no debconf information



More information about the SELinux-devel mailing list