summaryrefslogtreecommitdiff
path: root/perl/lib/Wallet/Kadmin/AD.pm
diff options
context:
space:
mode:
authorBill MacAllister <whm@dropbox.com>2016-05-06 19:40:17 +0000
committerRuss Allbery <eagle@eyrie.org>2018-05-27 17:33:31 -0700
commitf98ba772f9453f39b8b7c02f896dd3725d1c7d8b (patch)
treea2b345b69ecb15813d12d1079ee592f8ab23a19c /perl/lib/Wallet/Kadmin/AD.pm
parent8bfba28196485236125ad363ed3b96c461025d94 (diff)
Correction to AD handling of long service keytab IDs
The account name for a service keytab cannot exceed 20 characters. The routine that was generating a unique id incorrectly attempted to perform an LDAP query. This change fixes that problem.
Diffstat (limited to 'perl/lib/Wallet/Kadmin/AD.pm')
-rw-r--r--perl/lib/Wallet/Kadmin/AD.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perl/lib/Wallet/Kadmin/AD.pm b/perl/lib/Wallet/Kadmin/AD.pm
index 83912dd..2d93b32 100644
--- a/perl/lib/Wallet/Kadmin/AD.pm
+++ b/perl/lib/Wallet/Kadmin/AD.pm
@@ -280,8 +280,8 @@ sub get_service_id {
my $this_prefix = substr($this_cn, 0, 20-$suffix_size);
my $this_format = "%0${suffix_size}i";
while ($cnt<$loop_limit) {
- my $this_cn = $this_prefix . sprintf($this_format, $cnt);
- $this_dn = ldap_get_dn($this_base, "cn=$this_cn");
+ $this_cn = $this_prefix . sprintf($this_format, $cnt);
+ $this_dn = $self->ldap_get_dn($this_base, "cn=$this_cn");
if (!$this_dn) {
$this_id = $this_cn;
last;