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.

314 lines
17 KiB

  1. #include <windows.h>
  2. #include <ntverp.h>
  3. #include "gptext.h"
  4. #define VER_FILETYPE VFT_APP
  5. #define VER_FILESUBTYPE VFT2_UNKNOWN
  6. #define VER_FILEDESCRIPTION_STR "GPTExt"
  7. #define VER_INTERNALNAME_STR "gptext\0"
  8. #define VER_ORIGINALFILENAME_STR "gptext.dll"
  9. #include "common.ver"
  10. IDI_POLICY ICON policy.ico
  11. IDI_POLICY2 ICON policy2.ico
  12. IDI_POLICY3 ICON policy3.ico
  13. IDI_DOCUMENT ICON document.ico
  14. IDI_SCRIPT ICON script.ico
  15. IDI_FILTER ICON filter.ico
  16. IDB_16x16 BITMAP "icons16.bmp"
  17. IDB_32x32 BITMAP "icons32.bmp"
  18. STRINGTABLE
  19. BEGIN
  20. IDS_SCRIPTS_NAME "Scripts"
  21. IDS_SCRIPTS_NAME_MACHINE "Scripts (Startup/Shutdown)"
  22. IDS_SCRIPTS_NAME_USER "Scripts (Logon/Logoff)"
  23. IDS_NAME "Name"
  24. IDS_STATE "State"
  25. IDS_SETTING "Setting"
  26. IDS_PARAMETERS "Parameters"
  27. IDS_ENABLED "Enabled"
  28. IDS_DISABLED "Disabled"
  29. IDS_NOTCONFIGURED "Not configured"
  30. IDS_LOGON "Logon"
  31. IDS_LOGOFF "Logoff"
  32. IDS_STARTUP "Startup"
  33. IDS_SHUTDOWN "Shutdown"
  34. IDS_BROWSEFILTER "All Files#*.*##"
  35. IDS_BROWSE "Browse"
  36. IDS_SCRIPT_EDIT "Edit Script"
  37. IDS_SCRIPT_FILTER "Script Files#*.bat;*.cmd;*.vbs;*.js;*.exe#All Files#*.*##"
  38. IDS_POLICY_NAME "Administrative Templates"
  39. IDS_POLICY_NAME_MACHINE "Administrative Templates (Computers)"
  40. IDS_POLICY_NAME_USER "Administrative Templates (Users)"
  41. IDS_TEMPLATES "&Add/Remove Templates..."
  42. IDS_TEMPLATESDESC "Manage administrative templates"
  43. IDS_SIZE "Size"
  44. IDS_MODIFIED "Modified"
  45. IDS_POLICYFILTER "Policy Templates#*.adm##"
  46. IDS_POLICYTITLE "Policy Templates"
  47. IDS_NONE "(None)"
  48. //
  49. // Dev note: If you are adding new adm files to the system and you want
  50. // them automatically loaded by the Administrative Templates snapin,
  51. // all you have to do is add the filename to **both** lists below (semi-colon seperated).
  52. //
  53. IDS_DEFAULTTEMPLATES "system.adm;inetres.adm;conf.adm;wmplayer.adm"
  54. IDS_ADDITIONALTTEMPLATES "wmplayer.adm"
  55. IDS_LISTBOX_SHOW "Show..."
  56. IDS_VALUE "Value"
  57. IDS_VALUENAME "Value Name"
  58. IDS_VALUENAMENOTUNIQUE "The name you entered has already been used. You need to enter a unique name."
  59. IDS_EMPTYVALUENAME "You need to enter a name."
  60. IDS_VALUEDATANOTUNIQUE "The value you entered has already been used. You need to enter a unique value."
  61. IDS_EMPTYVALUEDATA "You need to enter a value."
  62. IDS_FILTERING "Filtering..."
  63. IDS_FILTERINGDESC "Displays filtering options."
  64. IDS_GPONAME "GPO Name"
  65. IDS_MULTIPLEGPOS "(Merged GPOs)"
  66. IDS_DESCTEXT "%d scripts (processed from top to bottom)"
  67. IDS_LASTEXECUTED "Last Executed"
  68. IDS_SAVEFAILED "The Scripts component is unable to save the changes due to error %d."
  69. IDS_DISPLAYPROPERTIES "Display <A HREF = javascript:external.ExecuteSelectionMenuItem('_PROPERTIES')>Properties </A>"
  70. IDS_EXTRAREGSETTINGS "Extra Registry Settings"
  71. IDS_STRINGTOOLONG "The following entry in the [strings] section is too long and has been truncated.\n\n%s"
  72. IDS_WORDTOOLONG "The following keyword is too long:\n\n%s"
  73. IDS_ErrOUTOFMEMORY "There is not enough memory available. Quit one or more applications and try again."
  74. IDS_ParseErr_UNEXPECTED_KEYWORD "Unexpected keyword"
  75. IDS_ParseErr_UNEXPECTED_EOF "Unexpected end of file"
  76. IDS_ParseErr_DUPLICATE_KEYNAME "Key name specified more than once. Likely causes are: 1) the KEYNAME tag is defined multiple times in this category 2) this KEYNAME is already defined in another category with the same name \
  77. 3) this KEYNAME is already defined in another category with the same name in a different adm file."
  78. IDS_ParseErr_DUPLICATE_VALUENAME "Value name specified more than once"
  79. IDS_ParseErr_DUPLICATE_ITEMNAME "Item name specified more than once"
  80. IDS_ParseErr_DUPLICATE_ACTIONLIST "More than one action list was specified"
  81. IDS_ParseErr_NO_KEYNAME "There was no key name specified for this entry or any of its parents"
  82. IDS_ParseErr_NO_VALUENAME "There was no value name specified"
  83. IDS_ParseErr_NO_VALUE "There was no value specified"
  84. IDS_ParseErr_NO_ITEMNAME "There was no item name specified"
  85. IDS_ParseErr_NOT_NUMERIC "Expected a numeric value"
  86. IDS_ParseErr_STRING_NOT_FOUND "The corresponding string was not found in the [strings] section"
  87. IDS_ParseErr_UNMATCHED_DIRECTIVE "An unmatched interpreter directive was found"
  88. IDS_ParseErr_DUPLICATE_HELP "Help string specified more than once"
  89. IDS_ParseErr_DUPLICATE_CLIENTEXT "CLIENTEXT string specified more than once"
  90. IDS_ParseErr_INVALID_CLIENTEXT "GUID specified in CLIENTEXT is invalid. Format should be: {4765724D-ACCE-11d2-9A8F-0000F87571E3}"
  91. IDS_ParseErr_DUPLICATE_SUPPORTED "Supported string specified more than once"
  92. IDS_ParseErr_MISSINGVALUEON_OR_OFF "Missing either a VALUEON or VALUEOFF keyword. Policies using the unnamed registry value must have both VALUEON and VALUEOFF defined."
  93. IDS_ParseFmt_MSG_FORMAT "The following error occurred in %s on line %lu:\r\nError %lu %s\r\n\r\n"
  94. IDS_ParseFmt_FOUND "Found: %s\r\n"
  95. IDS_ParseFmt_EXPECTED "Expected: %s\r\n"
  96. IDS_ParseFmt_FATAL "\r\nThe file can not be loaded.\r\n"
  97. IDS_ENTRYREQUIRED "You need to enter something for ""%s"" This field cannot be left blank."
  98. IDS_INVALIDNUM "You need to enter a number for ""%s"" This field has invalid characters or the number is too large."
  99. IDS_NUMBERTOOLARGE "%lu is greater than the maximum allowed value of %lu. %lu will be saved instead of %lu."
  100. IDS_NUMBERTOOSMALL "%d is less than the minimum allowed value of %d. %d will be saved instead of %d."
  101. IDS_POLICYCHANGEDFAILED "The Group Policy snapin was unable to save your changes due to the following error:\r\n\r\n %s"
  102. IDS_INVALIDADMFILE "%s is not a valid template file. Only files that end with the .adm file extension can be added to this Group Policy Object."
  103. IDS_IPSEC_NAME "IP Security"
  104. IDS_PSCHED_NAME "QoS Packet Scheduler"
  105. IDS_LOGON_DESC "A user logon script"
  106. IDS_LOGOFF_DESC "A user logoff script"
  107. IDS_STARTUP_DESC "A computer startup script"
  108. IDS_SHUTDOWN_DESC "A computer shutdown script"
  109. IDS_SCRIPTS_DESC "Group Policy scripts"
  110. IDS_SCRIPTS_USER_DESC "Administrators use this extension to specify scripts that are run when the user logs on or off the computer. Scripts run in the user's context."
  111. IDS_SCRIPTS_COMPUTER_DESC "Administrators use this extension to specify scripts that are to run during computer startup or shutdown. Scripts run in the Local System context."
  112. IDS_SCRIPTS_LOGON "Contains user logon scripts."
  113. IDS_SCRIPTS_LOGOFF "Contains user logoff scripts."
  114. IDS_SCRIPTS_STARTUP "Contains computer startup scripts."
  115. IDS_SCRIPTS_SHUTDOWN "Contains computer shutdown scripts."
  116. IDS_POLICY_DESC "The Group Policy Administrative Templates node contains all registry-based policy information. "
  117. IDS_RSOP_ADMFAILED "The latest versions of the ADM files below are not available. This can be due to insufficient permissions or unavailable network resources. The local copy of these ADM files will be used."
  118. IDS_FAILED_RSOPFMT "%.100s\r\nLocation - ""%.300s""\r\nError - %.100s"
  119. IDS_BINARYDATA "(Binary data)"
  120. IDS_UNKNOWNDATA "(Unknown data format)"
  121. IDS_EXSETROOT_DESC "This node contains registry settings that do not correspond to an Administrative Template policy (e.g. they did not originate from a .adm file). These settings may have been defined by a different snap-in."
  122. IDS_EXSET_DESC "This registry setting does not correspond to an Administrative Template policy (e.g. they did not originate from a .adm file). It may have been defined by a different snap-in."
  123. IDS_PREFERENCE "\r\n\r\nNote: This registry setting is not stored in a policies key and thus considered a preference. Therefore if the Group Policy Object that implements this setting is ever removed, this setting will remain."
  124. IDS_SUPPORTEDDESC "<BR>\n<BR>\nRequirements:<BR>\n"
  125. IDS_NOSUPPORTINFO "Policies with no Requirements information"
  126. END
  127. IDD_SCRIPT DIALOG DISCARDABLE 0, 0, 252, 218
  128. STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
  129. CAPTION "Scripts"
  130. FONT 8, "MS Shell Dlg"
  131. BEGIN
  132. ICON IDI_SCRIPT, -1, 7, 7, 18, 20
  133. LTEXT "%s Scripts for %s",IDC_SCRIPT_TITLE,46,12,197,16
  134. CONTROL "",-1,"Static",SS_BLACKFRAME | SS_SUNKEN,7,34,238,1
  135. CONTROL "",IDC_SCRIPT_LIST,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS |
  136. LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,7,43,181,108
  137. PUSHBUTTON "&Up",IDC_SCRIPT_UP,195,55,50,14
  138. PUSHBUTTON "Do&wn",IDC_SCRIPT_DOWN,195,69,50,14
  139. PUSHBUTTON "A&dd...",IDC_SCRIPT_ADD,195,101,50,14
  140. PUSHBUTTON "&Edit...",IDC_SCRIPT_EDIT,195,119,50,14
  141. PUSHBUTTON "&Remove",IDC_SCRIPT_REMOVE,195,137,50,14
  142. CONTROL "",-1,"Static",SS_BLACKFRAME | SS_SUNKEN,7,167,238,1
  143. LTEXT "To view the script files stored in this Group Policy Object, press the button below.",
  144. -1,7,173,197,16
  145. PUSHBUTTON "&Show Files...",IDC_SCRIPT_SHOW,7,195,80,14
  146. END
  147. IDD_SCRIPT_EDIT DIALOGEX 22, 34, 252, 100
  148. STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
  149. EXSTYLE WS_EX_CONTEXTHELP
  150. CAPTION "Add a Script"
  151. FONT 8, "MS Shell Dlg"
  152. BEGIN
  153. LTEXT "Script &Name:", -1, 8, 11, 145, 8
  154. EDITTEXT IDC_SCRIPT_NAME, 8, 23, 177, 12, ES_AUTOHSCROLL
  155. LTEXT "Script &Parameters:", -1, 8, 46, 147, 8
  156. EDITTEXT IDC_SCRIPT_ARGS, 8, 58, 177, 12, ES_AUTOHSCROLL
  157. PUSHBUTTON "&Browse...", IDC_SCRIPT_BROWSE, 194, 22, 50, 14
  158. DEFPUSHBUTTON "OK", IDOK, 138, 82, 50, 14
  159. PUSHBUTTON "Cancel", IDCANCEL, 195, 82, 50, 14
  160. END
  161. IDD_POLICY DIALOGEX DISCARDABLE 0, 0, 252, 218
  162. STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
  163. CAPTION "Setting"
  164. FONT 8, "MS Shell Dlg"
  165. BEGIN
  166. ICON IDI_POLICY2, IDC_POLICYICON, 7, 8, 16, 16
  167. LTEXT "", IDC_POLICY, 20, 10, 225, 8, SS_ENDELLIPSIS | SS_NOPREFIX
  168. CONTROL "", -1, "Static", SS_BLACKFRAME | SS_SUNKEN, 7, 25, 238, 1
  169. AUTORADIOBUTTON "Not &Configured", IDC_NOCONFIG, 7, 34, 238, 10, WS_GROUP | WS_TABSTOP
  170. AUTORADIOBUTTON "&Enabled", IDC_ENABLED, 7, 46, 238, 10
  171. AUTORADIOBUTTON "&Disabled", IDC_DISABLED, 7, 58, 238, 10
  172. CONTROL "",IDC_POLICY_SETTINGS,"ClipClass",WS_TABSTOP | WS_VISIBLE |
  173. WS_CHILD | WS_VSCROLL | WS_HSCROLL, 7, 70, 238, 115, WS_EX_CLIENTEDGE
  174. LTEXT "Supported on:", IDC_SUPPORTEDTITLE, 7, 187, 50, 8
  175. LTEXT "", IDC_SUPPORTED, 60, 187, 178, 8, SS_ENDELLIPSIS | SS_NOPREFIX
  176. PUSHBUTTON "&Previous Setting",IDC_POLICY_PREVIOUS,7,199,75,14, WS_GROUP | WS_TABSTOP
  177. PUSHBUTTON "&Next Setting",IDC_POLICY_NEXT,86,199,75,14
  178. END
  179. IDD_POLICY_HELP DIALOG DISCARDABLE 0, 0, 252, 218
  180. STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
  181. CAPTION "Explain"
  182. FONT 8, "MS Shell Dlg"
  183. BEGIN
  184. LTEXT "",IDC_POLICY_TITLE,7,7,235,10, SS_ENDELLIPSIS | SS_NOPREFIX
  185. PUSHBUTTON "&Previous Setting",IDC_POLICY_PREVIOUS,7,199,75,14
  186. PUSHBUTTON "&Next Setting",IDC_POLICY_NEXT,86,199,75,14
  187. EDITTEXT IDC_POLICY_HELP,7,19,238,176,ES_READONLY | ES_MULTILINE | ES_AUTOVSCROLL | WS_VSCROLL
  188. END
  189. IDD_POLICY_PRECEDENCE DIALOG DISCARDABLE 0, 0, 252, 218
  190. STYLE WS_CHILD | WS_DISABLED | WS_CAPTION
  191. CAPTION "Precedence"
  192. FONT 8, "MS Shell Dlg"
  193. BEGIN
  194. LTEXT "",IDC_POLICY_TITLE,7,7,235,10, SS_ENDELLIPSIS | SS_NOPREFIX
  195. LTEXT "GPOs higher in the list have the highest priority",-1,7,187,238,10
  196. PUSHBUTTON "&Previous Setting",IDC_POLICY_PREVIOUS,7,199,75,14
  197. PUSHBUTTON "&Next Setting",IDC_POLICY_NEXT,86,199,75,14
  198. CONTROL "",IDC_POLICY_PRECEDENCE,"SysListView32",LVS_REPORT | LVS_SINGLESEL |
  199. LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,7,19,238,164
  200. END
  201. IDD_TEMPLATES DIALOG 42, 63, 288, 150
  202. STYLE DS_MODALFRAME | DS_CONTEXTHELP | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
  203. CAPTION "Add/Remove Templates"
  204. FONT 8, "MS Shell Dlg"
  205. BEGIN
  206. LTEXT "&Current Policy Templates:", IDC_TEMPLATE_TEXT, 8, 8, 248, 8
  207. CONTROL "", IDC_TEMPLATELIST, WC_LISTVIEW, LVS_REPORT |
  208. LVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,
  209. 8, 20, 270, 100
  210. PUSHBUTTON "&Add...", IDC_ADDTEMPLATES, 8, 130, 50, 14
  211. PUSHBUTTON "&Remove", IDC_REMOVETEMPLATES, 66, 130, 50, 14, WS_DISABLED
  212. DEFPUSHBUTTON "C&lose", IDCLOSE, 229, 130, 50, 14
  213. END
  214. IDD_POLICY_LBADD DIALOG 6, 18, 260, 46
  215. STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
  216. CAPTION "Add Item"
  217. FONT 8, "MS Shell Dlg"
  218. BEGIN
  219. LTEXT "&Enter the item to be added:", -1, 7, 7, 180, 8
  220. EDITTEXT IDC_POLICY_VALUEDATA, 7, 19, 180, 12, ES_AUTOHSCROLL
  221. PUSHBUTTON "OK", IDOK, 203, 7, 50, 14
  222. PUSHBUTTON "Cancel", IDCANCEL, 203, 24, 50, 14
  223. EDITTEXT IDC_POLICY_VALUENAME, 0,0,1,1, ES_AUTOHSCROLL, WS_DISABLED
  224. END
  225. IDD_POLICY_LBADD2 DIALOG 6, 18, 260, 77
  226. STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
  227. CAPTION "Add Item"
  228. FONT 8, "MS Shell Dlg"
  229. BEGIN
  230. LTEXT "Enter the &name of the item to be added:", -1, 7, 7, 180, 8
  231. EDITTEXT IDC_POLICY_VALUENAME, 7, 19, 180, 12, ES_AUTOHSCROLL
  232. LTEXT "Enter the &value of the item to be added:", -1, 7, 42, 180, 8
  233. EDITTEXT IDC_POLICY_VALUEDATA, 7, 54, 180, 12, ES_AUTOHSCROLL
  234. PUSHBUTTON "OK", IDOK, 203, 7, 50, 14
  235. PUSHBUTTON "Cancel", IDCANCEL, 203, 24, 50, 14
  236. END
  237. IDD_POLICY_SHOWLISTBOX DIALOGEX 6, 18, 377, 163
  238. STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
  239. CAPTION "Show Contents"
  240. FONT 8, "MS Shell Dlg"
  241. BEGIN
  242. CONTROL "",IDC_POLICY_LISTBOX,"SysListView32",WS_TABSTOP | WS_VSCROLL |
  243. LVS_REPORT | LVS_SORTASCENDING, 6, 18, 302, 140, WS_EX_CLIENTEDGE
  244. LTEXT "",IDC_POLICY_TITLE, 6, 6, 171, 8
  245. DEFPUSHBUTTON "OK", IDOK, 317, 7, 54, 14
  246. PUSHBUTTON "Cancel", IDCANCEL, 317, 24, 54, 14
  247. PUSHBUTTON "&Add...", IDC_POLICY_ADD, 317, 64, 54, 14
  248. PUSHBUTTON "&Remove",IDC_POLICY_REMOVE, 317, 81, 54, 14
  249. END
  250. IDD_POLICY_FILTERING DIALOGEX 6, 18, 252, 213
  251. STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
  252. EXSTYLE WS_EX_CONTEXTHELP
  253. CAPTION "Filtering"
  254. FONT 8, "MS Shell Dlg"
  255. BEGIN
  256. ICON IDI_FILTER, IDC_FILTERING_ICON, 7, 7, 18, 20
  257. LTEXT "These options allow you to filter the Administrative Templates policies.", IDC_STATIC,
  258. 46, 10, 195, 16
  259. CONTROL "", -1, "Static", SS_BLACKFRAME | SS_SUNKEN, 7, 33, 238, 1
  260. AUTOCHECKBOX "&Filter by Requirements information", IDC_SUPPORTEDOPTION, 7, 42, 230, 10
  261. LTEXT "Select the &items to be displayed:", IDC_SUPPORTEDONTITLE, 20, 56 222, 8
  262. CONTROL "",IDC_FILTERLIST,"SysListView32",WS_TABSTOP | WS_VSCROLL |
  263. LVS_REPORT | LVS_SORTASCENDING | LVS_NOCOLUMNHEADER, 20, 66, 222, 70, WS_EX_CLIENTEDGE
  264. PUSHBUTTON "&Select All", IDC_SELECTALL, 20, 139, 50, 14
  265. PUSHBUTTON "&Deselect All", IDC_DESELECTALL, 75, 139, 50, 14
  266. AUTOCHECKBOX "Only show &configured policy settings", IDC_SHOWCONFIG, 7, 163, 230, 10
  267. AUTOCHECKBOX "Only show &policy settings that can be fully managed", IDC_SHOWPOLICIES, 7, 175, 230, 10
  268. PUSHBUTTON "OK", IDOK, 71, 193, 50, 14
  269. PUSHBUTTON "Cancel", IDCANCEL, 131, 193, 50, 14
  270. END
  271. IDD_ERROR_ADMTEMPLATES DIALOGEX 45, 48, 275, 141
  272. STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_EX_TOPMOST
  273. CAPTION "Administrative Templates"
  274. FONT 8, "MS Shell Dlg"
  275. BEGIN
  276. ICON IDI_POLICY, IDC_ERROR_ICON, 8, 11, 18, 20
  277. LTEXT "", IDC_ERRORTEXT, 40, 11, 165, 36
  278. GROUPBOX "Details:", IDC_DETAILSBORDER, 8, 52, 262, 81
  279. EDITTEXT IDC_DETAILSTEXT, 14, 62, 250, 65, ES_MULTILINE |
  280. ES_AUTOVSCROLL | ES_READONLY | WS_VSCROLL | ES_AUTOHSCROLL | WS_HSCROLL
  281. DEFPUSHBUTTON "&Close", IDCLOSE, 219, 9, 50, 14
  282. END