Loading |
VBScript |
JavaScript |
Powershell |
Search Options: List Trust RelationshipsContent of List Trust Relationships.vbsMD5 Hash: EFAE362B94D3E28F93E2BA0F81FCB44E |
||
' Description: Enumerates trust relationships.
strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & _ strComputer & "\root\MicrosoftActiveDirectory") Set colTrustList = objWMIService.ExecQuery _ ("Select * from Microsoft_DomainTrustStatus") For each objTrust in colTrustList Wscript.Echo "Trusted domain: " & objTrust.TrustedDomain Wscript.Echo "Trust direction: " & objTrust.TrustDirection Wscript.Echo "Trust type: " & objTrust.TrustType Wscript.Echo "Trust attributes: " & objTrust.TrustAttributes Wscript.Echo "Trusted domain controller name: " & objTrust.TrustedDCName Wscript.Echo "Trust status: " & objTrust.TrustStatus Wscript.Echo "Trust is OK: " & objTrust.TrustIsOK Next | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |