Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

42 lines
1.4 KiB

  1. On Error Resume Next
  2. Set t_Service = GetObject ("winmgmts:\root\default")
  3. Set t_Class = t_Service.Get ("__CIMOMIDentification")
  4. WScript.Echo t_Class.Path_.Path
  5. Set t_Class = GetObject ("winmgmts:root/cimv2:win32_logicaldisk")
  6. WScript.Echo t_Class.Path_.Path
  7. Set t_Instance = GetObject ("winmgmts:{impersonationLevel=impersonate}!root/cimv2:win32_logicaldisk=""C:""")
  8. WScript.Echo t_Instance.Path_.Path
  9. Set t_Class = GetObject ("winmgmts:win32_logicaldisk")
  10. WScript.Echo t_Class.Path_.Path
  11. Set t_Instance = GetObject ("winmgmts:{impersonationLevel=impersonate}!win32_logicaldisk=""C:""")
  12. WScript.Echo t_Instance.Path_.Path
  13. Set t_Instance = GetObject ("wmi:{impersonationLevel=impersonate}!win32_logicaldisk=""C:""")
  14. WScript.Echo t_Instance.Path_.Path
  15. Set t_Instance = GetObject ("umi:{impersonationLevel=impersonate}!win32_logicaldisk=""C:""")
  16. WScript.Echo t_Instance.Path_.Path
  17. Set t_Instance = GetObject ("umi:///ldap/.cn=com/.cn=microsoft/.ou=sales")
  18. WScript.Echo t_Instance.Path_.Path
  19. Set t_Instance = GetObject ("umi:///winnt/joe,User")
  20. WScript.Echo t_Instance.Path_.Path
  21. Set t_Instance = GetObject ("umildap://cn=Joe,ou=Users")
  22. WScript.Echo t_Instance.Path_.Path
  23. Set t_Instance = GetObject ("umiwinnt://joe,User")
  24. WScript.Echo t_Instance.Path_.Path
  25. if Err <> 0 Then
  26. WScript.Echo Err.Number, Err.Description
  27. Err.Clear
  28. End If