Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 1.3.14 fails to compile #314

Open
corneauf opened this issue Apr 17, 2024 · 15 comments
Open

Version 1.3.14 fails to compile #314

corneauf opened this issue Apr 17, 2024 · 15 comments

Comments

@corneauf
Copy link

While installing xmlsec 1.3.14 we encounter the following error:

#16 21.06       /tmp/pip-install-z5k61bf_/xmlsec/src/keys.c: In function ‘PyXmlSec_KeyFromEngine’:

#16 21.06       /tmp/pip-install-z5k61bf_/xmlsec/src/keys.c:218:65: error: ‘xmlSecKeyDataFormatEngine’ undeclared (first use in this function); did you mean ‘xmlSecKeyDataFormat’?

#16 21.06         218 |         key->handle = xmlSecCryptoAppKeyLoad(engine_and_key_id, xmlSecKeyDataFormatEngine, NULL, xmlSecCryptoAppGetDefaultPwdCallback(), (void*)engine_and_key_id);

#16 21.06             |                                                                 ^~~~~~~~~~~~~~~~~~~~~~~~~

#16 21.06             |                                                                 xmlSecKeyDataFormat

Looking at the project, the xmlSecKeyDataFormatEngine does not seem to be defined anywhere. I've looked the <xmlsec/crypto.h> include and it does not contain the defined struct either.

@corneauf
Copy link
Author

From the discussion here #284 it seems some code was copy pasted without the necessary context.

@jplrank
Copy link

jplrank commented Apr 17, 2024

I'm having the same issue too when installing on a Red Hat 8 system with Python 3.9.12. Version 1.3.13 installs just fine

