]> git.proxmox.com Git - pve-access-control.git/commit
api: domains: fix setting only the realm authentication password
authorChristoph Heiss <c.heiss@proxmox.com>
Thu, 20 Jul 2023 14:48:47 +0000 (16:48 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Fri, 21 Jul 2023 11:20:15 +0000 (13:20 +0200)
commit162e68903d2b715b641b994e3044d27f4af256ad
tree8870200470aaa1e9a416c1681f637a25f5f95c96
parent33e4480a778a1ed328c25baf8efb46d12b2a0146
api: domains: fix setting only the realm authentication password

Previously, if one tried to only update e.g. the bind password for an
LDAP realm, it would fail with an rather unhelpful error message:

  # pveum realm modify ldap -password foo
  update auth server failed: no options specified

The root cause was that the `password` parameter was removed early from
the parameter object, which than would fail the check whether it is
empty or not.

Thus, additionally check if only `password` was specified and if so,
allow it.

Reported-by: Friedrich Weber <f.weber@proxmox.com>
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
src/PVE/API2/Domains.pm