f5networks.f5_modules.bigip_device_auth_ldap – Manage LDAP device authentication settings on BIG-IP

Note

This plugin is part of the f5networks.f5_modules collection (version 1.9.0).

To install it use: ansible-galaxy collection install f5networks.f5_modules.

To use it in a playbook, specify: f5networks.f5_modules.bigip_device_auth_ldap.

New in version 1.0.0: of f5networks.f5_modules

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 member attribute of the user 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 the system uses the Local authentication method if the remote authentication method is not available.
Option only available on TMOS 13.0.0 and above.
login_ldap_attr
string
Specifies the LDAP directory attribute containing the local user name that is associated with the selected directory entry.
If this parameter is not specified, when configuring LDAP device authentication for the first time, the default port is samaccountname.
port
integer
Specifies the port the system uses for access to the remote host server.
When configuring LDAP device authentication for the first time, the default port is 389 if this parameter is not specified.
provider
dictionary
added in 1.0.0 of f5networks.f5_modules
A dict object containing connection details.
auth_provider
string
Configures the auth provider for to obtain authentication tokens from the remote device.
This option is really used when working with BIG-IQ devices.
no_f5_teem
boolean
    Choices:
  • no
  • yes
If yes, TEEM telemetry data is not sent to F5.
You may omit this option by setting the environment variable F5_TEEM.
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.
timeout
integer
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:
  • 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 the system should search for the user authentication.
servers
list / elements=string
Specifies the LDAP servers 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.
When state equal to (absent), before you can delete the LDAP configuration, the system must set auth to some alternative. The system ships with a system auth called local, therefore the system authentication type will be set to that value on the device upon removal of LDAP configuration.
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.
use_for_auth
boolean
    Choices:
  • no
  • yes
Specifies whether or not this auth source is put in use on the system.
If yes, the module sets the current system auth type to the value of ldap.
If no, the module sets the authentication type to local, similar behavior to when state is absent, without removing the configured LDAP resource.
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 %[email protected] 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
    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 f5networks.f5_modules.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:
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 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 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 / elements=string
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


Authors

  • Tim Rupp (@caphrim007)

  • Wojciech Wypior (@wojtek0806)