AnsweredAssumed Answered

R12.5 -$session->GetAllAdmins()-Not returning admin if they stored external

Question asked by sheik.ali on Mar 25, 2013
Latest reply on Mar 27, 2013 by Chris_Hackett
The below perl program is supposed to list all the administrators(administrator rom external sources (AD, LDS etc) and Legacy administrators) from R12x environment. The below program returns the legacy administrators perfectly, when it comes to the administrator who are from external sources it returns some junk values like below mentioned.

siteminder -----Looks Good and it is legacy admin
SMWAMUI:ei1096vwin.fmr.com__0 -------Not looks good as this is administrator is from external resource
SMWAMUI:ei1100vwin__0 -------Not looks good as this is administrator is from external resource
hostreg -----Looks Good and it is legacy admin
SMWAMUI:ei1100vwin __0 -------Not looks good as this is administrator is from external resource
CA.XPS::Administrator@1ab5b473-909f-4fa5-b97b-c89c6d1f0959 -------Not looks good as this is administrator is from external resource
SMWAMUI:ei1096vwin__0 -------Not looks good as this is administrator is from external resource


Is there a way to get this working at R12.5 environment, returning all administrators list irrespective of legacy admi / admin from external resources.

----------------------------------------------
use Netegrity::PolicyMgtAPI;
use Net::FTP;

# SiteMinder admin user
$adminuser = "siteminder";
$adminpassword = "*******";
$filedir = "D:\\SM-Cust-QA-Config\\";
# Miscellaneous arrays

logintoPS($adminuser,$adminpassword);

sub logintoPS
{
$policymgtapi = Netegrity::PolicyMgtAPI->New();
$session = $policymgtapi->CreateSession($adminuser, $adminpassword);
die "\nFATAL: Cannot create session. Please check admin credentials\n"
unless ($session != undef);


$policymgtapi->PreLoadCache(1);
$policymgtapi->LoadAgentTypeDictionary(1);
print "successfully logged onto PS console"."\n";

@admins = $session->GetAllAdmins();
foreach $admin(@admins)
{

print $admin->Name()."\n";

print $admin->Password()."\n";



}
}

Outcomes