Django LastPass SAML authenticator
Project description
This is a hacky extension to django-saml-service-provider that, instead of onelogin, uses LastPass Enterprise as an IdP.
Installation
Get it from PyPI:
pip install django-lastpass-sp
Example configuration
# Check the LastPass SAML metadata for the bits after '.../login/'
LASTPASS_CONNECTOR_ID = '1234567/abc4'
# This is the certificate given by LastPass
# or LASTPASS_CERTIFICATE if you want the cert in your conf
LASTPASS_CERTIFICATE_FILE = os.path.join(BASE_DIR, 'lastpass.crt')
# Private key, try it like this:
# openssl genrsa > samlsp.key
# or SAML_SP_KEY if you want the key in your conf
SAML_SP_KEY_FILE = os.path.join(BASE_DIR, 'samlsp.key')
# Certificate, try with self-signed:
# openssl req -new -x509 -key samlsp.key -out samlsp.crt -days 365
# or SAML_SP_CERTIFICATE if you want the key in your conf
SAML_SP_CERTIFICATE_FILE = os.path.join(BASE_DIR, 'samlsp.crt')
# Optional!
# Contact info provided in the metadata
SAML_SP_CONTACT_INFO = {
"technical": {
"givenName": "Admin",
"emailAddress": "admin@example.com",
}
}
# Optional!
# Ditto for organization info
SAML_SP_ORGANIZATION_INFO = {
"en-US": {
"name": "acme",
"displayname": 'Acme Inc',
"url": "http://example.com/",
}
}
AUTHENTICATION_BACKENDS = (
# This is just so you don't block yourself out
#'django.contrib.auth.backends.ModelBackend',
# This is the beef
'sp.auth_backend.SAMLServiceProviderBackend',
)
# Optional
# Create new users with admin and/or staff accounts
# Both default to False
LASTPASS_CREATE_ADMIN = True
LASTPASS_CREATE_STAFF = True
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
django-lastpass-sp-0.1.4.tar.gz
(21.0 kB
view details)
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file django-lastpass-sp-0.1.4.tar.gz.
File metadata
- Download URL: django-lastpass-sp-0.1.4.tar.gz
- Upload date:
- Size: 21.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8818fe3eb83eb6b6aab3dc7992036bc2c88b1204084fb068d032df00ab72b6aa
|
|
| MD5 |
a460bf924ba7c85e17894d772d3710d1
|
|
| BLAKE2b-256 |
636b9900048a6fc6ae9f40aa2220877f54df2ea10189b2f853d65fd1852cca83
|
File details
Details for the file django_lastpass_sp-0.1.4-py3-none-any.whl.
File metadata
- Download URL: django_lastpass_sp-0.1.4-py3-none-any.whl
- Upload date:
- Size: 13.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
698f79e427bcea4e86f45a7d7bf6c3ed2826bcc9baef3221702948c4e70e2d73
|
|
| MD5 |
76c7d4ed7474b64e53dff1b6f79653ec
|
|
| BLAKE2b-256 |
83f9277bc0fe40961b21203c0b5b639c284feadad54d10259f0c576663a1e044
|
File details
Details for the file django_lastpass_sp-0.1.4-py2-none-any.whl.
File metadata
- Download URL: django_lastpass_sp-0.1.4-py2-none-any.whl
- Upload date:
- Size: 13.0 kB
- Tags: Python 2
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c77dc75cadade74726b45051f3cb24193b777d6eb5bf741033985c43fed74adb
|
|
| MD5 |
f6dbc6546c45db59d960f0abc3620cd6
|
|
| BLAKE2b-256 |
6f9c06514fa1b57182e27c5c74f2afeeba3620beed2352f259c735d082d99835
|