 15f7be9a52
			
		
	
	15f7be9a52
	
	
	
		
			
			This external documentation for pyVmomi was generated using Googly Docs (aka Google Standard Documentation) which renders very cleanly in GitHub. Internal documentation for a class should be done in Sphinx format because tools like pyCharm and Eclipse can use that documentation as a hint for code completion. Note: External docs as Googly Docs, internal docs as Sphinx. Closes bug#15
		
			
				
	
	
	
		
			7.3 KiB
		
	
	
	
	
	
	
	
			
		
		
	
	vim.host.ActiveDirectoryAuthentication
The HostActiveDirectoryAuthentication managed object indicates domain membership status and provides methods for adding a host to and removing a host from a domain.
- extends
- since
Attributes
Methods
- JoinDomain(domainName, userName, password):
- 
Adds the host to an Active Directory domain.If the HostAuthenticationStoreInfo . enabled property isTrue(accessed through theinfoproperty), the host has joined a domain. The vSphere API will throw theInvalidStatefault if you try to add a host to a domain when the host has already joined a domain. - Privilege:
- 
Host.Config.AuthenticationStore 
- Args:
- Returns:
 Raises: - vim.fault.InvalidState:
- 
if the host has already joined a domain. 
- vim.fault.HostConfigFault:
- 
if the host configuration prevents the join operation from succeeding. 
- vim.fault.InvalidLogin:
- 
ifuserNameandpasswordare not valid user credentials. 
- vim.fault.ActiveDirectoryFault:
- 
for any problem that is not handled with a more specific fault. 
- vim.fault.TaskInProgress:
- 
if the HostActiveDirectoryAuthentication object is busy. 
- vim.fault.BlockedByFirewall:
- 
if ports needed by the join operation are blocked by the firewall. 
- vim.fault.DomainNotFound:
- 
if the domain controller fordomainNamecannot be reached. 
- vim.fault.NoPermissionOnAD:
- 
ifuserNamehas no right to add hosts to the domain. 
- vim.fault.InvalidHostName:
- 
if the domain part of the host's FQDN doesn't match the domain being joined. 
- vim.fault.ClockSkew:
- 
if the clocks of the host and the domain controller differ by more than the allowed amount of time. 
 
- JoinDomainWithCAM(domainName, camServer):
- 
Adds the host to an Active Directory domain through CAM service.If the HostAuthenticationStoreInfo . enabled property isTrue(accessed through theinfoproperty), the host has joined a domain. The vSphere API will throw theInvalidStatefault if you try to add a host to a domain when the host has already joined a domain. since: vSphere API 5.0 - Privilege:
- 
Host.Config.AuthenticationStore 
- Args:
- Returns:
 Raises: - vim.fault.InvalidState:
- 
if the host has already joined a domain. 
- vim.fault.HostConfigFault:
- 
if the host configuration prevents the join operation from succeeding. 
- vim.fault.ActiveDirectoryFault:
- 
for any problem that is not handled with a more specific fault. 
- vim.fault.TaskInProgress:
- 
if the HostActiveDirectoryAuthentication object is busy. 
- vim.fault.BlockedByFirewall:
- 
if ports needed by the join operation are blocked by the firewall. 
- vim.fault.DomainNotFound:
- 
if the domain controller fordomainNamecannot be reached. 
- vim.fault.InvalidHostName:
- 
if the domain part of the host's FQDN doesn't match the domain being joined. 
- vim.fault.ClockSkew:
- 
if the clocks of the host and the domain controller differ by more than the allowed amount of time. 
- vim.fault.InvalidCAMServer:
- 
if camServer is not a valid IP address, or if camServer is not accessible. 
- vim.fault.InvalidCAMCertificate:
- 
if the certificate of the given CAM server cannot be verified. 
- vim.fault.CAMServerRefusedConnection:
- 
if the specified CAM server is not reachable, or if the server denied access. 
 
- ImportCertificateForCAM(certPath, camServer):
- 
Import the CAM server's certificate to the local store of vmwauth.The certificate should have already been uploaded to ESXi file system. since: vSphere API 5.0 - Privilege:
- 
Host.Config.AuthenticationStore 
- Args:
- Returns:
 Raises: - vim.fault.FileNotFound:
- 
if the certificate file does not exist 
- vim.fault.ActiveDirectoryFault:
- 
for any problem that is not handled with a more specific fault. 
- vim.fault.InvalidCAMServer:
- 
if camServer is not a valid IP address 
 
- LeaveCurrentDomain(force):
- 
Removes the host from the Active Directory domain to which it belongs. - Privilege:
- 
Host.Config.AuthenticationStore 
- Args:
- 
- force (bool):
- 
IfTrue, any existing permissions on managed entities for Active Directory users will be deleted. IfFalseand such permissions exist, the operation will fail. 
 
- Returns:
 Raises: - vim.fault.InvalidState:
- 
if the host is not in a domain or there are active permissions for Active Directory users. 
- vim.fault.AuthMinimumAdminPermission:
- 
if this change would leave the system with no Administrator permission on the root node. 
- vim.fault.ActiveDirectoryFault:
- 
for any problem that is not handled with a specific fault. 
- vim.fault.TaskInProgress:
- 
if the ActiveDirectoryAuthentication object is busy. 
- vim.fault.NonADUserRequired:
- 
only non Active Directory users can initiate the leave domain operation.