Skip to main content
https://img.shields.io/pypi/v/xmlsec.svg?logo=python&logoColor=white https://img.shields.io/travis/com/mehcode/python-xmlsec/master.svg?logo=travis&logoColor=white&label=Travis%20CI https://img.shields.io/appveyor/ci/hoefling/xmlsec/master.svg?logo=appveyor&logoColor=white&label=AppVeyor https://github.com/mehcode/python-xmlsec/workflows/manylinux2010/badge.svg https://github.com/mehcode/python-xmlsec/workflows/MacOS/badge.svg https://github.com/mehcode/python-xmlsec/workflows/linuxbrew/badge.svg https://codecov.io/gh/mehcode/python-xmlsec/branch/master/graph/badge.svg Documentation Status

Python bindings for the XML Security Library.

Documentation

A documentation for xmlsec can be found at xmlsec.readthedocs.io.

Usage

Check the examples section in the documentation to see various examples of signing and verifying using the library.

Requirements

  • libxml2 >= 2.9.1

  • libxmlsec1 >= 1.2.18

Install

xmlsec is available on PyPI:

pip install xmlsec

Depending on your OS, you may need to install the required native libraries first:

Linux (Debian)

apt-get install libxml2-dev libxmlsec1-dev libxmlsec1-openssl

Note: There is no required version of LibXML2 for Ubuntu Precise, so you need to download and install it manually.

wget http://xmlsoft.org/sources/libxml2-2.9.1.tar.gz
tar -xvf libxml2-2.9.1.tar.gz
cd libxml2-2.9.1
./configure && make && make install

Linux (CentOS)

yum install libxml2-devel xmlsec1-devel xmlsec1-openssl-devel libtool-ltdl-devel

Linux (Fedora)

dnf install libxml2-devel xmlsec1-devel xmlsec1-openssl-devel libtool-ltdl-devel

Mac

brew install libxml2 libxmlsec1 pkg-config

Alpine

apk add build-base libressl libffi-dev libressl-dev libxslt-dev libxml2-dev xmlsec-dev xmlsec

Troubleshooting

Mac

If you get any fatal errors about missing .h files, update your C_INCLUDE_PATH environment variable to include the appropriate files from the libxml2 and libxmlsec1 libraries.

Windows

Starting with 1.3.7, prebuilt wheels are available for Windows, so running pip install xmlsec should suffice. If you want to build from source:

  1. Configure build environment, see wiki.python.org for more details.

  2. Install from source dist:

    pip install xmlsec --no-binary=xmlsec

Building from source

  1. Clone the xmlsec source code repository to your local computer.

    git clone https://github.com/mehcode/python-xmlsec.git
  2. Change into the python-xmlsec root directory.

    cd /path/to/xmlsec
  3. Install the project and all its dependencies using pip.

    pip install .

Contributing

Setting up your environment

  1. Follow steps 1 and 2 of the manual installation instructions.

  2. Initialize a virtual environment to develop in. This is done so as to ensure every contributor is working with close-to-identicial versions of packages.

    mkvirtualenv xmlsec

    The mkvirtualenv command is available from virtualenvwrapper package which can be installed by following link.

  3. Activate the created virtual environment:

    workon xmlsec
  4. Install xmlsec in development mode with testing enabled. This will download all dependencies required for running the unit tests.

    pip install -r requirements-test.txt
    pip install -e "."

Running the test suite

  1. Set up your environment.

  2. Run the unit tests.

    pytest tests
  3. Tests configuration

    Env variable PYXMLSEC_TEST_ITERATIONS specifies number of test iterations to detect memory leaks.

Reporting an issue

Please attach the output of following information:

  • version of xmlsec

  • version of libxmlsec1

  • version of libxml2

  • output from the command

    pkg-config --cflags xmlsec1

License

Unless otherwise noted, all files contained within this project are licensed under the MIT opensource license. See the included LICENSE file or visit opensource.org for more information.

