saltstack / saltstack/salt

[BUG] ldap module broken after upgrade to 3006.2

Open
#64,962 11 comments 0 reactions 1 assignee View on GitHub

Nobody has claimed this yet.

bug Regression Sulfur v3006.2
Dominant language
Python
Stars
15.7k
Forks
5.6k
Avg merge
2d 44m
Merged PRs (30d)
80

Description

Description
On a clean install of 3006.2 on AlmaLinux 9, the ldap module fails to import with the following error:

$ /opt/saltstack/salt/bin/python3 -c 'import ldap'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/opt/saltstack/salt/extras-3.10/ldap/__init__.py", line 34, in <module>
    import _ldap
ImportError: /lib64/libldap.so.2: undefined symbol: EVP_md2, version OPENSSL_3.0.0

It works with 3006.1, as well as the system Python.

Steps to Reproduce the behavior

$ podman run --rm -it almalinux:9
$ curl -o bootstrap-salt.sh -L https://bootstrap.saltproject.io
$ bash bootstrap-salt.sh onedir
$ rpm -qf `which salt-pip`
salt-3006.2-0.x86_64
$ dnf install gcc openldap-devel
$ rpm -q openldap-devel
openldap-devel-2.6.2-3.el9.x86_64
$ salt-pip install python-ldap
Collecting python-ldap
  Downloading python-ldap-3.4.3.tar.gz (377 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━ 377.4/377.4 kB 8.8 MB/s eta 0:00:00
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Collecting pyasn1-modules>=0.1.5
  Downloading pyasn1_modules-0.3.0-py2.py3-none-any.whl (181 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━ 181.3/181.3 kB 22.3 MB/s eta 0:00:00
Collecting pyasn1>=0.3.7
  Downloading pyasn1-0.5.0-py2.py3-none-any.whl (83 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━ 83.9/83.9 kB 64.4 MB/s eta 0:00:00
Building wheels for collected packages: python-ldap
  Building wheel for python-ldap (pyproject.toml) ... done
  Created wheel for python-ldap: filename=python_ldap-3.4.3-cp310-cp310-linux_x86_64.whl size=317527 sha256=caec96d436be13a253a9e328e3cafd4257429b96f17a44210e05df38d283f479
  Stored in directory: /root/.cache/pip/wheels/46/da/1e/560bb8f6a776fb7e42af5f32f40360f4bd4674710337e1b087
Successfully built python-ldap
Installing collected packages: pyasn1, pyasn1-modules, python-ldap
  WARNING: In `rpath_only mode` but /lib64/libldap.so.2 is not in /opt/saltstack/salt
  WARNING: In `rpath_only mode` but /lib64/liblber.so.2 is not in /opt/saltstack/salt
  WARNING: In `rpath_only mode` but /lib64/libevent-2.1.so.7 is not in /opt/saltstack/salt
  WARNING: In `rpath_only mode` but /lib64/libsasl2.so.3 is not in /opt/saltstack/salt
  WARNING: In `rpath_only mode` but /lib64/libcrypt.so.2 is not in /opt/saltstack/salt
  WARNING: In `rpath_only mode` but /lib64/libcom_err.so.2 is not in /opt/saltstack/salt
  WARNING: In `rpath_only mode` but /lib64/libkeyutils.so.1 is not in /opt/saltstack/salt
  WARNING: In `rpath_only mode` but /lib64/libselinux.so.1 is not in /opt/saltstack/salt
  WARNING: In `rpath_only mode` but /lib64/libpcre2-8.so.0 is not in /opt/saltstack/salt
  Do not adjust rpath of /tmp/pip-target-zabty43p/_ldap.cpython-310-x86_64-linux-gnu.so
Successfully installed pyasn1-0.5.0 pyasn1-modules-0.3.0 python-ldap-3.4.3

$ /opt/saltstack/salt/bin/python3 -c 'import ldap'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/opt/saltstack/salt/extras-3.10/ldap/__init__.py", line 34, in <module>
    import _ldap
ImportError: /lib64/libldap.so.2: undefined symbol: EVP_md2, version OPENSSL_3.0.0

Repeating the above with bootstrap-salt.sh stable 3006.1 works as expected. For now we're switching to the ldap3 module in our external pillars.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.