2020-03-09 09:11:07 +00:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
|
2022-08-05 10:28:29 +00:00
|
|
|
# Copyright (c) 2016, Peter Sagerson <psagers@ignorare.net>
|
|
|
|
# Copyright (c) 2016, Jiri Tyr <jiri.tyr@gmail.com>
|
|
|
|
# Copyright (c) 2017-2018 Keller Fuchs (@KellerFuchs) <kellerfuchs@hashbang.sh>
|
|
|
|
# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
|
|
|
|
# SPDX-License-Identifier: GPL-3.0-or-later
|
2020-03-09 09:11:07 +00:00
|
|
|
|
2020-06-24 19:50:36 +00:00
|
|
|
from __future__ import (absolute_import, division, print_function)
|
|
|
|
__metaclass__ = type
|
|
|
|
|
2020-03-09 09:11:07 +00:00
|
|
|
|
|
|
|
class ModuleDocFragment(object):
|
|
|
|
# Standard LDAP documentation fragment
|
2024-12-27 13:30:17 +00:00
|
|
|
DOCUMENTATION = r"""
|
2020-03-09 09:11:07 +00:00
|
|
|
options:
|
|
|
|
bind_dn:
|
|
|
|
description:
|
2024-12-27 13:30:17 +00:00
|
|
|
- A DN to bind with. Try to use a SASL bind with the EXTERNAL mechanism as default when this parameter is omitted.
|
|
|
|
- Use an anonymous bind if the parameter is blank.
|
2020-03-09 09:11:07 +00:00
|
|
|
type: str
|
|
|
|
bind_pw:
|
|
|
|
description:
|
2023-06-10 07:28:40 +00:00
|
|
|
- The password to use with O(bind_dn).
|
2020-03-09 09:11:07 +00:00
|
|
|
type: str
|
2022-11-01 18:25:51 +00:00
|
|
|
default: ''
|
2023-03-22 06:39:58 +00:00
|
|
|
ca_path:
|
|
|
|
description:
|
|
|
|
- Set the path to PEM file with CA certs.
|
|
|
|
type: path
|
|
|
|
version_added: "6.5.0"
|
2023-06-15 05:19:29 +00:00
|
|
|
client_cert:
|
|
|
|
type: path
|
|
|
|
description:
|
|
|
|
- PEM formatted certificate chain file to be used for SSL client authentication.
|
|
|
|
- Required if O(client_key) is defined.
|
|
|
|
version_added: "7.1.0"
|
|
|
|
client_key:
|
|
|
|
type: path
|
|
|
|
description:
|
|
|
|
- PEM formatted file that contains your private key to be used for SSL client authentication.
|
|
|
|
- Required if O(client_cert) is defined.
|
|
|
|
version_added: "7.1.0"
|
2020-03-09 09:11:07 +00:00
|
|
|
dn:
|
|
|
|
required: true
|
|
|
|
description:
|
|
|
|
- The DN of the entry to add or remove.
|
|
|
|
type: str
|
2021-01-27 06:56:07 +00:00
|
|
|
referrals_chasing:
|
|
|
|
choices: [disabled, anonymous]
|
|
|
|
default: anonymous
|
|
|
|
type: str
|
|
|
|
description:
|
|
|
|
- Set the referrals chasing behavior.
|
2023-06-10 07:28:40 +00:00
|
|
|
- V(anonymous) follow referrals anonymously. This is the default behavior.
|
|
|
|
- V(disabled) disable referrals chasing. This sets C(OPT_REFERRALS) to off.
|
2021-01-27 06:56:07 +00:00
|
|
|
version_added: 2.0.0
|
2020-03-09 09:11:07 +00:00
|
|
|
server_uri:
|
|
|
|
description:
|
2024-12-27 13:30:17 +00:00
|
|
|
- The O(server_uri) parameter may be a comma- or whitespace-separated list of URIs containing only the schema, the host,
|
|
|
|
and the port fields.
|
2020-03-09 09:11:07 +00:00
|
|
|
- The default value lets the underlying LDAP client library look for a UNIX domain socket in its default location.
|
2022-03-24 06:05:26 +00:00
|
|
|
- Note that when using multiple URIs you cannot determine to which URI your client gets connected.
|
|
|
|
- For URIs containing additional fields, particularly when using commas, behavior is undefined.
|
2020-03-09 09:11:07 +00:00
|
|
|
type: str
|
|
|
|
default: ldapi:///
|
|
|
|
start_tls:
|
|
|
|
description:
|
2024-12-27 13:30:17 +00:00
|
|
|
- Use the START_TLS LDAP extension if set to V(true).
|
2020-03-09 09:11:07 +00:00
|
|
|
type: bool
|
2022-08-24 17:58:42 +00:00
|
|
|
default: false
|
2020-03-09 09:11:07 +00:00
|
|
|
validate_certs:
|
|
|
|
description:
|
2023-06-10 07:28:40 +00:00
|
|
|
- If set to V(false), SSL certificates will not be validated.
|
2020-03-09 09:11:07 +00:00
|
|
|
- This should only be used on sites using self-signed certificates.
|
|
|
|
type: bool
|
2022-08-24 17:58:42 +00:00
|
|
|
default: true
|
2021-01-27 07:15:38 +00:00
|
|
|
sasl_class:
|
|
|
|
description:
|
|
|
|
- The class to use for SASL authentication.
|
|
|
|
type: str
|
|
|
|
choices: ['external', 'gssapi']
|
|
|
|
default: external
|
|
|
|
version_added: "2.0.0"
|
2023-02-27 19:26:01 +00:00
|
|
|
xorder_discovery:
|
|
|
|
description:
|
|
|
|
- Set the behavior on how to process Xordered DNs.
|
2023-06-10 07:28:40 +00:00
|
|
|
- V(enable) will perform a C(ONELEVEL) search below the superior RDN to find the matching DN.
|
|
|
|
- V(disable) will always use the DN unmodified (as passed by the O(dn) parameter).
|
|
|
|
- V(auto) will only perform a search if the first RDN does not contain an index number (C({x})).
|
2023-02-27 19:26:01 +00:00
|
|
|
type: str
|
|
|
|
choices: ['enable', 'auto', 'disable']
|
|
|
|
default: auto
|
|
|
|
version_added: "6.4.0"
|
2024-12-27 13:30:17 +00:00
|
|
|
"""
|