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.

61 lines
1.5 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 2000-2002.
  5. //
  6. // File: PolicyOID.h
  7. //
  8. // Contents: CPolicyOID
  9. //
  10. //----------------------------------------------------------------------------
  11. #ifndef __POLICYOID_H_INCLUDED__
  12. #define __POLICYOID_H_INCLUDED__
  13. class CPolicyOID {
  14. public:
  15. void SetDisplayName (const CString& szDisplayName);
  16. bool IsApplicationOID () const;
  17. bool IsIssuanceOID () const;
  18. CPolicyOID (const CString& szOID, const CString& szDisplayName,
  19. ADS_INTEGER flags, bool bCanRename = true);
  20. virtual ~CPolicyOID ();
  21. CString GetOIDW () const
  22. {
  23. return m_szOIDW;
  24. }
  25. PCSTR GetOIDA () const
  26. {
  27. if ( m_pszOIDA )
  28. return m_pszOIDA;
  29. else
  30. return "";
  31. }
  32. CString GetDisplayName () const
  33. {
  34. return m_szDisplayName;
  35. }
  36. bool CanRename () const
  37. {
  38. return m_bCanRename;
  39. }
  40. private:
  41. const ADS_INTEGER m_flags;
  42. CString m_szOIDW;
  43. CString m_szDisplayName;
  44. PSTR m_pszOIDA;
  45. const bool m_bCanRename;
  46. };
  47. typedef CTypedPtrList<CPtrList, CPolicyOID*> POLICY_OID_LIST;
  48. // NTRAID #572262 Certtmpl: Limit OID input UI to allow ( 20 elements * 2^28 )
  49. // == 200 characters + 19 dots for a total of 219 characters
  50. #define MAX_OID_LEN 219
  51. #endif // __POLICYOID_H_INCLUDED__