Commit ca9c56c0 authored by Mike Hibler's avatar Mike Hibler

Backward-compatible behavior was not.

We appear to need to specify a user_id even when using a key.
In part, this is to satisfy the check in ipmiexec, but even if we fix
that code and don't pass the user to ipmitool (-U), ipmitool will prompt
for a password.
parent c500ebf6
#!/usr/bin/perl -wT #!/usr/bin/perl -wT
# #
# Copyright (c) 2008-2014 University of Utah and the Flux Group. # Copyright (c) 2008-2015 University of Utah and the Flux Group.
# #
# {{{EMULAB-LICENSE # {{{EMULAB-LICENSE
# #
...@@ -124,6 +124,14 @@ sub iloctrl($$@) { ...@@ -124,6 +124,14 @@ sub iloctrl($$@) {
} }
} }
elsif ($krole eq "ipmi-kgkey") { elsif ($krole eq "ipmi-kgkey") {
#
# XXX looks like we always need a user ID.
# Not just for the check in ipmiexec, but for ipmitool too.
# ipmitool seems to want both uid/password in addition to key,
# otherwise it prompts for a password.
#
$kuid = $row->{'key_uid'};
($kgkey = $row->{'mykey'}) =~ s/^0x//; ($kgkey = $row->{'mykey'}) =~ s/^0x//;
# NOTE: key_privlvl is currently ignored in case this is the # NOTE: key_privlvl is currently ignored in case this is the
# only authentication mechanism being used. # only authentication mechanism being used.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment