vSphere SDK for Perl Programming Guide - Documentation - VMware
vSphere SDK for Perl Programming Guide - Documentation - VMware
vSphere SDK for Perl Programming Guide - Documentation - VMware
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
<strong>vSphere</strong> <strong>SDK</strong> <strong>for</strong> <strong>Perl</strong> <strong>Programming</strong> <strong>Guide</strong><br />
add_password<br />
Creates a credential store file if none exists and stores the password <strong>for</strong> a given server and user name.<br />
If a password already exists <strong>for</strong> that server and user name, add_password overwrites that password.<br />
Parameters<br />
Parameter Description<br />
server Server <strong>for</strong> the new entry. Can be an ESX/ESXi or vCenter Server system.<br />
username User name <strong>for</strong> the new entry. <strong>VMware</strong> recommends that you create a user with appropriate<br />
privileges and store the corresponding user name and password in the credential store. Do not<br />
use the root or administrator user and the corresponding password.<br />
password Password <strong>for</strong> the new entry.<br />
Returns<br />
Returns 1 if a password <strong>for</strong> this server and user does not exists; otherwise, returns zero.<br />
remove_password<br />
Removes the password <strong>for</strong> a given server and user name. If no password exists, this method has no effect.<br />
Parameters<br />
Parameter Description<br />
server Server from which the password <strong>for</strong> the specified user is removed. Can be an ESX/ESXi or<br />
vCenter Server system.<br />
username User name <strong>for</strong> which the associated password is removed.<br />
Returns<br />
Returns 1 if the password existed and was successfully removed; otherwise, returns zero.<br />
clear_passwords<br />
Removes all passwords.<br />
Parameters<br />
No parameters.<br />
Returns<br />
Returns nothing.<br />
get_hosts<br />
Returns a list of all servers that have entries in the credential store.<br />
Parameters<br />
No parameters.<br />
Returns<br />
Returns a list of all servers in the credential store.<br />
64 <strong>VMware</strong>, Inc.