Release files for xmlsec 1.3.11

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for xmlsec 1.3.11
File Size Uploaded
xmlsec-1.3.11.tar.gz 61.3 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for xmlsec 1.3.11
File
xmlsec-1.3.11-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details
xmlsec-1.3.11-cp39-cp39-win32.whl CPython 3.9 CPython 3.9 Windows x86-32 Details
xmlsec-1.3.11-cp38-cp38-win_amd64.whl CPython 3.8 CPython 3.8 Windows x86-64 Details
xmlsec-1.3.11-cp38-cp38-win32.whl CPython 3.8 CPython 3.8 Windows x86-32 Details
xmlsec-1.3.11-cp37-cp37m-win_amd64.whl CPython 3.7 CPython 3.7 pymalloc Windows x86-64 Details
xmlsec-1.3.11-cp37-cp37m-win32.whl CPython 3.7 CPython 3.7 pymalloc Windows x86-32 Details
xmlsec-1.3.11-cp36-cp36m-win_amd64.whl CPython 3.6 CPython 3.6 pymalloc Windows x86-64 Details
xmlsec-1.3.11-cp36-cp36m-win32.whl CPython 3.6 CPython 3.6 pymalloc Windows x86-32 Details
xmlsec-1.3.11-cp35-cp35m-win_amd64.whl CPython 3.5 CPython 3.5 pymalloc Windows x86-64 Details
xmlsec-1.3.11-cp35-cp35m-win32.whl CPython 3.5 CPython 3.5 pymalloc Windows x86-32 Details

Total release size: 17.6 MB

Release files / xmlsec-1.3.11.tar.gz

Download URL xmlsec-1.3.11.tar.gz
Size 61.3 kB
Tags Source
SHA-256 checksum
How to use checksums
cd2eaaff7f31784a07dd99ce81fa767313df3ba1834faa4143ee2c07000cac7a
BLAKE2b-256 checksum
How to use checksums
ffdd0893ae620bfe3537eaa91c3a24e70dceba616b0cc71ed8e9fe9d0289fe34
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.5

Release files / xmlsec-1.3.11-cp39-cp39-win_amd64.whl

Download URL xmlsec-1.3.11-cp39-cp39-win_amd64.whl
Size 1.9 MB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
4fb38ab0bf3e47cbae136119674a869e09d61c939b510350f369c8ac46087373
BLAKE2b-256 checksum
How to use checksums
9827d91697a59419dc09c935f4208a09ec4616f2ffe61d4a452fe0ecd5e580e6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.0

Release files / xmlsec-1.3.11-cp39-cp39-win32.whl

Download URL xmlsec-1.3.11-cp39-cp39-win32.whl
Size 1.6 MB
Tags CPython 3.9 Windows x86-32
SHA-256 checksum
How to use checksums
843d10bba4c480609da74ee11fff1ee0fc1c12821c656979f12a7a4ecb043e03
BLAKE2b-256 checksum
How to use checksums
d769ce30beabe841229d3355abfccf3a45ca09984136338d9deddaaec7257e5e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.9.0

Release files / xmlsec-1.3.11-cp38-cp38-win_amd64.whl

Download URL xmlsec-1.3.11-cp38-cp38-win_amd64.whl
Size 1.9 MB
Tags CPython 3.8 Windows x86-64
SHA-256 checksum
How to use checksums
23f209260b37bdc2fd96af837494c47dd1e67964f077442b63acd83c0f62e212
BLAKE2b-256 checksum
How to use checksums
330ff1ea1bcf7dbfc09a553e3d302dcb36a10eecd83bc07187f14eeaddeb45ba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.8.0

Release files / xmlsec-1.3.11-cp38-cp38-win32.whl

Download URL xmlsec-1.3.11-cp38-cp38-win32.whl
Size 1.6 MB
Tags CPython 3.8 Windows x86-32
SHA-256 checksum
How to use checksums
c7b49d4fce83186b89f7ce6cec765245d36a70d0acc2f3ed0ba95c735b3667da
BLAKE2b-256 checksum
How to use checksums
d9382b8d1322ccf4ec4877833a6ab8ebf3592383fc2b5b7e2821be917fe6df39
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.8.0

Release files / xmlsec-1.3.11-cp37-cp37m-win_amd64.whl

