mirror of
https://github.com/kakwa/ldapcherry
synced 2024-11-22 17:34:21 +01:00
documentation for ppolicy API
This commit is contained in:
parent
324eddf04f
commit
29abe4b1a8
@ -1,7 +1,34 @@
|
|||||||
Package ldapcherry.ppolicy
|
Implementing password policy modules
|
||||||
==========================
|
====================================
|
||||||
|
|
||||||
.. automodule:: ldapcherry.ppolicy
|
API
|
||||||
:members:
|
---
|
||||||
:undoc-members:
|
|
||||||
|
The password policy modules must respect following API:
|
||||||
|
|
||||||
|
.. autoclass:: ldapcherry.ppolicy.PPolicy
|
||||||
|
:members: check, info, __init__
|
||||||
|
:undoc-members: check
|
||||||
:show-inheritance:
|
:show-inheritance:
|
||||||
|
|
||||||
|
Configuration
|
||||||
|
-------------
|
||||||
|
|
||||||
|
Parameters are declared in the main configuration file, inside the **ppolicy** section.
|
||||||
|
|
||||||
|
After having set **self.config** to **config** in the constructor, parameters can be recovered
|
||||||
|
by **self.get_param**:
|
||||||
|
|
||||||
|
.. autoclass:: ldapcherry.ppolicy.PPolicy
|
||||||
|
:members: get_param
|
||||||
|
:undoc-members: check
|
||||||
|
:show-inheritance:
|
||||||
|
|
||||||
|
Example
|
||||||
|
-------
|
||||||
|
|
||||||
|
Here is the simple default ppolicy module that comes with LdapCherry:
|
||||||
|
|
||||||
|
.. literalinclude:: ../ldapcherry/ppolicy/simple.py
|
||||||
|
:language: python
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user