Skip to main content

Python bindings for the XML Security Library

Project description

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 pkg-config 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.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

xmlsec-1.3.13.tar.gz (64.6 kB view details)

Uploaded Source

Built Distributions

xmlsec-1.3.13-cp310-cp310-win_amd64.whl (1.9 MB view details)

Uploaded CPython 3.10 Windows x86-64

xmlsec-1.3.13-cp310-cp310-win32.whl (1.6 MB view details)

Uploaded CPython 3.10 Windows x86

xmlsec-1.3.13-cp39-cp39-win_amd64.whl (1.9 MB view details)

Uploaded CPython 3.9 Windows x86-64

xmlsec-1.3.13-cp39-cp39-win32.whl (1.6 MB view details)

Uploaded CPython 3.9 Windows x86

xmlsec-1.3.13-cp38-cp38-win_amd64.whl (1.9 MB view details)

Uploaded CPython 3.8 Windows x86-64

xmlsec-1.3.13-cp38-cp38-win32.whl (1.6 MB view details)

Uploaded CPython 3.8 Windows x86

xmlsec-1.3.13-cp37-cp37m-win_amd64.whl (1.9 MB view details)

Uploaded CPython 3.7m Windows x86-64

xmlsec-1.3.13-cp37-cp37m-win32.whl (1.6 MB view details)

Uploaded CPython 3.7m Windows x86

xmlsec-1.3.13-cp36-cp36m-win_amd64.whl (1.9 MB view details)

Uploaded CPython 3.6m Windows x86-64

xmlsec-1.3.13-cp36-cp36m-win32.whl (1.6 MB view details)

Uploaded CPython 3.6m Windows x86

xmlsec-1.3.13-cp35-cp35m-win_amd64.whl (1.9 MB view details)

Uploaded CPython 3.5m Windows x86-64

xmlsec-1.3.13-cp35-cp35m-win32.whl (1.6 MB view details)

Uploaded CPython 3.5m Windows x86

File details

Details for the file xmlsec-1.3.13.tar.gz.

File metadata

  • Download URL: xmlsec-1.3.13.tar.gz
  • Upload date:
  • Size: 64.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for xmlsec-1.3.13.tar.gz
Algorithm Hash digest
SHA256 916f5d78e8041f6cd9391abba659da8c94a4fef7196d126d40af1ff417f2cf86
MD5 93f88028282552bb1c99d6f4dde12d73
BLAKE2b-256 379f342d4562eac99178d0d515c780285e107c6828cefad37d02f05b7b7d8751

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for xmlsec-1.3.13-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 46d1daf16a8f4430efca5bb9c6a15776f2671f69f48a1941d6bb335e6f8cb29d
MD5 a5b3de84411ffeef66af37d979828525
BLAKE2b-256 97c1f7d68da7ff04e08f4141eaf04f605769dd7a64ac6ce411a8dfd15f714f28

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp310-cp310-win32.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp310-cp310-win32.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: CPython 3.10, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.6

File hashes

Hashes for xmlsec-1.3.13-cp310-cp310-win32.whl
Algorithm Hash digest
SHA256 2174e8c88555383322d8b7d3927490a92ef72ad72a6ddaf4fa1b96a3f27c3e90
MD5 3f542ef815816f71955353b9e378f9eb
BLAKE2b-256 198ddd240b3936db22e943db8bc118fe682a93290415f353ab221f8f0c6f9308

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for xmlsec-1.3.13-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 5162f416179350587c4ff64737af68a846a9b86f95fd465df4e68b589ce56618
MD5 a0470eedfb463661f75e2fe50e54dc90
BLAKE2b-256 c90610563c244775c54d6091e62102bd6869b2ba8a30ca383064f86ed7ce089e

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp39-cp39-win32.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp39-cp39-win32.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: CPython 3.9, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for xmlsec-1.3.13-cp39-cp39-win32.whl
Algorithm Hash digest
SHA256 091f23765729df6f3b3a55c8a6a96f9c713fa86e76b86a19cdb756aaa6dc0646
MD5 6105f42a093c364bb5221bc6404cc16e
BLAKE2b-256 7d1ea60e9b379fe28ac32717e04640fca62f7a5da068c6b6c33f7b3fc230b2ac

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.0

File hashes

