mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2026-01-15 00:12:35 +08:00
- Create archivebox/config/ldap.py with LDAPConfig class - Create archivebox/ldap/ Django app with custom auth backend - Update core/settings.py to conditionally load LDAP when enabled - Add LDAP_CREATE_SUPERUSER support to auto-grant superuser privileges - Add comprehensive tests in test_auth_ldap.py (no mocks, no skips) - LDAP only activates if django-auth-ldap is installed and LDAP_ENABLED=True - Helpful error messages when LDAP libraries are missing or config is incomplete Fixes #1664 Co-authored-by: Nick Sweeting <pirate@users.noreply.github.com>
18 lines
495 B
Python
18 lines
495 B
Python
"""
|
|
LDAP authentication module for ArchiveBox.
|
|
|
|
This module provides native LDAP authentication support using django-auth-ldap.
|
|
It only activates if:
|
|
1. LDAP_ENABLED=True in config
|
|
2. Required LDAP libraries (python-ldap, django-auth-ldap) are installed
|
|
|
|
To install LDAP dependencies:
|
|
pip install archivebox[ldap]
|
|
|
|
Or manually:
|
|
apt install build-essential python3-dev libsasl2-dev libldap2-dev libssl-dev
|
|
pip install python-ldap django-auth-ldap
|
|
"""
|
|
|
|
__package__ = "archivebox.ldap"
|