Ejemplos

POST /api/auth_source_ldaps
{
  "auth_source_ldap": {
    "name": "ldap2",
    "host": "ldap2",
    "server_type": "posix"
  }
}
201
{
  "host": "ldap2",
  "port": 389,
  "account": null,
  "base_dn": null,
  "ldap_filter": null,
  "attr_login": null,
  "attr_firstname": null,
  "attr_lastname": null,
  "attr_mail": null,
  "attr_photo": null,
  "onthefly_register": false,
  "usergroup_sync": true,
  "tls": false,
  "server_type": "posix",
  "groups_base": null,
  "use_netgroups": false,
  "created_at": "2019-11-07 08:51:15 UTC",
  "updated_at": "2019-11-07 08:51:15 UTC",
  "id": 980190964,
  "type": "AuthSourceLdap",
  "name": "ldap2",
  "external_usergroups": [],
  "locations": [],
  "organizations": []
}

Parámetros

Nombre del parámetro Descripción
location_id
opcional

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
opcional

Set the current organization context for the request

Validations:

  • Must be a Integer

auth_source_ldap
requerido

Validations:

  • Must be a Hash

auth_source_ldap[name]
requerido

Validations:

  • Must be a String

auth_source_ldap[host]
requerido

Validations:

  • Must be a String

auth_source_ldap[port]
opcional , nil permitido

se predetermina a 389

Validations:

  • Must be a number.

auth_source_ldap[account]
opcional , nil permitido

Validations:

  • Must be a String

auth_source_ldap[base_dn]
opcional , nil permitido

Validations:

  • Must be a String

auth_source_ldap[account_password]
opcional , nil permitido

obligatorio si onthefly_register es verdadero

Validations:

  • Must be a String

auth_source_ldap[attr_login]
opcional , nil permitido

obligatorio si onthefly_register es verdadero

Validations:

  • Must be a String

auth_source_ldap[attr_firstname]
opcional , nil permitido

obligatorio si onthefly_register es verdadero

Validations:

  • Must be a String

auth_source_ldap[attr_lastname]
opcional , nil permitido

obligatorio si onthefly_register es verdadero

Validations:

  • Must be a String

auth_source_ldap[attr_mail]
opcional , nil permitido

obligatorio si onthefly_register es verdadero

Validations:

  • Must be a String

auth_source_ldap[attr_photo]
opcional , nil permitido

Validations:

  • Must be a String

auth_source_ldap[onthefly_register]
opcional , nil permitido

Validations:

  • Must be one of: true, false, 1, 0.

auth_source_ldap[usergroup_sync]
opcional , nil permitido

sincronizar los grupos de usuarios externos durante el inicio de sesión

Validations:

  • Must be one of: true, false, 1, 0.

auth_source_ldap[tls]
opcional , nil permitido

Validations:

  • Must be one of: true, false, 1, 0.

auth_source_ldap[groups_base]
opcional , nil permitido

DN base para grupos

Validations:

  • Must be a String

auth_source_ldap[use_netgroups]
opcional , nil permitido

utilice NIS netgroups en lugar de grupos posix, aplicable únicamente cuando el tipo de servidor es posix o free_ipa

Validations:

  • Must be one of: true, false, 1, 0.

auth_source_ldap[server_type]
opcional , nil permitido

tipo de servidor LDAP

Validations:

  • Must be one of: free_ipa, active_directory, posix.

auth_source_ldap[ldap_filter]
opcional , nil permitido

Filtro LDAP

Validations:

  • Must be a String

auth_source_ldap[location_ids]
opcional , nil permitido

REMPLAZAR ubicaciones con ID dadas

Validations:

  • Must be an array of any type

auth_source_ldap[organization_ids]
opcional , nil permitido

REMPLAZAR organizaciones con ID dadas.

Validations:

  • Must be an array of any type