bigip_device_auth_ldap – Manage LDAP device authentication settings on BIG-IP — Ansible Documentation

- AnsibleFest
- Products
- Community
- Webinars & Training
- Blog

Documentation

# bigip_device_auth_ldap – Manage LDAP device authentication settings on BIG-IP

New in version 2.8.

- Synopsis
- Parameters
- Notes
- Examples
- Return Values
- Status

## Synopsis

- Manage LDAP device authentication settings on BIG-IP.

## Parameters

Parameter | Choices/Defaults | Comments
--- | --- | ---
bind_dn string |  | Specifies the distinguished name for the Active Directory or LDAP server user ID. The BIG-IP client authentication module does not support Active Directory or LDAP servers that do not perform bind referral when authenticating referred accounts. Therefore, if you plan to use Active Directory or LDAP as your authentication source and want to use referred accounts, make sure your servers perform bind referral.
bind_password string |  | Specifies a password for the Active Directory or LDAP server user ID.
ca_cert string |  | Specifies the name of an SSL certificate from a certificate authority (CA). To remove this value, use the reserved value `none`. aliases: ssl_ca_cert
check_member_attr boolean | Choices: no yes | Checks the user's member attribute in the remote LDAP or AD group.
client_cert string |  | Specifies the name of an SSL client certificate. To remove this value, use the reserved value `none`. aliases: ssl_client_cert
client_key string |  | Specifies the name of an SSL client key. To remove this value, use the reserved value `none`. aliases: ssl_client_key
fallback_to_local boolean | Choices: no yes | Specifies that the system uses the Local authentication method if the remote authentication method is not available.
login_ldap_attr string |  | Specifies the LDAP directory attribute containing the local user name that is associated with the selected directory entry. When configuring LDAP device authentication for the first time, if this parameter is not specified, the default port is `samaccountname`.
password string / required |  | The password for the user account used to connect to the BIG-IP. You may omit this option by setting the environment variable `F5_PASSWORD`. aliases: pass, pwd
port integer |  | Specifies the port that the system uses for access to the remote host server. When configuring LDAP device authentication for the first time, if this parameter is not specified, the default port is `389`.
provider dictionary added in 2.5 |  | A dict object containing connection details.
| password string / required |  | The password for the user account used to connect to the BIG-IP. You may omit this option by setting the environment variable `F5_PASSWORD`. aliases: pass, pwd
| server string / required |  | The BIG-IP host. You may omit this option by setting the environment variable `F5_SERVER`.
| server_port integer | Default: 443 | The BIG-IP server port. You may omit this option by setting the environment variable `F5_SERVER_PORT`.
| ssh_keyfile path |  | Specifies the SSH keyfile to use to authenticate the connection to the remote device. This argument is only used for cli transports. You may omit this option by setting the environment variable `ANSIBLE_NET_SSH_KEYFILE`.
| timeout integer | Default: 10 | Specifies the timeout in seconds for communicating with the network device for either connecting or sending commands. If the timeout is exceeded before the operation is completed, the module will error.
| transport string | Choices: cli rest ← | Configures the transport connection to use when connecting to the remote device.
| user string / required |  | The username to connect to the BIG-IP with. This user must have administrative privileges on the device. You may omit this option by setting the environment variable `F5_USER`.
| validate_certs boolean | Choices: no yes ← | If `no`, SSL certificates are not validated. Use this only on personally controlled sites using self-signed certificates. You may omit this option by setting the environment variable `F5_VALIDATE_CERTS`.
remote_directory_tree string |  | Specifies the file location (tree) of the user authentication database on the server.
scope string | Choices: sub one base | Specifies the level of the remote Active Directory or LDAP directory that the system should search for the user authentication.
server string / required |  | The BIG-IP host. You may omit this option by setting the environment variable `F5_SERVER`.
server_port integer added in 2.2 | Default: 443 | The BIG-IP server port. You may omit this option by setting the environment variable `F5_SERVER_PORT`.
servers list |  | Specifies the LDAP servers that the system must use to obtain authentication information. You must specify a server when you create an LDAP configuration object.
ssl string | Choices: yes no start-tls | Specifies whether the system uses an SSL port to communicate with the LDAP server.
state string | Choices: present ← absent | When `present`, ensures the device authentication method exists. When `absent`, ensures the device authentication method does not exist.
update_password string | Choices: always ← on_create | `always` will always update the `bind_password`. `on_create` will only set the `bind_password` for newly created authentication mechanisms.
user string / required |  | The username to connect to the BIG-IP with. This user must have administrative privileges on the device. You may omit this option by setting the environment variable `F5_USER`.
user_template string |  | Specifies the distinguished name of the user who is logging on. You specify the template as a variable that the system replaces with user-specific information during the logon attempt. For example, you could specify a user template such as `%s@siterequest.com` or `uxml:id=%s,ou=people,dc=siterequest,dc=com`. When a user attempts to log on, the system replaces `%s` with the name the user specified in the Basic Authentication dialog box, and passes that as the distinguished name for the bind operation. The system passes the associated password as the password for the bind operation. This field can contain only one `%s` and cannot contain any other format specifiers.
validate_certs boolean added in 2.0 | Choices: no yes ← | Specifies whether the system checks an SSL peer, as a result of which the system requires and verifies the server certificate. aliases: ssl_check_peer

## Notes

Note

- For more information on using Ansible to manage F5 Networks devices see https://www.ansible.com/integrations/networks/f5.
- Requires BIG-IP software version >= 12.
- The F5 modules only manipulate the running configuration of the F5 product. To ensure that BIG-IP specific configuration persists to disk, be sure to include at least one task that uses the bigip_config module to save the running configuration. Refer to the module’s documentation for the correct usage of the module to save your running configuration.

## Examples

    - name: Create an LDAP authentication object
      bigip_device_auth_ldap:
        name: foo
        provider:
          password: secret
          server: lb.mydomain.com
          user: admin
      delegate_to: localhost

## Return Values

Common return values are documented here, the following are the fields unique to this module:

Key | Returned | Description
--- | --- | ---
bind_dn string | changed | The distinguished name for the Active Directory or LDAP server user ID. Sample: user@foobar.local
ca_cert string | changed | The name of an SSL certificate from a certificate authority. Sample: My-Trusted-CA-Bundle.crt
check_member_attr boolean | changed | The user's member attribute in the remote LDAP or AD group. Sample: True
client_cert string | changed | The name of an SSL client certificate. Sample: MyCert.crt
client_key string | changed | The name of an SSL client key. Sample: MyKey.key
fallback_to_local boolean | changed | Specifies that the system uses the Local authentication method as fallback Sample: True
login_ldap_attr string | changed | The LDAP directory attribute containing the local user name associated with the selected directory entry. Sample: samaccountname
port integer | changed | The port that the system uses for access to the remote LDAP server. Sample: 389
remote_directory_tree string | changed | File location (tree) of the user authentication database on the server. Sample: CN=Users,DC=FOOBAR,DC=LOCAL
scope string | changed | The level of the remote Active Directory or LDAP directory searched for user authentication. Sample: base
servers list | changed | LDAP servers used by the system to obtain authentication information. Sample: ['192.168.1.1', '192.168.1.2']
ssl string | changed | Specifies whether the system uses an SSL port to communicate with the LDAP server. Sample: start-tls
user_template string | changed | The distinguished name of the user who is logging on. Sample: uid=%s,ou=people,dc=foobar,dc=local
validate_certs boolean | changed | Indicates if the system checks an SSL peer. Sample: True

## Status

- This module is not guaranteed to have a backwards compatible interface. [preview]
- This module is maintained by an Ansible Partner. [certified]

### Authors

- Tim Rupp (@caphrim007)
- Wojciech Wypior (@wojtek0806)

Hint

If you notice any issues in this documentation you can edit this document to improve it.