Download URL xmlsec-1.3.11-cp37-cp37m-win_amd64.whl
Size 1.9 MB
Tags CPython 3.7 CPython 3.7 pymalloc Windows x86-64
SHA-256 checksum
How to use checksums
ee233d0bc27fb8f447ca2622b0de2ac2df45b8795f02ef263825912011fe4fe9
BLAKE2b-256 checksum
How to use checksums
aa7b98f8d6ef14c06c1429cb432c2380022fea5bf2badb53bd6f778c6caf1acd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.7.5

Release files / xmlsec-1.3.11-cp37-cp37m-win32.whl

Download URL xmlsec-1.3.11-cp37-cp37m-win32.whl
Size 1.6 MB
Tags CPython 3.7 CPython 3.7 pymalloc Windows x86-32
SHA-256 checksum
How to use checksums
dea5bef9b5830c36ccb7a68a0d94d49eaea4d03fbbd04179652bf661b7e6e30f
BLAKE2b-256 checksum
How to use checksums
ea7c0bd6f832b94cc10e1ab1c31bc769e33cb44802167f6296b347013d9931d3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.7.5

Release files / xmlsec-1.3.11-cp36-cp36m-win_amd64.whl

Download URL xmlsec-1.3.11-cp36-cp36m-win_amd64.whl
Size 1.9 MB
Tags CPython 3.6 CPython 3.6 pymalloc Windows x86-64
SHA-256 checksum
How to use checksums
86d54b93f8278e2f0c504d0744e39a483c1c7ce9993f2ca70184cc7770faa982
BLAKE2b-256 checksum
How to use checksums
961393000dfd14d2d4524df00126397c1d306a7bc48611c0661aaad25d831efb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.6.8

Release files / xmlsec-1.3.11-cp36-cp36m-win32.whl

Download URL xmlsec-1.3.11-cp36-cp36m-win32.whl
Size 1.6 MB
Tags CPython 3.6 CPython 3.6 pymalloc Windows x86-32
SHA-256 checksum
How to use checksums
eadff662d89c80db409c69d82eb3e695e16d4a5e8ab56b5b22670a54e9c6ff20
BLAKE2b-256 checksum
How to use checksums
05afd8f93ff0a4ddf1a301eeb1dbc6f4adc424be036e9817bfef9b9207ec684b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.3.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.6.8

Release files / xmlsec-1.3.11-cp35-cp35m-win_amd64.whl

Download URL xmlsec-1.3.11-cp35-cp35m-win_amd64.whl
Size 1.9 MB
Tags CPython 3.5 CPython 3.5 pymalloc Windows x86-64
SHA-256 checksum
How to use checksums
705ab5b848afdf3a5c78b1322276054c885f44dc51601e14cb883a9c86cbe20f
BLAKE2b-256 checksum
How to use checksums
baffff7e783b43879e76738358855a8c035d53a1f65ac7ced5714c45cb2ae449
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.7.0 requests/2.25.1 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.5.4

Release files / xmlsec-1.3.11-cp35-cp35m-win32.whl

Download URL xmlsec-1.3.11-cp35-cp35m-win32.whl
Size 1.6 MB
Tags CPython 3.5 CPython 3.5 pymalloc Windows x86-32
SHA-256 checksum
How to use checksums
8922fba55a060ee81de4a7f5efc593c5bf121047763aecf0eead02e061c9d2db
BLAKE2b-256 checksum
How to use checksums
8569c93c32048b4b84f2ec8da4284083bf478b594b2a5c914819b306e81a2c6d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.7.0 requests/2.25.1 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.61.0 CPython/3.5.4

Release history Release notifications | RSS feed

This release

1.3.11 This release

11 release files

1.3.9

13 release files

1.3.8

11 release files

1.3.7

11 release files

1.3.3

1 release file

1.3.2

1 release file

1.3.1

1 release file

1.2.0

1 release file

1.1.0

1 release file

1.0.9

1 release file

1.0.8

1 release file

1.0.7

1 release file

1.0.6

1 release file

1.0.5

1 release file

1.0.4

1 release file

1.0.3

1 release file

1.0.1

1 release file

0.6.1

1 release file

0.6.0

1 release file

0.5.0

1 release file

0.4.0

1 release file

0.3.3

1 release file

0.3.2

0.3.1

1 release file

0.3.0

1 release file

0.2.0

1 release file

0.1.2

1 release file

0.1.1

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page