home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / sdk / sdktools / winnt / cacls / account.hxx < prev    next >
Text File  |  1995-03-13  |  1KB  |  57 lines

  1. //+-------------------------------------------------------------------
  2. //
  3. // Copyright (C) 1995, Microsoft Corporation.
  4. //
  5. //  File:        account.hxx
  6. //
  7. //  Contents:    class encapsulating NT security user account.
  8. //
  9. //  Classes:     CAccount
  10. //
  11. //  History:     Nov-93        Created         DaveMont
  12. //
  13. //--------------------------------------------------------------------
  14. #ifndef __ACCOUNT__
  15. #define __ACCOUNT__
  16.  
  17. #include <t2.hxx>
  18.  
  19. //+-------------------------------------------------------------------
  20. //
  21. //  Class:      CAccount
  22. //
  23. //  Purpose:    encapsulation of NT Account, this class actually interfaces
  24. //              with the NT security authority to get SIDs for usernames and
  25. //              vis-versa.
  26. //
  27. //--------------------------------------------------------------------
  28. class CAccount
  29. {
  30. public:
  31.  
  32.     CAccount(WCHAR *Name, WCHAR *System);
  33.     CAccount(SID *pSid, WCHAR *System);
  34.  
  35.    ~CAccount();
  36.  
  37.     ULONG GetAccountSid(SID **psid);
  38.     ULONG GetAccountName(WCHAR **name);
  39.     ULONG GetAccountDomain(WCHAR **domain);
  40.  
  41.  
  42. private:
  43.  
  44.     BOOL        _fsid        ;
  45.     SID        *_psid        ;
  46.     WCHAR      *_system      ;
  47.     WCHAR      *_name        ;
  48.     WCHAR      *_domain      ;
  49. };
  50.  
  51. #endif // __ACCOUNT__
  52.  
  53.  
  54.  
  55.  
  56.  
  57.