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.

127 lines
3.3 KiB

  1. //=============================================================================
  2. // Copyright (c) 2000 Microsoft Corporation
  3. //
  4. // precomp.hpp
  5. //
  6. // Created 02/29/2000 johnstep (John Stephens)
  7. //=============================================================================
  8. #define UNICODE
  9. #include <nt.h>
  10. #include <ntrtl.h>
  11. #include <nturtl.h>
  12. #include <windows.h>
  13. #include <stdio.h>
  14. #include <malloc.h>
  15. extern "C" {
  16. #include <commctrl.h>
  17. }
  18. #define _CREDUI_
  19. #include <wincrui.h>
  20. #ifndef SECURITY_WIN32
  21. #define SECURITY_WIN32
  22. #endif
  23. #include <security.h>
  24. #include <controls.hpp>
  25. #include "utils.hpp"
  26. #include <netlib.h>
  27. #include <shfusion.h>
  28. #include <strsafe.h>
  29. #if defined(DBG)
  30. #if defined(CREDUIPRINTF)
  31. #define CreduiDebugLog printf
  32. #else
  33. #define CreduiDebugLog DbgPrint
  34. #endif
  35. #else
  36. #define CreduiDebugLog
  37. #endif
  38. //-----------------------------------------------------------------------------
  39. // Types
  40. //-----------------------------------------------------------------------------
  41. struct CREDUI_STRINGS
  42. {
  43. WCHAR UserNameTipTitle[32];
  44. WCHAR UserNameTipText[256];
  45. WCHAR PasswordTipTitle[32];
  46. WCHAR PasswordTipText[256];
  47. WCHAR CapsLockTipTitle[32];
  48. WCHAR CapsLockTipText[256];
  49. WCHAR LogonTipTitle[32];
  50. WCHAR LogonTipText[256];
  51. WCHAR LogonTipCaps[256];
  52. WCHAR DnsCaption[64];
  53. WCHAR NetbiosCaption[64];
  54. WCHAR GenericCaption[64];
  55. WCHAR Welcome[64];
  56. WCHAR WelcomeBack[64];
  57. WCHAR Connecting[64];
  58. WCHAR PasswordStatic[32];
  59. WCHAR PinStatic[32];
  60. WCHAR UserNameStatic[32];
  61. WCHAR CertificateStatic[32];
  62. WCHAR Certificate[32];
  63. WCHAR LookupName[64];
  64. WCHAR EmptyReader[64];
  65. WCHAR NoCard[32];
  66. WCHAR UnknownCard[64];
  67. WCHAR BackwardsCard[64];
  68. WCHAR EmptyCard[64];
  69. WCHAR ReadingCard[64];
  70. WCHAR CardError[64];
  71. WCHAR BackwardsTipTitle[32];
  72. WCHAR BackwardsTipText[128];
  73. WCHAR SmartCardStatic[32];
  74. WCHAR WrongOldTipTitle[32];
  75. WCHAR WrongOldTipText[256];
  76. WCHAR NotSameTipTitle[32];
  77. WCHAR NotSameTipText[256];
  78. WCHAR TooShortTipTitle[32];
  79. WCHAR TooShortTipText[256];
  80. WCHAR Save[64];
  81. WCHAR PromptForUse[256];
  82. WCHAR NoUsernameEntered[256];
  83. WCHAR PassportSave[64];
  84. WCHAR EmailName[64];
  85. WCHAR DowngradeTipText[256];
  86. WCHAR EmailNameTipTitle[64];
  87. WCHAR EmailNameTipText[256];
  88. };
  89. // Private window message:
  90. enum
  91. {
  92. CREDUI_WM_APP_LOOKUP_COMPLETE = WM_APP + 0,
  93. CREDUI_WM_APP_VIEW_COMPLETE = WM_APP + 1
  94. };
  95. //-----------------------------------------------------------------------------
  96. // Global Variables
  97. //-----------------------------------------------------------------------------
  98. extern HMODULE CreduiInstance;
  99. extern ULONG CreduiComReferenceCount;
  100. extern BOOL CreduiIsPersonal;
  101. extern BOOL CreduiIsDomainController;
  102. extern BOOL CreduiIsSafeMode;
  103. extern CREDUI_STRINGS CreduiStrings;
  104. extern UINT CreduiScarduiWmReaderArrival;
  105. extern UINT CreduiScarduiWmReaderRemoval;
  106. extern UINT CreduiScarduiWmCardInsertion;
  107. extern UINT CreduiScarduiWmCardRemoval;
  108. extern UINT CreduiScarduiWmCardCertAvail;
  109. extern UINT CreduiScarduiWmCardStatus;
  110. extern BOOL CreduiHasSmartCardSupport;
  111. extern CONST CREDUI_BALLOON_TIP_INFO CreduiCapsLockTipInfo;