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.

72 lines
2.6 KiB

  1. /*---------------------------------------------------------------------------
  2. File: ARUtil.hpp
  3. Comments: Definitions for helper routines and command-line parsing for Account Replicator
  4. (c) Copyright 1995-1998, Mission Critical Software, Inc., All Rights Reserved
  5. Proprietary and confidential to Mission Critical Software, Inc.
  6. REVISION LOG ENTRY
  7. Revision By: Christy Boles
  8. Revised on 6/23/98 4:31:22 PM
  9. ---------------------------------------------------------------------------
  10. */
  11. #include "UserCopy.hpp"
  12. int
  13. CompVal(
  14. const TNode * tn, //in -tree node
  15. const void * actname //in -name to look for
  16. );
  17. int
  18. CompNode(
  19. const TNode * v1, //in -first node to compare
  20. const TNode * v2 //in -second node to compare
  21. );
  22. int
  23. CompSid(
  24. const TNode * v1, // in -first node to compare
  25. const TNode * v2 // in -second node to compare
  26. );
  27. int
  28. CompSidVal(
  29. const TNode * tn, // in -node to compare
  30. const void * pVal // in -value to compare
  31. );
  32. BOOL // ret-TRUE if the password is successfully generated
  33. PasswordGenerate(
  34. Options const * options, // in -includes PW Generating options
  35. WCHAR * password, // out -buffer for generated password
  36. DWORD dwPWBufferLength, // in -DIM length of password buffer
  37. BOOL isAdminAccount = FALSE // in -Whether to use the Admin rules
  38. );
  39. //------------------------------------------------------------------------------
  40. // ParseParms: parse out source & target servers plus any switches.
  41. //------------------------------------------------------------------------------
  42. BOOL // ret-TRUE=success
  43. ParseParms(
  44. TCHAR const ** argv ,// in -argument list
  45. Options * options // out-options
  46. );
  47. PSID
  48. GetWellKnownSid(
  49. DWORD wellKnownAccount, // in - which well known account to get sid for (constants defined in UserCopy.hpp)
  50. Options * opt, // in - options structure containing source and target domains
  51. BOOL bTarget = FALSE // in - flag, whether to use source or target domain information
  52. );
  53. // GenerateSidAsString
  54. // generates string SID after using GetWellKnownSid to generate SID
  55. _bstr_t __stdcall GenerateSidAsString(Options* pOptions, BOOL bTarget, DWORD dwRid);