pip install xmlsec==1.3.14
Collecting xmlsec==1.3.14
  Downloading xmlsec-1.3.14.tar.gz (68 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 68.9/68.9 kB 6.1 MB/s eta 0:00:00
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Collecting lxml>=3.8 (from xmlsec==1.3.14)
  Using cached lxml-5.2.1-cp39-cp39-manylinux_2_28_x86_64.whl.metadata (3.4 kB)
Using cached lxml-5.2.1-cp39-cp39-manylinux_2_28_x86_64.whl (5.0 MB)
Building wheels for collected packages: xmlsec
  Building wheel for xmlsec (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for xmlsec (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [39 lines of output]
      WARNING setuptools_scm.pyproject_reading toml section missing 'pyproject.toml does not contain a tool.setuptools_scm section'
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build/lib.linux-x86_64-cpython-39
      creating build/lib.linux-x86_64-cpython-39/xmlsec
      copying src/xmlsec/__init__.pyi -> build/lib.linux-x86_64-cpython-39/xmlsec
      copying src/xmlsec/constants.pyi -> build/lib.linux-x86_64-cpython-39/xmlsec
      copying src/xmlsec/template.pyi -> build/lib.linux-x86_64-cpython-39/xmlsec
      copying src/xmlsec/tree.pyi -> build/lib.linux-x86_64-cpython-39/xmlsec
      copying src/xmlsec/py.typed -> build/lib.linux-x86_64-cpython-39/xmlsec
      running build_ext
      building 'xmlsec' extension
      creating build/temp.linux-x86_64-cpython-39
      creating build/temp.linux-x86_64-cpython-39/tmp
      creating build/temp.linux-x86_64-cpython-39/tmp/pip-install-khokr2w2
      creating build/temp.linux-x86_64-cpython-39/tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b
      creating build/temp.linux-x86_64-cpython-39/tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src
      gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DXMLSEC_CRYPTO_DYNAMIC_LOADING=1 -D__XMLSEC_FUNCTION__=__func__ -DXMLSEC_NO_SIZE_T -DXMLSEC_NO_GOST=1 -DXMLSEC_NO_GOST2012=1 -DXMLSEC_DL_LIBLTDL=1 -DMODULE_NAME=xmlsec -DMODULE_VERSION=1.3.14 -I/usr/include/xmlsec1 -I/usr/include/libxml2 -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libexslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/extlibs -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/__pycache__ -I/venv/include -I/opt/python39/include/python3.9 -c /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/constants.c -o build/temp.linux-x86_64-cpython-39/tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/constants.o -g -std=c99 -fPIC -fno-strict-aliasing -Wno-error=declaration-after-statement -Werror=implicit-function-declaration -Os
      gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DXMLSEC_CRYPTO_DYNAMIC_LOADING=1 -D__XMLSEC_FUNCTION__=__func__ -DXMLSEC_NO_SIZE_T -DXMLSEC_NO_GOST=1 -DXMLSEC_NO_GOST2012=1 -DXMLSEC_DL_LIBLTDL=1 -DMODULE_NAME=xmlsec -DMODULE_VERSION=1.3.14 -I/usr/include/xmlsec1 -I/usr/include/libxml2 -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libexslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/extlibs -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/__pycache__ -I/venv/include -I/opt/python39/include/python3.9 -c /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/ds.c -o build/temp.linux-x86_64-cpython-39/tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/ds.o -g -std=c99 -fPIC -fno-strict-aliasing -Wno-error=declaration-after-statement -Werror=implicit-function-declaration -Os
      gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DXMLSEC_CRYPTO_DYNAMIC_LOADING=1 -D__XMLSEC_FUNCTION__=__func__ -DXMLSEC_NO_SIZE_T -DXMLSEC_NO_GOST=1 -DXMLSEC_NO_GOST2012=1 -DXMLSEC_DL_LIBLTDL=1 -DMODULE_NAME=xmlsec -DMODULE_VERSION=1.3.14 -I/usr/include/xmlsec1 -I/usr/include/libxml2 -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libexslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/extlibs -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/__pycache__ -I/venv/include -I/opt/python39/include/python3.9 -c /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/enc.c -o build/temp.linux-x86_64-cpython-39/tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/enc.o -g -std=c99 -fPIC -fno-strict-aliasing -Wno-error=declaration-after-statement -Werror=implicit-function-declaration -Os
      /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/enc.c: In function ‘PyXmlSec_ClearReplacedNodes’:
      /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/enc.c:207:14: warning: assignment to ‘struct LxmlElement **’ from incompatible pointer type ‘PyXmlSec_LxmlElementPtr’ {aka ‘struct LxmlElement *’} [-Wincompatible-pointer-types]
               elem = PyXmlSec_elementFactory(doc, n);
                    ^
      gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DXMLSEC_CRYPTO_DYNAMIC_LOADING=1 -D__XMLSEC_FUNCTION__=__func__ -DXMLSEC_NO_SIZE_T -DXMLSEC_NO_GOST=1 -DXMLSEC_NO_GOST2012=1 -DXMLSEC_DL_LIBLTDL=1 -DMODULE_NAME=xmlsec -DMODULE_VERSION=1.3.14 -I/usr/include/xmlsec1 -I/usr/include/libxml2 -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libexslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/extlibs -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/__pycache__ -I/venv/include -I/opt/python39/include/python3.9 -c /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/exception.c -o build/temp.linux-x86_64-cpython-39/tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/exception.o -g -std=c99 -fPIC -fno-strict-aliasing -Wno-error=declaration-after-statement -Werror=implicit-function-declaration -Os
      /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/exception.c: In function ‘PyXmlSec_ExchangeLastError’:
      /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/exception.c:76:9: warning: variable ‘r’ set but not used [-Wunused-but-set-variable]
           int r;
               ^
      gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DXMLSEC_CRYPTO_DYNAMIC_LOADING=1 -D__XMLSEC_FUNCTION__=__func__ -DXMLSEC_NO_SIZE_T -DXMLSEC_NO_GOST=1 -DXMLSEC_NO_GOST2012=1 -DXMLSEC_DL_LIBLTDL=1 -DMODULE_NAME=xmlsec -DMODULE_VERSION=1.3.14 -I/usr/include/xmlsec1 -I/usr/include/libxml2 -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libexslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxml -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/extlibs -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/libxslt -I/tmp/pip-build-env-8vp3i0k9/overlay/lib/python3.9/site-packages/lxml/includes/__pycache__ -I/venv/include -I/opt/python39/include/python3.9 -c /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/keys.c -o build/temp.linux-x86_64-cpython-39/tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/keys.o -g -std=c99 -fPIC -fno-strict-aliasing -Wno-error=declaration-after-statement -Werror=implicit-function-declaration -Os
      /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/keys.c: In function ‘PyXmlSec_KeyFromEngine’:
      /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/keys.c:218:65: error: ‘xmlSecKeyDataFormatEngine’ undeclared (first use in this function); did you mean ‘xmlSecKeyDataFormat’?
               key->handle = xmlSecCryptoAppKeyLoad(engine_and_key_id, xmlSecKeyDataFormatEngine, NULL, xmlSecCryptoAppGetDefaultPwdCallback(), (void*)engine_and_key_id);
                                                                       ^~~~~~~~~~~~~~~~~~~~~~~~~
                                                                       xmlSecKeyDataFormat
      /tmp/pip-install-khokr2w2/xmlsec_ba08e5441ebd4063854e30606f4e9b9b/src/keys.c:218:65: note: each undeclared identifier is reported only once for each function it appears in
      error: command '/usr/bin/gcc' failed with exit code 1
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for xmlsec
Failed to build xmlsec
ERROR: Could not build wheels for xmlsec, which is required to install pyproject.toml-based projects

@fram-sse
Copy link

I can confirm that this broke my build as well. ubuntu 22.04 on GHA.

@shamanthb
Copy link

I can confirm my python project build is broken as well.
Using the docker image: python:3.11-slim-bullseye.

@mxamin
Copy link
Collaborator

mxamin commented Apr 18, 2024

Thanks for the update, xmlsec1 (C library) introduced breaking changes in v1.3.x which made it hard to support old and new version at the same time. I'll note this issue and hopefully we can fix it in the new release.

@corneauf @jplrank @fram-sse @shamanthb Can you provide the following information so we can debug easier:

  • OS version and distribution
  • xmlsec1 library version
  • libxml2 version

@mxamin mxamin added the bug label Apr 18, 2024
nizamial09 added a commit to rhcs-dashboard/ceph that referenced this issue Apr 18, 2024
xmlsec is an inner dependency used by python3-saml. A newer release of
it broke the import.
xmlsec/python-xmlsec#314

Signed-off-by: Nizamudeen A <[email protected]>
@shamanthb
Copy link

@mxamin
Here are the details:
OS: Debian GNU/Linux 11
xmlsec1 version: 1.2.31
libxml2 version: libxml2-dev:arm64 (2.9.10+dfsg-6.7+deb11u4)

@jplrank
Copy link

jplrank commented Apr 18, 2024

@mxamin
Here are my details:

  • OS version and distribution: Red Hat Enterprise Linux 8.9 (Ootpa)
  • xmlsec1 library version: 1.2.25-4.el8
  • libxml2 version: 2.9.7-18.el8_9

nizamial09 added a commit to rhcs-dashboard/ceph that referenced this issue Apr 18, 2024
xmlsec is an inner dependency used by python3-saml. A newer release of
it broke the import.
xmlsec/python-xmlsec#314

Signed-off-by: Nizamudeen A <[email protected]>
relrod added a commit to ansible/django-ansible-base that referenced this issue Apr 18, 2024
This was referenced Apr 18, 2024
nizamial09 added a commit to rhcs-dashboard/ceph that referenced this issue Apr 18, 2024
xmlsec is an inner dependency used by python3-saml. A newer release of
it broke the import.
xmlsec/python-xmlsec#314

Fixes: https://tracker.ceph.com/issues/65571
Signed-off-by: Nizamudeen A <[email protected]>
@fram-sse
Copy link

fram-sse commented Apr 18, 2024

@mxamin
OS: Ubuntu 20.04.6 LTS
xmlsec1_1.2.28-2_amd64
libxml2_2.9.10+dfsg-5_amd64

@aafaque33
Copy link

Having same issue in latest installation

Python version: (3.11.6 (main, Oct 27 2023, 00:08:24) [GCC 8.5.0 20210514 (Red Hat 8.5.0-18)])
Operation System: (Rocky Linux 8.8 (Green Obsidian))
xmlsec1 version: 1.2.25
libxml2 version: 2.9.7

nizamial09 added a commit to rhcs-dashboard/ceph that referenced this issue Apr 19, 2024
xmlsec is an inner dependency used by python3-saml. A newer release of
it broke the import.
xmlsec/python-xmlsec#314

Fixes: https://tracker.ceph.com/issues/65571
Signed-off-by: Nizamudeen A <[email protected]>
(cherry picked from commit ac656f0)
MichaelRoytman added a commit to openedx-unsupported/edx-analytics-data-api that referenced this issue Apr 19, 2024
The latest version of python-xmlsec is breaking the mysql8-migrations Github action. See xmlsec/python-xmlsec#314.

The recommended course of action is to pin the vesrion of python-xmlsec in the action.
MichaelRoytman added a commit to openedx-unsupported/registrar that referenced this issue Apr 19, 2024
The latest version of python-xmlsec is breaking the mysql8-migrations Github action. See xmlsec/python-xmlsec#314.

The recommended course of action is to pin the vesrion of python-xmlsec in the action.
MichaelRoytman added a commit to openedx-unsupported/registrar that referenced this issue Apr 19, 2024
The latest version of python-xmlsec is breaking the mysql8-migrations Github action. See xmlsec/python-xmlsec#314.

The recommended course of action is to pin the version of python-xmlsec in the action.
MichaelRoytman added a commit to openedx-unsupported/edx-analytics-dashboard that referenced this issue Apr 19, 2024
The latest version of python-xmlsec is breaking the mysql-migrations Github action. See xmlsec/python-xmlsec#314.

The recommended course of action is to pin the version of python-xmlsec in the action.
MichaelRoytman added a commit to edx/portal-designer that referenced this issue Apr 19, 2024
The latest version of python-xmlsec is breaking the mysql8-migrations-check Github action. See xmlsec/python-xmlsec#314.

The recommended course of action is to pin the version of python-xmlsec in the action.
MichaelRoytman added a commit to openedx-unsupported/edx-analytics-data-api that referenced this issue Apr 19, 2024
The latest version of python-xmlsec is breaking the mysql8-migrations Github action. See xmlsec/python-xmlsec#314.

The recommended course of action is to pin the version of python-xmlsec in the action.
MichaelRoytman added a commit to openedx-unsupported/registrar that referenced this issue Apr 19, 2024
The latest version of python-xmlsec is breaking the mysql8-check-migrations Github action. See xmlsec/python-xmlsec#314.

The recommended course of action is to pin the version of python-xmlsec in the action.
MichaelRoytman added a commit to openedx-unsupported/registrar that referenced this issue Apr 19, 2024
The latest version of python-xmlsec is breaking the mysql8-check-migrations Github action. See xmlsec/python-xmlsec#314.

The recommended course of action is to pin the version of python-xmlsec in the action.
@jonathangreen
Copy link
Contributor

For the latest release there are now binary wheels uploaded to pypi for xmlsec. These wheels are compatible with lxml > 5.0.

If you are able to install both xmlsec and lxml from wheels you should be able to install the latest version.

@jonathangreen
Copy link
Contributor

The problem here is that we are not currently compatible with these older libxmlsec1 versions.

If you are able to build against a newer version of libxmlsec1 or use the wheel, which is built against the latest version, then the new release should work.

0x29a added a commit to open-craft/edx-platform that referenced this issue Apr 22, 2024
0x29a added a commit to open-craft/edx-enterprise that referenced this issue Apr 22, 2024
0x29a added a commit to open-craft/edx-enterprise that referenced this issue Apr 22, 2024
0x29a added a commit to open-craft/edx-enterprise that referenced this issue Apr 22, 2024
0x29a added a commit to open-craft/edx-enterprise that referenced this issue Apr 23, 2024
awojno-bloomberg pushed a commit to awojno-bloomberg/ceph that referenced this issue Apr 23, 2024
xmlsec is an inner dependency used by python3-saml. A newer release of
it broke the import.
xmlsec/python-xmlsec#314

Fixes: https://tracker.ceph.com/issues/65571
Signed-off-by: Nizamudeen A <[email protected]>
joscollin pushed a commit to joscollin/ceph that referenced this issue May 6, 2024
xmlsec is an inner dependency used by python3-saml. A newer release of
it broke the import.
xmlsec/python-xmlsec#314

Fixes: https://tracker.ceph.com/issues/65571
Signed-off-by: Nizamudeen A <[email protected]>
@jimjag
Copy link
Collaborator

jimjag commented May 6, 2024

Considering that older libxmlsec1 versions do have security issues, and will likely be deprecated, this may resolve itself on its own

tecoholic pushed a commit to open-craft/edx-enterprise that referenced this issue May 8, 2024
* fix: create CEA object when enrolling using a license flow

* test: verify that allow_enrollment is called_correctly

* fix: xmlsec issue

xmlsec/python-xmlsec#314
alexmv added a commit to alexmv/zulip that referenced this issue May 9, 2024
Building these libraries from source requires too much memory, and
causes OOMs on a host with 4GB of RAM when still running Zulip.

Building from source was enabled in `main` to work around
xmlsec/python-xmlsec#320, which does not occur with the xmlsec version
in the 8.x branch, as xmlsec/python-xmlsec#314 (incompatibilities with
Ubuntu 20.04) causes us to pin xmlsec<1.3.14.

As such, we switch back to using prebuilt wheels.  The version
mismatch from xmlsec/python-xmlsec#320, if real, is not new, so this
exposes us to no more risk than before.
timabbott pushed a commit to zulip/zulip that referenced this issue May 9, 2024
Building these libraries from source requires too much memory, and
causes OOMs on a host with 4GB of RAM when still running Zulip.

Building from source was enabled in `main` to work around
xmlsec/python-xmlsec#320, which does not occur with the xmlsec version
in the 8.x branch, as xmlsec/python-xmlsec#314 (incompatibilities with
Ubuntu 20.04) causes us to pin xmlsec<1.3.14.

As such, we switch back to using prebuilt wheels.  The version
mismatch from xmlsec/python-xmlsec#320, if real, is not new, so this
exposes us to no more risk than before.
tecoholic pushed a commit to open-craft/edx-enterprise that referenced this issue Aug 12, 2024
* fix: create CEA object when enrolling using a license flow
* test: verify that allow_enrollment is called_correctly
* fix: xmlsec issue
    xmlsec/python-xmlsec#314
* build: enable CI for pull requests
* style: fix some pycodestyle issues
tecoholic pushed a commit to open-craft/edx-enterprise that referenced this issue Aug 17, 2024
@bitti
Copy link

bitti commented Oct 1, 2024

Also happens under RHEL9:

OS: Red Hat Enterprise Linux release 9.2 (Plow)
xmlsec1 version: 1.2.29-9.el9
libxml2 version: 2.9.13-6.el9_4

@jimjag
Copy link
Collaborator

jimjag commented Oct 2, 2024

Can you provide logs of the build error for RHEL9?

@jarshwah
Copy link

jarshwah commented Nov 7, 2024

For the latest release there are now binary wheels uploaded to pypi for xmlsec. These wheels are compatible with lxml > 5.0.

If you are able to install both xmlsec and lxml from wheels you should be able to install the latest version.

I don't think this is right, don't they both compile against different versions of libxml2? Do we know, specifically, which version of libxml2 is used in the xmlsec wheels?

We also use python3-saml which depends on xmlsec, and we were seeing seg faults when using binary wheel versions of xmlsec 1.3.14 and lxml 5.2.2 - see SAML-Toolkits/python3-saml#389 for more details.

I tried installing lxml from source which should use the system libxml2 - and that is compatible with xmlsec 1.3.13 but not with 1.3.14.

So I tried building xmlsec from source @ 1.3.14 and I run into this same compilation failure. So, no matter what I do, I can't seem to have python3-saml + lxml + xmlsec==1.3.14 on the same system.

OS: Linux 6d2916178dc5 6.10.4-linuxkit #1 SMP Wed Oct 2 16:38:00 UTC 2024 aarch64 GNU/Linux
xmlsec1 version: 1.3.14
libxml2 version: 2.9.10+dfsg-6.7+deb11u5
Docker base image: python:3.11.10-slim-bullseye

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

10 participants