All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
1.4.0 - 2025-04-11
- log:
- Support de-facto standard
NO_COLOR
environment variable by disabling ANSI colors when this variable is set with non-empty value (#45). - Support optional logger component used as prefix of every log entries.
- Support de-facto standard
- settings: Support parameters deprecation (#48).
- auth:
- Introduce
JWTBaseManager
for more generic and versatile JWT encode and decode management with custom claimset. - Introduce
jwt_validate_expiration()
function to load and validate expiration of JWT without its signature.
- Introduce
- log: Disable debug by default with
DaemonFormatter
similarly toTTYFormatter
.
- auth:
- Catch
ldap.OPERATIONS_ERROR
on LDAP users list and user DN lookup searches (#40). - Support binary non-ascii JWT private signature key by default with option to expect text key.
- Catch
1.3.0 - 2025-02-03
- auth:
- Introduce
AnonymousUser
class as a child ofAuthenticatedUser
withis_anonynous()
onAuthenticatedUser
class to tell if user is anonymous. - Add posibility to lookup user DN in the scope of user base subtree before trying authentication instead of expecting the DN is the basic concatenation of the user name attribute, the login and the user base (#30→#36).
- Introduce
- perms: Add
RBACPolicyManager.disable_anonymous()
as a mean to disable anonymous role even if defined in loaded authorization policy (#35→#39)
- web: Change error description and log message when unauthorized to access
endpoint with
@rbac_action
decorator with anonymous token in order to match access without token.
- perms: Fix retrieval of anonymous user permissions as defined in authorization policy (#29→#31).
- web:
- Deny access without bearer token in
@check_jwt
and@rbac_action
decorators (#33,#37→#34,#38). - Add missing dependency on Flask package.
- Deny access without bearer token in
1.2.0 - 2024-11-26
- settings: print list parameters as comma-separated list of values for more readability (#27).
- permissions: Do not attribute anonymous role by default anymore to authenticated users.
- core:
AttributeError
withasyncio.tasks._gather
on Python 3.6 (#23). - settings:
- Print URL as readable string in dumps (#25).
- Print IP/network addresses as readable strings in dumps (#26).
1.1.1 - 2024-11-05
- web: Add warning log entry in case of JWT decode error.
- settings: Valid ip and network default values were wrongly reported having the wrong type.
1.1.0 - 2024-10-18
- core: Introduce
asyncio
module withasyncio_run()
wrapper with a backported version ofasyncio.run()
compatible with Python 3.6 (#11). - settings:
- Add
dump()
method onRuntimeSettings
class to print all settings with their value and origin on standard output. - Add
name
attribute onSettingsDefinitionLoaderYaml
andRuntimeSettingsSiteLoaderIni
classes. - Add
_origin
dict attribute onRuntimeSettingsSection
to keep tracks of origin of parameters values. - Support new
password
type of parameters, similar to strings but it is not printed as clear text when dumped (#7). - Support new
ip
andnetwork
types of parameters which return Pythonipaddress.IPv{4,6}Address
andipaddress.IPv{4,6}Network
objects respectively (#8).
- Add
- auth: When retrieving users with
users()
method, raiseLDAPAuthenticationError
only when user name attribute is missing in all retrieved user entries, instead of raising as soon as it is missing in any user entry. Warning log message is emitted for all user entries that miss the attribute (#12).
1.0.3 - 2024-08-30
- core: Introduce
utils
module withshlex_join
function to backportshlex.join()
from Python >= 3.8. - auth:
- Add
user_primary_group_attribute
argument toLDAPAuthentifier
class initializer with default value gidNumber to define an alternative user primary group ID attribute (#4). - Add
group_object_classes
argument toLDAPAuthentifier
class initializer with default values posixGroup and groupOfNames to define alternative LDAP group object classes (#6).
- Add
- auth: Support absence of primary group attribute optional in LDAP user entries (#5).
- auth: Handle
UnicodeDecodeError
when loading JWT private key (#3).
1.0.2 - 2024-06-19
- auth: Add
user_name_attribute
argument with default value uid toLDAPAuthentifier
class initializer to specify an alternative user name attribute (#2). - build: Support explicit packages list without find, lack of dependencies, lack of urls, lack and file license in PEP 518 → setup.py script generator.
- auth: Add default values for
cacert
,user_class
,user_fullname_attribute
andgroup_name_attribute
arguments ofLDAPAuthentifier
class initializer.
1.0.1 - 2024-05-08
- pkgs: add
project
andbuild-system
sections in mainpyproject.toml
to satisfy requirements of packaging build systems.