Source code of Windows XP (NT5)
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.

75 lines
2.1 KiB

  1. /////////////////////////////////////////////////////////////////////////////
  2. //
  3. // Copyright(C) 1999-2000 Microsoft Corporation all rights reserved.
  4. //
  5. // Module: utils.cpp
  6. //
  7. // Project: Windows 2000 IAS
  8. //
  9. // Description: IAS 4 to Windows 2000 Migration Utility Functions
  10. //
  11. // Used mostly by the NT4 migration code
  12. //
  13. // Author: TLP 1/13/1999
  14. //
  15. //
  16. // Revision 02/24/2000 Moved to a separate dll
  17. //
  18. /////////////////////////////////////////////////////////////////////////////
  19. #ifndef _UTILS_H_643D9D3E_AD27_4c9e_8ECC_CCB7B8A1AC19
  20. #define _UTILS_H_643D9D3E_AD27_4c9e_8ECC_CCB7B8A1AC19
  21. #if _MSC_VER > 1000
  22. #pragma once
  23. #endif // _MSC_VER > 1000
  24. #include "nocopy.h"
  25. class CUtils : private NonCopyable
  26. {
  27. protected:
  28. CUtils();
  29. public:
  30. static CUtils& Instance();
  31. LONG GetAuthSrvDirectory(/*[in]*/ _bstr_t& pszDir) const;
  32. LONG GetIAS2Directory( /*[in]*/ _bstr_t& pszDir) const;
  33. void DeleteOldIASFiles();
  34. BOOL IsWhistler() const throw();
  35. BOOL IsNT4Isp() const throw();
  36. BOOL IsNT4Corp() const throw();
  37. BOOL OverrideUserNameSet() const throw();
  38. BOOL UserIdentityAttributeSet() const throw();
  39. void NewGetAuthSrvParameter(
  40. /*[in]*/ LPCWSTR szParameterName,
  41. /*[out]*/ DWORD& DwordValue
  42. ) const;
  43. DWORD GetUserIdentityAttribute() const throw();
  44. static const WCHAR AUTHSRV_PARAMETERS_KEY[];
  45. static const WCHAR SERVICES_KEY[];
  46. private:
  47. static CUtils _instance;
  48. void GetVersion();
  49. void GetRealmParameters() throw();
  50. static const WCHAR IAS_KEY[];
  51. static const WCHAR* m_FilesToDelete[];
  52. static const int m_NbFilesToDelete;
  53. BOOL m_IsNT4ISP;
  54. BOOL m_IsNT4CORP;
  55. BOOL m_OverrideUserNameSet;
  56. BOOL m_UserIdentityAttributeSet;
  57. DWORD m_UserIdentityAttribute;
  58. };
  59. #endif // _UTILS_H_643D9D3E_AD27_4c9e_8ECC_CCB7B8A1AC19