the fix for bug 3364300 - not display passwords in xcat commands or logs.

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@12311 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
sjing 2012-04-24 01:47:48 +00:00
parent f84a114049
commit 66b2bcfce0

View File

@ -172,9 +172,17 @@ sub fsp_api_action {
#print "cmd: $cmd\n";
$SIG{CHLD} = 'DEFAULT';
# secure passwords in verbose mode
my $tmpv = $::VERBOSE;
if($action =~ /^add_connection$/)
{
# password involved
$::VERBOSE = 0;
}
$res = xCAT::Utils->runcmd($cmd, -1);
#$res = "good";
$Rc = $::RUNCMD_RC;
$::VERBOSE = $tmpv;
##################
# output the prompt