Hashes for xmlsec-1.3.13-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 e6626bece0e97a8598b5df28c27bc6f2ae1e97d29dca3c1a4910a7598a4d1d0f
MD5 ab4f311a4e6ef3a64f201c642e5d4d2a
BLAKE2b-256 0d04cebdd14b861bd3ffa9cc5f5b0b15dc3e851ce53304590c37bcf104b2bea0

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp38-cp38-win32.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp38-cp38-win32.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: CPython 3.8, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.0

File hashes

Hashes for xmlsec-1.3.13-cp38-cp38-win32.whl
Algorithm Hash digest
SHA256 56cfcf3487b6ad269eb1fb543c04dee2c101f1bc91e06d6cf7bfab9ac486efd8
MD5 b6f1626ee4a07cd6c6b6843102cb9012
BLAKE2b-256 1a284e76f3845e50bfbb0e97b72618d660bd1d77ea4923d433700d8ddf3d0fa5

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.7.5

File hashes

Hashes for xmlsec-1.3.13-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 d249c0a2bf3ff13a231bca6a588e7d276b3f1e2cf09316b542f470a63855799e
MD5 c4c24926cb5b5ba5e00e17eeac9fb3a9
BLAKE2b-256 d8d665e1bd2cb6fdde271457c8af2d0451d350577618baa6c75f099e3ee8eae3

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp37-cp37m-win32.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp37-cp37m-win32.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: CPython 3.7m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.7.5

File hashes

Hashes for xmlsec-1.3.13-cp37-cp37m-win32.whl
Algorithm Hash digest
SHA256 ff1c61f296e75cba5bac802d0000bfde09143eed946ced1a5162211867c335f8
MD5 d042c6c294e2667ea031b4e7eda1d256
BLAKE2b-256 5af18c80455f1a0fa6c34f32a890d2425b5893dab93c65bbc816eceb9a4b64ce

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.3 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.11 tqdm/4.64.0 importlib-metadata/4.8.3 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.5 CPython/3.6.8

File hashes

Hashes for xmlsec-1.3.13-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 1f8c41162152d7086fd459926e61bc7cb2d52ffc829e760bf8b2c221a645d568
MD5 7ed01babc1caf34fedda5780c0d14cce
BLAKE2b-256 2dc70e36fb25209c07115034191ac82aff9f71b726d904d415be5fe89fa1dfb3

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp36-cp36m-win32.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp36-cp36m-win32.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: CPython 3.6m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.3 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.11 tqdm/4.64.0 importlib-metadata/4.8.3 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.5 CPython/3.6.8

File hashes

Hashes for xmlsec-1.3.13-cp36-cp36m-win32.whl
Algorithm Hash digest
SHA256 1725d70ee2bb2cd8dd66c7a7451be02bb59dc8280103db4f68e731f00135b1e0
MD5 308a17683dfdda4d22c27b30eb103f3e
BLAKE2b-256 83bec0669dae95ec0ae55a748a8b6714948eb0e2f8b019e5e01ea78fcb7a806b

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp35-cp35m-win_amd64.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp35-cp35m-win_amd64.whl
  • Upload date:
  • Size: 1.9 MB
  • Tags: CPython 3.5m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.8.2 requests/2.25.1 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.64.0 CPython/3.5.4

File hashes

Hashes for xmlsec-1.3.13-cp35-cp35m-win_amd64.whl
Algorithm Hash digest
SHA256 7c7e8ef52688ddaf5b66750cc8d901f61716f46727014ff012f41d8858cedeb0
MD5 00b50287828f0609fa2d7c76aec4199d
BLAKE2b-256 3fe549ca397b7616659abdb5b550c393c91d86598df8371770088510182fbdc4

See more details on using hashes here.

Provenance

File details

Details for the file xmlsec-1.3.13-cp35-cp35m-win32.whl.

File metadata

  • Download URL: xmlsec-1.3.13-cp35-cp35m-win32.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: CPython 3.5m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.8.2 requests/2.25.1 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.64.0 CPython/3.5.4

File hashes

Hashes for xmlsec-1.3.13-cp35-cp35m-win32.whl
Algorithm Hash digest
SHA256 d47062c42775a025aa94fb8b15de97c1db86e301e549d3168157e0b1223d51b1
MD5 86ea22c13e4f2b6609a044c23ec38ff8
BLAKE2b-256 5c30fafb47d92fbc1bcd238b1dd92f1a580a6ca2d1e4e7b0a06cce8ab0d0ca55

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page