ITS Operations : SSO - OneLogin Python SAML Toolkit

(warning) This page is still under development

Overview

OneLogin's SAML Python toolkit lets you turn your Python application into a SP (Service Provider) that can be connected to an IdP (Identity Provider).

Supports:

  • SSO and SLO (SP-Initiated and IdP-Initiated).
  • Assertion and nameId encryption.
  • Assertion signatures.
  • Message signatures: AuthNRequest, LogoutRequest, LogoutResponses.
  • Enable an Assertion Consumer Service endpoint.
  • Enable a Single Logout Service endpoint.
  • Publish the SP metadata (which can be signed).

Key Features:

  • saml2int - Implements the SAML 2.0 Web Browser SSO Profile.
  • Session-less - Forget those common conflicts between the SP and the final app, the toolkit delegate session in the final app.
  • Easy to use - Programmer will be allowed to code high-level and low-level programming, 2 easy to use APIs are available.
  • Tested - Thoroughly tested.
  • Popular - OneLogin's customers use it. Add easy support to your Django/Flask web projects.

Up-to-date information and general implementation guides can be found in the onelogin/python3-saml GitHub repo.



Installation

Option 1. Download from GitHub

The toolkit is hosted on GitHub. You can download it from:

Lastest release: https://github.com/onelogin/python3-saml/releases/latest
Master repo: https://github.com/onelogin/python3-saml/tree/master
Copy the core of the library (src/onelogin/saml2 folder) and merge the setup.py inside the Python application. (Each application has its structure so take your time to locate the Python SAML toolkit in the best place).

Option 2. Download from pypi

The toolkit is hosted in pypi, you can find the python3-saml package at https://pypi.python.org/pypi/python3-saml

You can install it executing:

$ pip install python3-saml

If you want to know how a project can handle python packages review this guide and review this sampleproject