├── .gitattributes
├── .gitignore
├── README.md
└── Scripts
├── Autorun.inf
├── BDD_Autorun.wsf
├── BDD_Welcome_ENU.xml
├── BackButton.JPG
├── BackButton.PNG
├── Computer.png
├── Create.png
├── Credentials_ENU.xml
├── Credentials_scripts.vbs
├── Delete.png
├── DeployWiz_AdminAccounts.xml
├── DeployWiz_AdminPassword.vbs
├── DeployWiz_AdminPassword.xml
├── DeployWiz_Administrator.png
├── DeployWiz_Applications.vbs
├── DeployWiz_Applications.xml
├── DeployWiz_BitLocker.vbs
├── DeployWiz_BitLocker.xml
├── DeployWiz_CaptureImage.vbs
├── DeployWiz_CaptureImage.xml
├── DeployWiz_Computer.png
├── DeployWiz_ComputerBackup.vbs
├── DeployWiz_ComputerBackup.xml
├── DeployWiz_ComputerName.vbs
├── DeployWiz_ComputerName.xml
├── DeployWiz_Credentials.png
├── DeployWiz_Credentials.vbs
├── DeployWiz_Credentials.xml
├── DeployWiz_Definition_ENU.xml
├── DeployWiz_Initialization.vbs
├── DeployWiz_Language.png
├── DeployWiz_LanguagePack.vbs
├── DeployWiz_LanguagePack.xml
├── DeployWiz_LanguageUI.vbs
├── DeployWiz_LanguageUI.xml
├── DeployWiz_Network.png
├── DeployWiz_OfflineData.vbs
├── DeployWiz_OfflineData.xml
├── DeployWiz_ProductKeyVista.vbs
├── DeployWiz_ProductKeyVista.xml
├── DeployWiz_Ready.vbs
├── DeployWiz_Ready.xml
├── DeployWiz_Roles.vbs
├── DeployWiz_Roles.xml
├── DeployWiz_Roles.xsl
├── DeployWiz_SelectTS.vbs
├── DeployWiz_SelectTS.xml
├── DeployWiz_TimeZone.png
├── DeployWiz_UserData.vbs
├── DeployWiz_UserData.xml
├── DeployWiz_UserDataRestore.vbs
├── DeployWiz_UserDataRestore.xml
├── DeployWiz_Validation.vbs
├── Extend.png
├── FolderIcon.png
├── Format.png
├── GetCurrentTimeZoneExit.vbs
├── ItemIcon1.png
├── LTIApply.wsf
├── LTIBootstrap.vbs
├── LTICleanup.wsf
├── LTICopyScripts.wsf
├── LTIGetFolder.wsf
├── LTIOEM.wsf
├── LTISuspend.wsf
├── LTISysprep.wsf
├── ListOfLanguages.xml
├── LiteTouch.vbs
├── LiteTouch.wsf
├── MinusIcon1.png
├── NICSettings_Definition_ENU.xml
├── NavBar.png
├── OSDBranding.vbs
├── OSDBrandingx64.vbs
├── OSDEndTime.vbs
├── OSDLocalAdmins.vbs
├── OSDProgress.vbs
├── OSD_BaseVariables.vbs
├── PlusIcon1.png
├── Refresh.png
├── SelectItem.jpg
├── SelectItem.png
├── ServerManager.xml
├── SharesBackup
├── quotas_backup.vbs
├── quotas_restore.vbs
├── shares_backup.vbs
└── shares_restore.vbs
├── Summary_Definition_ENU.xml
├── Summary_scripts.vbs
├── UDIWizard.wsf
├── UDIWizard_Config.xml
├── UDIWizard_Config.xml.app
├── UDIoffline.xml
├── WelcomeBanner.jpg
├── WelcomeWiz_Background.jpg
├── WelcomeWiz_Choice.vbs
├── WelcomeWiz_Choice.xml
├── WelcomeWiz_DeployRoot.vbs
├── WelcomeWiz_DeployRoot.xml
├── WelcomeWiz_Initialize.vbs
├── WelcomeWiz_Initialize.xml
├── WizUtility.vbs
├── Wizard.css
├── Wizard.hta
├── Wizard.ico
├── ZTIAppXmlGen.wsf
├── ZTIApplications.wsf
├── ZTIApplyGPOPack.wsf
├── ZTIAuthorizeDHCP.wsf
├── ZTIBCDUtility.vbs
├── ZTIBIOSCheck.wsf
├── ZTIBIOSCheck.xml
├── ZTIBackup.wsf
├── ZTIBde.wsf
├── ZTICoalesce.wsf
├── ZTIConfigFile.vbs
├── ZTIConfigure.wsf
├── ZTIConfigure.xml
├── ZTIConfigureADDS.wsf
├── ZTIConfigureDHCP.wsf
├── ZTIConfigureDNS.wsf
├── ZTIConfirmDiskpart.vbs
├── ZTIConnect.wsf
├── ZTICopyLogs.wsf
├── ZTIDataAccess.vbs
├── ZTIDisableBDEProtectors.wsf
├── ZTIDiskUtility.vbs
├── ZTIDiskpart.wsf
├── ZTIDomainJoin.wsf
├── ZTIDone.wsf
├── ZTIDrivers.wsf
├── ZTIErrorMsg.wsf
├── ZTIExecuteRunbook.wsf
├── ZTIGather.wsf
├── ZTIGather.xml
├── ZTIGroups.wsf
├── ZTILangPacksOnline.wsf
├── ZTIModifyVol.wsf
├── ZTIMoveStateStore.wsf
├── ZTINICConfig.wsf
├── ZTINextPhase.wsf
├── ZTINicUtility.vbs
├── ZTIOSRole.wsf
├── ZTIOSRolePS.ps1
├── ZTIOptIn.wsf
├── ZTIPSUtility.vbs
├── ZTIPatches.wsf
├── ZTIPowerShell.wsf
├── ZTIPrereq.vbs
├── ZTISCCM.wsf
├── ZTISetBackground.wsf
├── ZTISetVariable.wsf
├── ZTISupportedPlatforms.xml
├── ZTITatoo.mof
├── ZTITatoo.wsf
├── ZTIUserState.wsf
├── ZTIUserState_Config.xml
├── ZTIUtility.vbs
├── ZTIVHDCreate.wsf
├── ZTIValidate.wsf
├── ZTIWinRE.wsf
├── ZTIWindowsUpdate.wsf
├── ZTIWipeDisk.wsf
├── btnout.png
├── btnover.png
├── btnsel.png
├── checkforservices.vbs
├── header-image.png
├── minusico.gif
├── plusicon.gif
└── ztiRunCommandHidden.wsf
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Auto detect text files and perform LF normalization
2 | * text=auto
3 |
4 | # Custom for Visual Studio
5 | *.cs diff=csharp
6 | *.sln merge=union
7 | *.csproj merge=union
8 | *.vbproj merge=union
9 | *.fsproj merge=union
10 | *.dbproj merge=union
11 |
12 | # Standard to msysgit
13 | *.doc diff=astextplain
14 | *.DOC diff=astextplain
15 | *.docx diff=astextplain
16 | *.DOCX diff=astextplain
17 | *.dot diff=astextplain
18 | *.DOT diff=astextplain
19 | *.pdf diff=astextplain
20 | *.PDF diff=astextplain
21 | *.rtf diff=astextplain
22 | *.RTF diff=astextplain
23 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | #################
2 | ## Eclipse
3 | #################
4 |
5 | *.pydevproject
6 | .project
7 | .metadata
8 | bin/
9 | tmp/
10 | *.tmp
11 | *.bak
12 | *.swp
13 | *~.nib
14 | local.properties
15 | .classpath
16 | .settings/
17 | .loadpath
18 |
19 | # External tool builders
20 | .externalToolBuilders/
21 |
22 | # Locally stored "Eclipse launch configurations"
23 | *.launch
24 |
25 | # CDT-specific
26 | .cproject
27 |
28 | # PDT-specific
29 | .buildpath
30 |
31 |
32 | #################
33 | ## Visual Studio
34 | #################
35 |
36 | ## Ignore Visual Studio temporary files, build results, and
37 | ## files generated by popular Visual Studio add-ons.
38 |
39 | # User-specific files
40 | *.suo
41 | *.user
42 | *.sln.docstates
43 |
44 | # Build results
45 |
46 | [Dd]ebug/
47 | [Rr]elease/
48 | x64/
49 | build/
50 | [Bb]in/
51 | [Oo]bj/
52 |
53 | # MSTest test Results
54 | [Tt]est[Rr]esult*/
55 | [Bb]uild[Ll]og.*
56 |
57 | *_i.c
58 | *_p.c
59 | *.ilk
60 | *.meta
61 | *.obj
62 | *.pch
63 | *.pdb
64 | *.pgc
65 | *.pgd
66 | *.rsp
67 | *.sbr
68 | *.tlb
69 | *.tli
70 | *.tlh
71 | *.tmp
72 | *.tmp_proj
73 | *.log
74 | *.vspscc
75 | *.vssscc
76 | .builds
77 | *.pidb
78 | *.log
79 | *.scc
80 |
81 | # Visual C++ cache files
82 | ipch/
83 | *.aps
84 | *.ncb
85 | *.opensdf
86 | *.sdf
87 | *.cachefile
88 |
89 | # Visual Studio profiler
90 | *.psess
91 | *.vsp
92 | *.vspx
93 |
94 | # Guidance Automation Toolkit
95 | *.gpState
96 |
97 | # ReSharper is a .NET coding add-in
98 | _ReSharper*/
99 | *.[Rr]e[Ss]harper
100 |
101 | # TeamCity is a build add-in
102 | _TeamCity*
103 |
104 | # DotCover is a Code Coverage Tool
105 | *.dotCover
106 |
107 | # NCrunch
108 | *.ncrunch*
109 | .*crunch*.local.xml
110 |
111 | # Installshield output folder
112 | [Ee]xpress/
113 |
114 | # DocProject is a documentation generator add-in
115 | DocProject/buildhelp/
116 | DocProject/Help/*.HxT
117 | DocProject/Help/*.HxC
118 | DocProject/Help/*.hhc
119 | DocProject/Help/*.hhk
120 | DocProject/Help/*.hhp
121 | DocProject/Help/Html2
122 | DocProject/Help/html
123 |
124 | # Click-Once directory
125 | publish/
126 |
127 | # Publish Web Output
128 | *.Publish.xml
129 | *.pubxml
130 |
131 | # NuGet Packages Directory
132 | ## TODO: If you have NuGet Package Restore enabled, uncomment the next line
133 | #packages/
134 |
135 | # Windows Azure Build Output
136 | csx
137 | *.build.csdef
138 |
139 | # Windows Store app package directory
140 | AppPackages/
141 |
142 | # Others
143 | sql/
144 | *.Cache
145 | ClientBin/
146 | [Ss]tyle[Cc]op.*
147 | ~$*
148 | *~
149 | *.dbmdl
150 | *.[Pp]ublish.xml
151 | *.pfx
152 | *.publishsettings
153 |
154 | # RIA/Silverlight projects
155 | Generated_Code/
156 |
157 | # Backup & report files from converting an old project file to a newer
158 | # Visual Studio version. Backup files are not needed, because we have git ;-)
159 | _UpgradeReport_Files/
160 | Backup*/
161 | UpgradeLog*.XML
162 | UpgradeLog*.htm
163 |
164 | # SQL Server files
165 | App_Data/*.mdf
166 | App_Data/*.ldf
167 |
168 | #############
169 | ## Windows detritus
170 | #############
171 |
172 | # Windows image file caches
173 | Thumbs.db
174 | ehthumbs.db
175 |
176 | # Folder config file
177 | Desktop.ini
178 |
179 | # Recycle Bin used on file shares
180 | $RECYCLE.BIN/
181 |
182 | # Mac crap
183 | .DS_Store
184 |
185 |
186 | #############
187 | ## Python
188 | #############
189 |
190 | *.py[co]
191 |
192 | # Packages
193 | *.egg
194 | *.egg-info
195 | dist/
196 | build/
197 | eggs/
198 | parts/
199 | var/
200 | sdist/
201 | develop-eggs/
202 | .installed.cfg
203 |
204 | # Installer logs
205 | pip-log.txt
206 |
207 | # Unit test / coverage reports
208 | .coverage
209 | .tox
210 |
211 | #Translations
212 | *.mo
213 |
214 | #Mr Developer
215 | .mr.developer.cfg
216 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | MS-Deployment-toolkit-scripts
2 | =============================
3 |
4 | Custom scripts for MDT 2012U1.
5 | I do not own any of this scripts (except for shares_backup.vbs, shares_restore.vbs, quotas_backup.vbs, quotas_restore.vbs), everything is belong to Microsoft. I've just changed some of them.
6 |
--------------------------------------------------------------------------------
/Scripts/Autorun.inf:
--------------------------------------------------------------------------------
1 | [AutoRun]
2 | action=Windows Deployment Wizard
3 | open=wscript.exe Deploy\Scripts\BDD_AutoRun.wsf
4 | icon=Deploy\Scripts\Wizard.ico
5 |
6 |
--------------------------------------------------------------------------------
/Scripts/BDD_Autorun.wsf:
--------------------------------------------------------------------------------
1 |
2 |
51 |
52 |
53 |
--------------------------------------------------------------------------------
/Scripts/BDD_Welcome_ENU.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 | true
22 |
23 |
24 |
25 |
26 |
27 |
28 | "YES" ]]>
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/Scripts/BackButton.JPG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/BackButton.JPG
--------------------------------------------------------------------------------
/Scripts/BackButton.PNG:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/BackButton.PNG
--------------------------------------------------------------------------------
/Scripts/Computer.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/Computer.png
--------------------------------------------------------------------------------
/Scripts/Create.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/Create.png
--------------------------------------------------------------------------------
/Scripts/Credentials_ENU.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 |
23 |
24 | Credentials_Scripts.vbs
25 | true
26 |
27 |
28 |
29 |
30 | Specify credentials for connecting to network shares.
33 |
34 |
35 |
64 |
65 | ]]>
66 |
67 |
68 | O K ]]>
69 |
70 |
71 | Back]]>
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
--------------------------------------------------------------------------------
/Scripts/Credentials_scripts.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: Credentials_scripts.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Scripts to initialize and validate credential wizard
12 | ' //
13 | ' // ***************************************************************************
14 |
15 | Option explicit
16 |
17 | Dim sValidateUNC
18 | Dim sValidateDomain
19 | Dim bDoNotSaveParameters
20 | Dim bLeaveShareOpen
21 |
22 |
23 | Function UserCredentialsInitialize
24 | Dim oArguments
25 | Dim SWbemObject
26 | Dim sNewDomain
27 | Dim aUNCPath
28 |
29 |
30 | ' Parse the Command Line
31 |
32 | sValidateDomain = oUtility.Arguments.Item("ValidateAgainstDomain")
33 | aUNCPath = Split(oUtility.Arguments.Item("ValidateAgainstUNCPath"),"\")
34 | bDoNotSaveParameters = oUtility.Arguments.Exists("DoNotSave")
35 | bLeaveShareOpen = oUtility.Arguments.Exists("LeaveShareOpen")
36 |
37 | oEnvironment.Item("UserCredentials") = CStr(FALSE)
38 |
39 | If UBound(aUNCPath) > 2 then
40 | If aUNCPath(0)="" and aUNCPath(1)="" and aUNCPath(2)<>"" and aUNCPath(3)<>"" then
41 | sValidateUNC = "\\" & aUNCPath(2) & "\" & aUNCPath(3)
42 | oLogging.CreateEntry "Validate Against UNC: " & sValidateUNC , LogTypeInfo
43 | End if
44 | End if
45 |
46 | If not IsEmpty(sValidateDomain) then
47 |
48 | oLogging.CreateEntry "Validate Against Domain: " & sValidateDomain , LogTypeInfo
49 |
50 | ElseIf not IsEmpty(sValidateUNC) then
51 |
52 | sValidateDomain = GetDomainDefault
53 | oLogging.CreateEntry "Validate Against UNC: " & sValidateUNC , LogTypeInfo
54 | ' Do we need to do any checking for IP address ( as compared to server names )
55 |
56 | Else
57 |
58 | sValidateDomain = GetDomainDefault
59 |
60 | End if
61 |
62 | If UserName.Value = "" and oNetwork.UserName <> "" and oNetwork.UserName <> "SYSTEM" then
63 | UserName.Value = oNetwork.UserName
64 | End if
65 |
66 | If oProperties("userdomain") = "" and sValidateDomain <> "" then
67 | userdomain.Value = sValidateDomain
68 | ElseIf oproperties("userdomain") = "" and oNetwork.UserDomain <> "" then
69 | userdomain.Value = oNetwork.UserDomain
70 | End if
71 |
72 | End function
73 |
74 |
75 | Function ValidateCredentials
76 | Dim r
77 |
78 | InvalidCredentials.style.display = "none"
79 | ValidateCredentials = ParseAllWarningLabelsEx(userdomain, username)
80 |
81 | If ValidateCredentials then
82 |
83 | r = CheckCredentials(sValidateUNC, UserName.value, userdomain.Value, userpassword.value)
84 | If r <> TRUE then
85 | InvalidCredentials.innerText = "* Invalid credentials: " & r
86 | InvalidCredentials.style.display = "inline"
87 | ValidateCredentials = false
88 | End if
89 |
90 | End if
91 |
92 | End Function
93 |
--------------------------------------------------------------------------------
/Scripts/Delete.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/Delete.png
--------------------------------------------------------------------------------
/Scripts/DeployWiz_AdminAccounts.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 |
23 |
24 | Specify accounts to be added to the local Administrators group.
26 |
27 |
28 |
29 |
47 |
48 | ]]>
49 |
50 |
51 |
52 |
53 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_AdminPassword.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Validation.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Validation routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 | Option Explicit
16 |
17 |
18 | '''''''''''''''''''''''''''''''''''''
19 | ' Validate Password
20 | '
21 |
22 | Function ValidatePassword
23 |
24 | ValidatePassword = ParseAllWarningLabels
25 |
26 | NonMatchPassword.style.display = "none"
27 | If Password1.Value <> "" then
28 | If Password1.Value <> Password2.Value then
29 | ValidatePassword = FALSE
30 | NonMatchPassword.style.display = "inline"
31 | End if
32 | End if
33 |
34 | ButtonNext.Disabled = not ValidatePassword
35 |
36 | End Function
37 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_AdminPassword.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_AdminPassword.vbs
23 |
24 |
25 |
26 |
27 | Specify the Administrator account password.
29 |
30 | This password will be used for logging onto the computer after a restart.
31 |
32 |
51 |
52 | ]]>
53 |
54 |
55 |
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Administrator.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/DeployWiz_Administrator.png
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Applications.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Applications.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Deployment Wizard application initialization routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 |
19 |
20 | '''''''''''''''''''''''''''''''''''''''''''
21 | ' Application List
22 | '
23 |
24 | Dim g_sApplicationDialog
25 | Dim g_oXMLAppList
26 |
27 | Function IsThereAtLeastOneApplicationPresent
28 |
29 | Dim oXMLAppList
30 | Dim dXMLCollection
31 | Dim oTaskList
32 | Dim oAction
33 |
34 | ' Bail out early if there is no "Install Application" step in the task sequence
35 |
36 | If not FindTaskSequenceStep( "//step[@type='BDD_InstallApplication' and ./defaultVarList/variable[@name='ApplicationGUID'] and ./defaultVarList[variable='']]", "ZTIApplications.wsf" ) then
37 | IsThereAtLeastOneApplicationPresent = false
38 | Exit function
39 | End if
40 |
41 |
42 | ' Load and cache the application list
43 |
44 | If IsEmpty(g_oXMLAppList) then
45 | Set g_oXMLAppList = new ConfigFile
46 | g_oXMLAppList.sFileType = "Applications"
47 | End if
48 |
49 |
50 | ' Get the filtered list of applications
51 |
52 | g_oXMLAppList.sSelectionProfile = oEnvironment.Item("WizardSelectionProfile")
53 | g_oXMLAppList.sCustomSelectionProfile = oEnvironment.Item("CustomWizardSelectionProfile")
54 | Set dXMLCollection = g_oXMLAppList.FindItems
55 |
56 | If dXMLCollection.count = 0 then
57 | IsThereAtLeastOneApplicationPresent = False
58 | g_sApplicationDialog = ""
59 | Exit Function
60 | End if
61 |
62 | g_sApplicationDialog = g_oXMLAppList.GetHTMLEx( "CheckBox", "Applications" )
63 |
64 | IsThereAtLeastOneApplicationPresent = True
65 |
66 | End function
67 |
68 | Function InitializeApplicationList
69 |
70 | AppListBox.InnerHTML = g_sApplicationDialog
71 | PopulateElements
72 |
73 | End Function
74 |
75 |
76 | Function ReadyInitializeApplicationList
77 | Dim oInput, oApplicationList, oAppItem
78 |
79 | If not ImageList.readystate = "complete" then
80 | Exit function
81 | End if
82 |
83 | Set oApplicationList = document.getElementsByName("Applications")
84 |
85 | If oApplicationList is nothing then
86 | Exit function
87 | ElseIf oApplicationList.Length < 1 then
88 | Exit function
89 | End if
90 |
91 | For each oInput in oApplicationList
92 | If UCase(document.all.item(oInput.SourceIndex - 1).TagName) = "INPUT" then
93 | If oInput.Value = "" then
94 | document.all.item(oInput.SourceIndex - 1).Disabled = TRUE
95 | document.all.item(oInput.SourceIndex - 1).Style.Display = "none"
96 | Else
97 | document.all.item(oInput.SourceIndex - 1).Style.Display = "inline"
98 | If not IsEmpty(Property("Applications"))then
99 | For each oAppItem in Property("Applications")
100 | If UCase(oAppItem) = UCase(oInput.Value) then
101 | document.all.item(oInput.SourceIndex - 1).checked = TRUE
102 | Exit for
103 | End if
104 | Next
105 | End if
106 | If not IsEmpty(Property("MandatoryApplications"))then
107 | For each oAppItem in Property("MandatoryApplications")
108 | If UCase(oAppItem) = UCase(oInput.Value) then
109 | document.all.item(oInput.SourceIndex - 1).disabled = TRUE
110 | document.all.item(oInput.SourceIndex - 1).checked = TRUE
111 | Exit for
112 | End if
113 | Next
114 | End if
115 |
116 | End if
117 | End if
118 |
119 | Next
120 |
121 | End function
122 |
123 |
124 | Sub AppItemChange
125 |
126 | document.all.item(window.event.srcElement.SourceIndex + 1).Disabled = not window.event.SrcElement.checked
127 |
128 | End sub
129 |
130 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Applications.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_Initialization.vbs
23 | DeployWiz_Applications.vbs
24 |
25 |
26 |
27 |
28 |
29 | Выберите приложения для установки.
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 | ]]>
43 |
44 |
45 |
46 |
47 |
48 |
49 | "YES" and UCase(Property("DeploymentType"))<>"REPLACE"]]>
50 |
51 | Пароль администратора.
53 |
54 |
55 | Этот пароль будет использован для авторизации после разворачивания ОС.
56 | Пароль администратора:
57 |
58 | * Заполнение обязательно
59 |
60 | Пожалуйста, повторите пароль администратора:
61 |
62 | ОШИБКА! Пароли не совпадают!
63 |
64 |
65 | ]]>
66 |
67 |
68 |
69 |
70 |
71 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_BitLocker.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Initialization.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Initialization routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 |
19 | Function InitializeBDE
20 |
21 | Dim sType
22 |
23 | sType = ucase(Property("BdeInstall"))
24 | If sType = "" then
25 | sType = ucase(Property("OSDBitLockerMode"))
26 | End if
27 |
28 | Select Case sType
29 | Case "TPM"
30 | BdeRadio2.checked = true
31 | BdeModeRadio1.checked = true
32 | Case "TPMKEY"
33 | BdeRadio2.checked = true
34 | BdeModeRadio2.checked = true
35 | If Property("BdeKeyLocation") <> "" then
36 | BdeModeSelect1.Value = ucase(Property("BdeKeyLocation"))
37 | ElseIf Property("OSDBitLockerStartupKeyDrive") <> "" then
38 | BdeModeSelect1.Value = ucase(Property("OSDBitLockerStartupKeyDrive"))
39 | End if
40 | Case "KEY"
41 | BdeRadio2.checked = true
42 | BdeModeRadio3.checked = true
43 | If Property("BdeKeyLocation") <> "" then
44 | BdeModeSelect2.Value = ucase(Property("BdeKeyLocation"))
45 | ElseIf Property("OSDBitLockerStartupKeyDrive") <> "" then
46 | BdeModeSelect2.Value = ucase(Property("OSDBitLockerStartupKeyDrive"))
47 | End if
48 | Case "TPMPIN"
49 | BdeRadio2.checked = true
50 | BdeModeRadio4.checked = true
51 | Case Else
52 | BdeRadio1.Checked = true
53 | End Select
54 |
55 | If UCase(Property("BdeRecoveryKey")) = "AD" or UCase(Property("OSDBitLockerCreateRecoveryPassword")) = "AD" Then
56 | ADButton1.checked = True
57 | Else
58 | ADButton2.Checked = True
59 | End if
60 |
61 | WaitForEncryption.checked = ucase(Property("OSDBitLockerWaitForEncryption")) = "TRUE" or ucase(Property("BdeWaitForEncryption")) = "TRUE"
62 |
63 | BdeInstallSuppress.value = "YES"
64 | End Function
65 |
66 |
67 |
68 | Function ValidateBDE
69 |
70 | Dim regEx
71 |
72 |
73 |
74 | ' Enable and disable
75 |
76 | If BDERadio2.checked then
77 |
78 | ' Enable second set of radio buttons
79 |
80 | BdeModeRadio1.disabled = false
81 | BdeModeRadio2.disabled = false
82 | BdeModeRadio3.disabled = false
83 | BdeModeRadio4.disabled = false
84 |
85 | BdePin.disabled = false
86 | ADButton1.disabled = false
87 | ADButton2.disabled = false
88 |
89 | WaitForEncryption.disabled = false
90 | Else
91 |
92 | ' Disable second set of radio buttons
93 |
94 | BdeModeRadio1.disabled = true
95 | BdeModeRadio2.disabled = true
96 | BdeModeRadio3.disabled = true
97 | BdeModeRadio4.disabled = true
98 |
99 |
100 | BdeModeSelect1.disabled = true
101 | BdeModeSelect2.disabled = true
102 |
103 | BdePin.disabled = true
104 |
105 | ADButton1.disabled = true
106 | ADButton2.disabled = true
107 |
108 | WaitForEncryption.disabled = true
109 | End if
110 |
111 |
112 |
113 |
114 | ' Set BdeInstall based on choices
115 |
116 | If BDERadio2.checked then
117 | BdeInstallSuppress.value = "NO"
118 |
119 | ' Mode/location
120 | If BdeModeRadio1.checked then
121 | BdeInstall.value = "TPM"
122 | BdePin.disabled = true
123 | ElseIf BdeModeRadio2.checked then
124 | BdeInstall.value = "TPMKey"
125 | OSDBitLockerStartupKeyDrive.value = BdeModeSelect1.Value
126 | BdeModeSelect1.disabled = false
127 | BdeModeSelect2.disabled = true
128 | BdePin.disabled = true
129 | ElseIf BdeModeRadio3.checked then
130 | BdeInstall.value = "Key"
131 | OSDBitLockerStartupKeyDrive.value = BdeModeSelect2.Value
132 | BdeModeSelect1.disabled = true
133 | BdeModeSelect2.disabled = false
134 | BdePin.disabled = true
135 | Else
136 | BdeInstall.value = "TPMPin"
137 | BdeModeSelect1.disabled = true
138 | BdeModeSelect2.disabled = true
139 | BdePin.disabled = false
140 | End if
141 |
142 |
143 | If ADButton1.checked Then
144 | BdeRecoveryKey.value = "AD"
145 | Else
146 | BdeRecoveryKey.value = ""
147 | End if
148 |
149 | OSDBitLockerWaitForEncryption.value = WaitForEncryption.checked
150 |
151 | Else ' IF BDERadio1.Checked then
152 |
153 | BdeInstall.value = ""
154 | BdeInstallSuppress.value = "YES"
155 |
156 | End if
157 |
158 | ValidateKey
159 |
160 | ' Scan required fields
161 |
162 | ValidateBDE = ParseAllWarningLabels
163 |
164 | End Function
165 |
166 | Function ValidateKey
167 |
168 | InvalidKey.style.display = "none"
169 | ValidateKey = TRUE
170 |
171 | If not BdeModeRadio4.Checked or not BDERadio2.Checked then
172 | BdePin.value = ""
173 | Exit Function
174 | End if
175 |
176 | If len(BdePin.value) = 0 Then
177 |
178 | InvalidKey.innerText = "* Required (MISSING)"
179 | InvalidKey.style.display = "inline"
180 | ValidateKey = FALSE
181 |
182 | ElseIf Not IsEmpty(oEnvironment.item("BDEPinMinLength")) And isNumeric(oEnvironment.item("BDEPinMinLength")) then
183 |
184 | if len(BdePin.value) < cLng(oEnvironment.item("BDEPinMinLength")) then
185 | InvalidKey.innerText = "* Pin must be " & oEnvironment.item("BDEPinMinLength") & " charaters or longer"
186 | InvalidKey.style.display = "inline"
187 | ValidateKey = FALSE
188 | End if
189 |
190 | ElseIf (oEnvironment.item("BDEAllowAlphaNumericPin") <> UCase("YES")) and Not IsNumeric(BdePin.value) then
191 |
192 | InvalidKey.innerText = "* Pin must be numeric"
193 | InvalidKey.style.display = "inline"
194 | ValidateKey = FALSE
195 |
196 | End if
197 |
198 | End Function
199 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_CaptureImage.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Initialization.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Initialization routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 |
19 | Function InitializeCapture
20 |
21 | If Ucase(Property("ComputerBackupLocation")) = "NETWORK" OR Ucase(oEnvironment.Item("ComputerBackupLocation")) = "NETWORK" Then
22 | If Property("BackupShare") <> ""AND Property("BackupDir") <> "" Then
23 | ComputerBackupLocation.value = Property("BackupShare") & "\" & Property("BackupDir")
24 | ElseIF oEnvironment.Item("BackupShare") <> "" AND oEnvironment.Item("BackupDir") <> "" Then
25 | ComputerBackupLocation.value = oEnvironment.Item("BackupShare") & "\" & oENvironment.Item("BackupDir")
26 | Else
27 | ComputerBackupLocation.value = Property("DeployRoot") & "\Captures"
28 | End If
29 | End If
30 | If Property("ComputerBackupLocation") = "" then
31 | ComputerBackupLocation.value = Property("DeployRoot") & "\Captures"
32 | End if
33 | If Property("BackupFile") = "" then
34 | BackupFile.value = Property("TaskSequenceID") & ".wim"
35 | End if
36 |
37 | RMPropIfFound("BdePin")
38 | RMPropIfFound("BdeModeSelect1")
39 | RMPropIfFound("BdeModeSelect2")
40 | RMPropIfFound("BdeKeyLocation")
41 | RMPropIfFound("OSDBitLockerWaitForEncryption")
42 | RMPropIfFound("BdeRecoveryKey")
43 | RMPropIfFound("BdeRecoveryPassword")
44 | RMPropIfFound("BdeInstallSuppress")
45 |
46 |
47 | End Function
48 |
49 |
50 |
51 | '''''''''''''''''''''''''''''''''''''
52 | ' Validate Capture
53 | '
54 |
55 | Function ValidateCaptureLocation
56 |
57 | InvalidCaptureLocation.style.display = "none"
58 | ValidateCaptureLocation = true
59 |
60 | If not CaptureRadio1.Checked then
61 | ComputerBackupLocation.value = ""
62 | BackupFile.Value = ""
63 | RMPropIfFound("ComputerBackupLocation")
64 | RMPropIfFound("BackupFile")
65 | Exit Function
66 | End if
67 |
68 | If Left(ComputerBackupLocation.value, 2) = "\\" and len(ComputerBackupLocation.value) > 6 and ubound(split(ComputerBackupLocation.value,"\")) >= 3 then
69 |
70 | If not oUtility.ValidateConnection(ComputerBackupLocation.value) = Success then
71 | InvalidCaptureLocation.style.display = "inline"
72 | ValidateCaptureLocation = FALSE
73 | End if
74 |
75 | Else
76 | InvalidCaptureLocation.style.display = "inline"
77 | ValidateCaptureLocation = FALSE
78 | End if
79 |
80 | End Function
81 |
82 | Function ValidateCapture
83 |
84 | document.GetElementByID("ComputerBackupLocation").Disabled = not CaptureRadio1.Checked
85 | document.GetElementByID("BackupFile").Disabled = not CaptureRadio1.Checked
86 |
87 | if not CaptureRadio4.Checked then
88 |
89 | RMPropIfFound("BdeInstall")
90 | RMPropIfFound("BdeInstallSuppress")
91 |
92 | End if
93 |
94 | ValidateCapture = ParseAllWarningLabels
95 |
96 | End Function
97 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_CaptureImage.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_CaptureImage.vbs
23 |
24 |
25 |
26 |
27 | Specify whether to capture an image.
29 |
101 | ]]>
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Computer.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/DeployWiz_Computer.png
--------------------------------------------------------------------------------
/Scripts/DeployWiz_ComputerBackup.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Initialization.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Initialization routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 |
19 | Function InitializeComputerBackupLocation
20 |
21 | ' We muck around with the values, so we need to do some manual cleanup
22 |
23 | If Ucase(property("DeploymentType")) = "REPLACE" then
24 |
25 | CBRadio1.Disabled = TRUE
26 | AllowLocal.Checked = FALSE
27 |
28 | If UCase(property("ComputerBackupLocation")) = "NONE" or Ucase(oEnvironment.Item("ComputerBackupLocation")) = "NONE" then
29 | CBRadio3.click
30 |
31 | Else
32 | CBRadio2.click
33 | If UCase(property("ComputerBackupLocation")) <> "NETWORK" then
34 | DataPath.Value = property("ComputerBackupLocation")
35 | End if
36 |
37 | End if
38 |
39 | ElseIf UCase(property("ComputerBackupLocation")) = "" then
40 |
41 | If Property("BackupShare") <> ""AND Property("BackupDir") <> "" Then
42 | DataPath.value = Property("BackupShare") & "\" & Property("BackupDir")
43 | CBRadio2.click
44 | End If
45 |
46 | ElseIf UCase(property("ComputerBackupLocation")) = "AUTO" or Ucase(oEnvironment.Item("ComputerBackupLocation")) = "AUTO" then
47 | AllowLocal.Checked = TRUE
48 | CBRadio1.click
49 |
50 | ElseIf UCase(property("ComputerBackupLocation")) = "NONE" or Ucase(oEnvironment.Item("ComputerBackupLocation")) = "NONE" then
51 | CBRadio3.click
52 |
53 | ElseIf UCase(property("ComputerBackupLocation")) = "NETWORK" or Ucase(oEnvironment.Item("ComputerBackupLocation")) = "NETWORK" then
54 | CBRadio1.Disabled = TRUE
55 | AllowLocal.Checked = FALSE
56 | CBRadio2.click
57 | If Property("BackupShare") <> ""AND Property("BackupDir") <> "" Then
58 | DataPath.value = Property("BackupShare") & "\" & Property("BackupDir")
59 | End if
60 |
61 | Else
62 | DataPath.Value = property("ComputerBackupLocation")
63 | CBRadio2.click
64 | End if
65 |
66 | ValidateComputerBackupLocation
67 |
68 | End function
69 |
70 |
71 |
72 |
73 | '''''''''''''''''''''''''''''''''''''
74 | ' Validate Computer Backup Location
75 | '
76 |
77 | Function ValidateComputerBackupLocation
78 | Dim HasErrors
79 |
80 | HasErrors = FALSE
81 | document.GetElementByID("CBRadio2").Value = document.GetElementByID("DataPath").Value
82 |
83 | document.GetElementByID("AllowLocal").Disabled = not CBRadio1.Checked
84 |
85 | document.GetElementByID("DataPath").Disabled = not CBRadio2.Checked
86 | document.GetElementByID("DataPathBrowse").Disabled = not CBRadio2.Checked
87 |
88 | ValidateComputerBackupLocation = ParseAllWarningLabels
89 |
90 | End Function
91 |
92 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_ComputerBackup.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_ComputerBackup.vbs
23 |
24 |
25 |
26 | Укажите путь, куда сохранить полный бэкап компьютера.
28 |
85 | ]]>
86 |
87 |
88 |
89 |
90 |
91 |
92 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_ComputerName.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_ComputerName.vbs
23 |
24 |
25 |
26 |
27 |
30 |
31 |
32 |
33 |
34 | Имя компьют ера:
35 |
36 |
37 | * Заполнение обязательно
38 | Не верные символы!
39 | Максимум 15 символов!
40 |
41 |
42 |
43 |
44 |
149 |
150 | ]]>
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Credentials.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/DeployWiz_Credentials.png
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Credentials.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Validation.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Validation routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 | Option Explicit
16 |
17 |
18 | Dim UserID_isDirty
19 | UserID_isDirty = FALSE
20 |
21 | Function ValidateCredentials
22 |
23 | UserID_isDirty = TRUE
24 | ValidateCredentials = ParseAllWarningLabelsEx(userdomain, username )
25 |
26 | End Function
27 |
28 | Function ValidateCredentialsEx
29 | Dim r
30 |
31 | ValidateCredentialsEx = ValidateCredentials
32 |
33 | InvalidCredentials.style.display = "none"
34 |
35 | If ValidateCredentialsEx and oEnvironment.Item("OSVersion") <> "WinPE" then
36 |
37 | ' Check using ADSI (not possible in Windows PE)
38 |
39 | r = CheckCredentials("", username.value, userdomain.value, userpassword.value)
40 | If r <> TRUE then
41 |
42 | InvalidCredentials.innerText = "* Invalid credentials: " & r
43 | InvalidCredentials.style.display = "inline"
44 | ValidateCredentialsEx = false
45 |
46 | End if
47 |
48 |
49 | End if
50 |
51 | End function
52 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Credentials.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_Credentials.vbs
23 |
24 |
25 |
26 |
27 | Specify credentials for connecting to network shares.
30 |
31 |
32 |
52 | * Invalid credentials
53 |
54 | ]]>
55 |
56 |
57 |
58 |
59 |
60 |
61 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Language.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/DeployWiz_Language.png
--------------------------------------------------------------------------------
/Scripts/DeployWiz_LanguagePack.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_LanguagePack.vbs
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
34 | Select the language packs to install.
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 | ]]>
47 |
48 |
49 |
50 |
51 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Network.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/DeployWiz_Network.png
--------------------------------------------------------------------------------
/Scripts/DeployWiz_OfflineData.vbs:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/DeployWiz_OfflineData.vbs
--------------------------------------------------------------------------------
/Scripts/DeployWiz_OfflineData.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_OfflineData.vbs
23 |
24 |
25 |
26 |
27 | Переместить данные и настройки из предыдущей установки Windows?
29 |
87 |
88 |
89 |
90 |
91 |
92 |
93 | Select "Do not restore user data and settings. " to delete the contents of Hard Disk 0, including all files and partitions.
94 |
95 |
96 |
97 |
98 | ]]>
99 |
100 |
101 |
102 |
103 |
104 |
105 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_ProductKeyVista.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Initialization.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Initialization routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 |
19 | Function InitializeProductKey
20 |
21 | ' Figure out how to initialize the pane.
22 |
23 | If Property("ProductKey") <> "" or Left(Property("ImageBuild"), 1) < "6" then
24 | locProductKey.disabled = false
25 | locProductKey.value = Property("ProductKey")
26 | ProductKey.value = locProductKey.value
27 | If Left(Property("ImageBuild"), 1) >= "6" then
28 | PKRadio3.click
29 | locOverrideProductKey.disabled = true
30 | OverrideProductKey.value = ""
31 | End if
32 | ElseIf Property("OverrideProductKey") <> "" then
33 | PKRadio2.click
34 | locOverrideProductKey.disabled = false
35 | locProductKey.disabled = true
36 | locOverrideProductKey.value = Property("OverrideProductKey")
37 | OverrideProductKey.value = locOverrideProductKey.value
38 | ProductKey.value = ""
39 | Else
40 | PKRadio1.click
41 | locOverrideProductKey.disabled = true
42 | locProductKey.disabled = true
43 | ProductKey.value = ""
44 | OverrideProductKey.value = ""
45 | End if
46 |
47 | End Function
48 |
49 | Function ValidateProductKey
50 |
51 | ValidateProductKey = False
52 |
53 | If Left(Property("ImageBuild"), 1) < "6" then
54 |
55 | ' Make sure the product key is valid
56 |
57 | If locProductKey.value = "" then
58 | PKBlank.style.display = "inline"
59 | PKInvalid.style.display = "none"
60 | ElseIf IsEmpty(GetProductKey(locProductKey.value)) then
61 | PKBlank.style.display = "none"
62 | PKInvalid.style.display = "inline"
63 | Else
64 | PKBlank.style.display = "none"
65 | PKInvalid.style.display = "none"
66 | ProductKey.value = GetProductKey(locProductKey.value)
67 | ValidateProductKey = True
68 | End if
69 |
70 | ElseIf PKRadio1.checked then
71 |
72 | locOverrideProductKey.disabled = true
73 | locProductKey.disabled = true
74 |
75 | OverrideBlank.style.display = "none"
76 | OverrideInvalid.style.display = "none"
77 | PKBlank.style.display = "none"
78 | PKInvalid.style.display = "none"
79 |
80 | ProductKey.value = ""
81 | OverrideProductKey.value = ""
82 |
83 | ValidateProductKey = True
84 |
85 |
86 | ElseIf PKRadio2.checked then
87 |
88 | locOverrideProductKey.disabled = false
89 | locProductKey.disabled = true
90 |
91 | PKBlank.style.display = "none"
92 | PKInvalid.style.display = "none"
93 |
94 |
95 | ' Make sure the MAK key is valid
96 |
97 | If locOverrideProductKey.value = "" then
98 | OverrideBlank.style.display = "inline"
99 | OverrideInvalid.style.display = "none"
100 | ElseIf IsEmpty(GetProductKey(locOverrideProductKey.value)) then
101 | OverrideBlank.style.display = "none"
102 | OverrideInvalid.style.display = "inline"
103 | Else
104 | OverrideBlank.style.display = "none"
105 | OverrideInvalid.style.display = "none"
106 | OverrideProductKey.value = GetProductKey(locOverrideProductKey.value)
107 | ProductKey.value = ""
108 | ValidateProductKey = True
109 | End if
110 |
111 | Else
112 |
113 | locOverrideProductKey.disabled = true
114 | locProductKey.disabled = false
115 |
116 | OverrideBlank.style.display = "none"
117 | OverrideInvalid.style.display = "none"
118 |
119 |
120 | ' Make sure the product key is valid
121 |
122 | If locProductKey.value = "" then
123 | PKBlank.style.display = "inline"
124 | PKInvalid.style.display = "none"
125 | ElseIf IsEmpty(GetProductKey(locProductKey.value)) then
126 | PKBlank.style.display = "none"
127 | PKInvalid.style.display = "inline"
128 | Else
129 | PKBlank.style.display = "none"
130 | PKInvalid.style.display = "none"
131 | ProductKey.value = GetProductKey(locProductKey.value)
132 | OverrideProductKey.value = ""
133 | ValidateProductKey = True
134 | End if
135 |
136 | End if
137 |
138 | End Function
139 |
140 |
141 | const PRODUCT_KEY_TEST = "([0-9A-Z]+)?[^0-9A-Z]*([0-9A-Z]{5})[^0-9A-Z]?([0-9A-Z]{5})[^0-9A-Z]?([0-9A-Z]{5})[^0-9A-Z]?([0-9A-Z]{5})[^0-9A-Z]?([0-9A-Z]{5})[^0-9A-Z]*([0-9A-Z]+)?" '
142 |
143 |
144 | Function GetProductKey( pk )
145 |
146 | Dim regEx, match
147 |
148 | Set regEx = New RegExp
149 | regEx.Pattern = PRODUCT_KEY_TEST
150 | regex.IgnoreCase = TRUE
151 |
152 | For each match in regEx.Execute( UCase(pk) )
153 | If IsEmpty(match.SubMatches(0)) and IsEmpty(match.SubMatches(6)) then
154 | GetProductKey = ucase( match.SubMatches(1) & "-" & match.SubMatches(2) & "-" & _
155 | match.SubMatches(3) & "-" & match.SubMatches(4) & "-" & match.SubMatches(5) )
156 | End if
157 | Exit function
158 | Next
159 |
160 | End function
161 |
162 |
163 | Function AssignProductKey
164 |
165 | If not IsEmpty(GetProductKey(locProductKey.value)) then
166 | locProductKey.value = GetProductKey(locProductKey.value)
167 | End if
168 | If Left(Property("ImageBuild"), 1) >= "6" then
169 | If not IsEmpty(GetProductKey(locOverrideProductKey.value)) then
170 | locOverrideProductKey.value = GetProductKey(locOverrideProductKey.value)
171 | End if
172 | End if
173 |
174 | End Function
175 |
176 |
177 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_ProductKeyVista.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_ProductKeyVista.vbs
23 |
24 |
25 |
26 |
27 | Specify the product key needed to install this operating system.
29 |
87 |
88 |
89 |
90 |
91 | ]]>
92 |
93 |
94 |
95 |
96 |
97 |
98 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Ready.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Initialization.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Initialization routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 | '
19 | ' Will return a dictionary object containing all Friendly Names Given a GUID as string, this funtion will search all *.xml files in the deployroot for a match.
20 | '
21 | Function GetFriendlyNamesofGUIDs
22 |
23 | Dim oFiles
24 | Dim oFolder
25 | Dim oXMLFile
26 | Dim oXMLNode
27 | Dim sName
28 | Dim GuidList
29 |
30 | Set GuidList = CreateObject("Scripting.Dictionary")
31 | GuidList.CompareMode = vbTextCompare
32 |
33 | Set oFolder = oFSO.GetFolder( oEnvironment.Item("DeployRoot") & "\control" )
34 | If oFolder is nothing then
35 | oLogging.CreateEntry oUtility.ScriptName & " Unable to find DeployRoot!", LogTypeError
36 | Exit function
37 | End if
38 |
39 | For each oFiles in oFolder.Files
40 |
41 | If UCase(right(oFIles.Name, 4)) = ".XML" then
42 | Set oXMLFile = oUtility.CreateXMLDOMObjectEx( oFiles.Path )
43 | If not oXMLFile is nothing then
44 |
45 | for each oXMLNode in oXMLFile.selectNodes("//*/*[@guid]")
46 |
47 | if not oXMLNode.selectSingleNode("./Name") is nothing then
48 | sName = oUtility.SelectSingleNodeString(oXMLNode,"./Name")
49 |
50 | if not oXMLNode.selectSingleNode("./Language") is nothing then
51 | if oUtility.SelectSingleNodeString(oXMLNode,"./Language") <> "" then
52 | sName = sName & " ( " & oUtility.SelectSingleNodeString(oXMLNode,"./Language") & " )"
53 | end if
54 | end if
55 |
56 | if not oXMLNode.Attributes.getNamedItem("guid") is nothing then
57 | if oXMLNode.Attributes.getNamedItem("guid").value <> "" and sName <> "" then
58 | if not GuidList.Exists(oXMLNode.Attributes.getNamedItem("guid").value) then
59 | GuidList.Add oXMLNode.Attributes.getNamedItem("guid").value, sName
60 | end if
61 | end if
62 | end if
63 | end if
64 |
65 | next
66 |
67 | End if
68 | End if
69 |
70 | Next
71 |
72 | set GetFriendlyNamesofGUIDs = GuidList
73 | End function
74 |
75 |
76 | Function PrepareFinalScreen
77 |
78 | Dim GuidList
79 | Dim p, i, item, Buffer
80 |
81 | set GuidList = GetFriendlyNamesofGUIDs
82 |
83 | Dim re, Match
84 |
85 | For each p in oProperties.Keys
86 |
87 | If IsObject(oProperties(p)) or IsArray(oProperties(p)) then
88 | i = 1
89 | For each item in oProperties(p)
90 | If Item <> "" then
91 | oStrings.AddToList Buffer, p & i & " = """ & item & """", vbNewLine
92 | i = i + 1
93 | End if
94 |
95 | next
96 | ElseIf ucase(p) = "DEFAULTDESTINATIONDISK" then
97 | ' Skip...
98 | ElseIf ucase(p) = "DEFAULTDESTINATIONPARTITION" then
99 | ' Skip...
100 | ElseIf ucase(p) = "DEFAULTDESTINATIONISDIRTY" then
101 | ' Skip...
102 | ElseIf ucase(p) = "KEYBOARDLOCALE_EDIT" then
103 | ' Skip...
104 | ElseIf ucase(p) = "USERLOCALE_EDIT" then
105 | ' Skip...
106 | ElseIf oProperties(p) = "" then
107 | ' Skip...
108 | ElseIf Instr(1, p, "Password" , vbTextCompare ) <> 0 then
109 | oStrings.AddToList Buffer, p & " = ""***********""", vbNewLine
110 | else
111 | oStrings.AddToList Buffer, p & " = """ & oProperties(p) & """", vbNewLine
112 | end if
113 | Next
114 |
115 | '
116 | ' Given a text string containing GUID ID's of configuration entries on the deployment share
117 | ' This function will search/replace all GUID's within the text blob.
118 | '
119 | Set re = new regexp
120 | re.IgnoreCase = True
121 | re.Global = True
122 | re.Pattern = "\{[A-F0-9]{8}\-[A-F0-9]{4}\-[A-F0-9]{4}\-[A-F0-9]{4}\-[A-F0-9]{12}\}"
123 |
124 | On error resume next
125 | Do while re.Test( Buffer )
126 | For each Match in re.execute(Buffer)
127 | Buffer = mid(Buffer,1,Match.FirstIndex) & _
128 | GuidList.Item(Match.Value) & _
129 | mid(Buffer,Match.FirstIndex+match.Length+1)
130 | Exit for
131 | Next
132 | Loop
133 | On error goto 0
134 |
135 | optionalWindow1.InnerText = Buffer
136 |
137 | End function
138 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Ready.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_Ready.vbs
23 |
24 |
25 |
26 |
27 | Beg in]]>
28 |
29 |
30 | Ready to begin.
32 | Using the information you provided, the deployment can now begin.
33 |
34 |
35 |
36 | Details ...
37 | Details Here!
38 |
39 |
40 | ]]>
41 |
42 |
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Roles.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_Roles.vbs
23 |
24 |
25 |
26 | Select the operating system roles to install on this computer.
29 | The following roles and role services are available.
30 |
31 |
32 | Select A ll
33 | Sel ect None
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 | ]]>
45 |
46 |
47 |
48 |
49 |
50 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Roles.xsl:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 | .
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_SelectTS.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_SelectTS.vbs
23 |
24 |
25 |
26 | "YES" ]]>
27 |
28 | Выберите задачу для выполнения.
30 | Ошибочная задача (Отсутствует О.С.)
31 |
32 |
33 | Нет доступных задач (Файл TaskSequences.xml не существует, пуст или недоступен)
34 |
35 |
36 |
37 |
38 | ]]>
39 |
40 |
41 |
42 |
43 |
44 |
45 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_TimeZone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/DeployWiz_TimeZone.png
--------------------------------------------------------------------------------
/Scripts/DeployWiz_UserData.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Initialization.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Initialization routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 |
19 | Function InitializeUserDataLocation
20 |
21 | ' We muck around with the values, so we need to do some manual cleanup
22 |
23 | If UCase(property("UserDataLocation")) = "" or UCase(property("UserDataLocation")) = "AUTO" then
24 | AllowLocal.Checked = TRUE
25 | UDRadio1.click
26 | UDRadio1.value = "AUTO"
27 |
28 | ElseIf UCase(property("UserDataLocation")) = "NONE" then
29 | UDRadio3.click
30 |
31 | ElseIf UCase(property("UserDataLocation")) = "NETWORK" then
32 | AllowLocal.Checked = FALSE
33 | UDRadio2.click
34 | UDRadio2.value = "NETWORK"
35 |
36 | Else
37 | DataPath.Value = property("UserDataLocation")
38 | UDRadio2.click
39 | End if
40 |
41 |
42 | If property("DeploymentType") = "REPLACE" then
43 |
44 | If UDRadio3.Checked then
45 | UDRadio2.Click
46 | End if
47 | UDRadio3.Disabled = TRUE
48 |
49 | End if
50 |
51 | If property("UDShare") = "" and property("DeploymentType") <> "REFRESH" then
52 |
53 | If UDRadio1.Checked then
54 | UDRadio2.Click
55 | End if
56 | UDRadio1.Disabled = TRUE
57 |
58 | End if
59 |
60 | if not isempty("UDShare") then
61 | DataPathT.Value = Property("UUID")
62 | End if
63 |
64 | ValidateUserDataLocation
65 |
66 | End function
67 |
68 |
69 | '''''''''''''''''''''''''''''''''''''
70 | ' Validate UserData Location
71 | '
72 |
73 | Function ValidateUserDataLocation
74 |
75 | Dim USMTTagFile
76 | InvalidPath.style.display = "none"
77 |
78 | DataPath.Value = property("UDShare")+"\"+DataPathT.Value
79 |
80 | UDRadio2.Value = DataPath.Value
81 | AllowLocal.Disabled = not UDRadio1.Checked
82 | document.GetElementByID("DataPathT").Disabled = not UDRadio2.Checked
83 | document.GetElementByID("DataPathBrowse").Disabled = not UDRadio2.Checked
84 |
85 | ValidateUserDataLocation = ParseAllWarningLabels
86 |
87 | If UDRadio2.Checked then
88 | 'If local Path (USB or other drive) is specified tag the drive
89 | If Mid(DataPath.Value, 2,1) = ":" Then
90 | On Error Resume Next
91 | Set USMTTagFile = OFSO.CreateTextFile(Left(DataPath.Value, 2) & "\UserState.tag", true)
92 | If Err Then
93 | InvalidPath.style.display = "inline"
94 | ValidateUserDateLocation = False
95 | Exit Function
96 | End If
97 | USMTTagFile.Close
98 | End If
99 |
100 | End if
101 |
102 | End Function
103 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_UserData.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_UserData.vbs
23 |
24 |
25 |
26 |
27 | Выберите, где сохранить данные и настройки.
29 |
88 | ]]>
89 |
90 |
91 |
92 |
93 |
94 |
95 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_UserDataRestore.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Initialization.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Initialization routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 |
19 | Function InitializeUserDataRestoreLocation
20 |
21 | ' If the user data location is AUTO or NETWORK, reset it to none for bare metal
22 |
23 | If UCase(Property("UserDataLocation")) = "AUTO" or UCase(Property("UserDataLocation")) = "NETWORK" then
24 | oProperties("UserDataLocation") = "NONE"
25 | End if
26 |
27 |
28 | ' Make sure the right radio button is set
29 |
30 | If UCase(Property("UserDataLocation")) = "NONE" OR Property("UserDataLocation") = "" then
31 | UDRadio1.click
32 | Else
33 | StatePath.value = Property("UserDataLocation")
34 | UDRadio2.click
35 | End if
36 |
37 | if not isempty("UDShare") then
38 | StatePathT.value = Property("UUID")
39 | UDRadio2.click
40 | End if
41 |
42 | End Function
43 |
44 |
45 | '''''''''''''''''''''''''''''''''''''
46 | ' Validate UserData Location
47 | '''''''''''''''''''''''''''''''''''''
48 |
49 | Function ValidateUserDataRestoreLocation
50 |
51 | StatePath.value = Property("UDShare")+"\"+StatePathT.value
52 |
53 | UDRadio2.Value = StatePath.Value
54 |
55 | document.GetElementByID("StatePathT").Disabled = not UDRadio2.Checked
56 | document.GetElementByID("StatePathBrowse").Disabled = not UDRadio2.Checked
57 |
58 | InvalidPath.style.display = "none"
59 | ValidateUserDataRestoreLocation = TRUE
60 | If UDRadio2.Checked and StatePath.value <> "" then
61 |
62 | If Left(StatePath.value, 2) = "\\" and len(StatePath.value) > 6 and ubound(split(StatePath.value,"\")) >= 3 then
63 | oUtility.ValidateConnection StatePath.value
64 | End if
65 |
66 | If (oFSO.FileExists(StatePath.value & "\USMT3.MIG" ) or oFSO.FileExists(StatePath.value & "\USMT.MIG" )) or ( oFSO.FileExists(StatePath.value & "\MIGSTATE.DAT" ) and _
67 | oFSO.FileExists(StatePath.value & "\catalog.mig" ) ) then
68 |
69 | ' Just in case the user selects the USMT3 directory.
70 | StatePath.value = StatePath.value & "\.."
71 |
72 | End if
73 |
74 | If not (oFSO.FolderExists(StatePath.value & "\USMT3" ) or oFSO.FolderExists(StatePath.value & "\USMT" )) then
75 | ValidateUserDataRestoreLocation = FALSE
76 | InvalidPath.style.display = "inline"
77 | Elseif not (oFSO.FileExists(StatePath.value & "\USMT3\USMT3.MIG" ) or oFSO.FileExists(StatePath.value & "\USMT\USMT.MIG" )) and _
78 | not (oFSO.FileExists(StatePath.value & "\USMT3\MIGSTATE.DAT" ) or oFSO.FileExists(StatePath.value & "\USMT\MIGSTATE.DAT" )) and _
79 | not (oFSO.FileExists(StatePath.value & "\USMT3\catalog.mig" ) or oFSO.FileExists(StatePath.value & "\USMT\catalog.mig" )) then
80 |
81 | ValidateUserDataRestoreLocation = FALSE
82 | InvalidPath.style.display = "inline"
83 | End if
84 |
85 |
86 |
87 | End if
88 |
89 | ValidateUserDataRestoreLocation = ValidateUserDataRestoreLocation and ParseAllWarningLabels
90 |
91 | End Function
92 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_UserDataRestore.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 | DeployWiz_UserDataRestore.vbs
23 |
24 |
25 |
26 |
27 | Укажите действие с пользовательскими данными.
29 |
71 | ]]>
72 |
73 |
74 |
75 |
76 |
77 |
78 |
--------------------------------------------------------------------------------
/Scripts/DeployWiz_Validation.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: DeployWiz_Validation.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Main Client Deployment Wizard Validation routines
12 | ' //
13 | ' // ***************************************************************************
14 |
15 | Option Explicit
16 |
17 |
--------------------------------------------------------------------------------
/Scripts/Extend.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/Extend.png
--------------------------------------------------------------------------------
/Scripts/FolderIcon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/FolderIcon.png
--------------------------------------------------------------------------------
/Scripts/Format.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/Format.png
--------------------------------------------------------------------------------
/Scripts/GetCurrentTimeZoneExit.vbs:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/GetCurrentTimeZoneExit.vbs
--------------------------------------------------------------------------------
/Scripts/ItemIcon1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/ItemIcon1.png
--------------------------------------------------------------------------------
/Scripts/LTIBootstrap.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: LTIBootstrap.ini
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Invoke LiteTouch.wsf from the appropriate folder
12 | ' //
13 | ' // Usage: wscript LTIBootstrap.vbs
14 | ' //
15 | ' // ***************************************************************************
16 |
17 | '//----------------------------------------------------------------------------
18 | '//
19 | '// Global constant and variable declarations
20 | '//
21 | '//----------------------------------------------------------------------------
22 |
23 | Option Explicit
24 |
25 | Dim iRetVal
26 | Dim oShell
27 | Dim oFSO
28 | Dim oDrive
29 | Dim sCmd
30 | Dim bFound
31 |
32 |
33 | '//----------------------------------------------------------------------------
34 | '// Initialization
35 | '//----------------------------------------------------------------------------
36 |
37 | Set oShell = CreateObject("WScript.Shell")
38 | Set oFSO = CreateObject("Scripting.FileSystemObject")
39 |
40 |
41 | '//----------------------------------------------------------------------------
42 | '// Find LiteTouch.wsf and run it
43 | '//----------------------------------------------------------------------------
44 |
45 | bFound = false
46 | For Each oDrive in oFSO.Drives
47 | If oDrive.IsReady then
48 | If oFSO.FileExists(oDrive.DriveLetter & ":\MININT\Scripts\LiteTouch.wsf") then
49 | sCmd = "wscript.exe """ & oDrive.DriveLetter & ":\MININT\Scripts\LiteTouch.wsf"" /start"
50 | iRetVal = oShell.Run(sCmd, 1, true)
51 | bFound = true
52 | Exit For
53 | End if
54 | End if
55 | Next
56 |
57 |
58 | ' Make sure we ran something. If not, pop up an error
59 |
60 | If not bFound then
61 | oShell.Popup "Unable to find LiteTouch.wsf needed to continue the deployment.", 0, "Script not found", 48
62 | iRetVal = 9981
63 | End if
64 |
65 |
66 | ' Delete ourselves
67 |
68 | On Error Resume Next
69 | oFSO.DeleteFile Wscript.ScriptFullName, true
70 | On Error Goto 0
71 |
72 |
73 | ' All done
74 |
75 | WScript.Quit iRetVal
76 |
--------------------------------------------------------------------------------
/Scripts/LTICopyScripts.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
113 |
114 |
115 |
--------------------------------------------------------------------------------
/Scripts/LTIGetFolder.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
67 |
68 |
69 |
--------------------------------------------------------------------------------
/Scripts/LTIOEM.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
134 |
135 |
136 |
--------------------------------------------------------------------------------
/Scripts/LTISuspend.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
140 |
141 |
--------------------------------------------------------------------------------
/Scripts/LiteTouch.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: Litetouch.vbs
8 | ' //
9 | ' // Version: 6.0.2149.0
10 | ' //
11 | ' // Purpose: Start the lite touch deployment process
12 | ' //
13 | ' // Usage: cscript LiteTouch.vbs [/debug:true]
14 | ' //
15 | ' // ***************************************************************************
16 |
17 | '//----------------------------------------------------------------------------
18 | '//
19 | '// Global constant and variable declarations
20 | '//
21 | '//----------------------------------------------------------------------------
22 |
23 | Option Explicit
24 |
25 | Dim oShell
26 | Dim oFSO
27 | Dim iRetVal
28 | Dim sCmd
29 | Dim sScriptDir
30 | Dim sArg
31 | Dim sArgString
32 | Dim sArchitecture
33 | Dim oDrive
34 |
35 | '//----------------------------------------------------------------------------
36 | '// Initialization
37 | '//----------------------------------------------------------------------------
38 |
39 | Set oShell = CreateObject("WScript.Shell")
40 | Set oFSO = CreateObject("Scripting.FileSystemObject")
41 | sScriptDir = oFSO.GetParentFolderName(WScript.ScriptFullName)
42 | For each sArg in WScript.Arguments
43 | sArgString = sArgString & sArg & " "
44 | Next
45 |
46 |
47 | 'Change the Architecture type from amd64 to X64 for consistency
48 |
49 | sArchitecture = oShell.Environment("SYSTEM").Item("Processor_Architecture")
50 | if lcase(sArchitecture) = "amd64" then
51 | sArchitecture = "x64"
52 | end if
53 |
54 |
55 | ' Clean up any existing C:\MININT directory
56 |
57 | sArgString = " /CleanStart " & sArgString
58 |
59 | oShell.Environment("PROCESS")("SEE_MASK_NOZONECHECKS") = 1
60 |
61 |
62 | ' Clean up any remnants of a previous task sequence
63 |
64 | On Error Resume Next
65 | iRetVal = oShell.Run("reg.exe delete HKCR\Microsoft.SMS.TSEnvironment /f", 0, true)
66 | iRetVal = oShell.Run("reg.exe delete HKCR\Microsoft.SMS.TSEnvironment.1 /f", 0, true)
67 | iRetVal = oShell.Run("reg.exe delete HKCR\Microsoft.SMS.TSProgressUI /f", 0, true)
68 | On Error Goto 0
69 |
70 |
71 | '//----------------------------------------------------------------------------
72 | '// Check to see if the prereq's have been satisfied
73 | '//----------------------------------------------------------------------------
74 |
75 | sCmd = "cscript.exe """ & sScriptDir & "\ZTIPrereq.vbs"""
76 | iRetVal = oShell.Run(sCmd, 0, true)
77 | If iRetVal <> 0 then
78 | oShell.Popup "This computer does not meet the prerequisites for deploying a new operating system. (" & CStr(iRetVal) & ")", 0, "Prerequisite Error", 16
79 | WScript.Quit iRetVal
80 | End if
81 |
82 |
83 | '//----------------------------------------------------------------------------
84 | '// Launch LiteTouch.wsf to do the heavy lifting
85 | '//----------------------------------------------------------------------------
86 |
87 | sCmd = """" & sScriptDir & "\..\tools\" & sArchitecture & "\bddrun.exe"" wscript.exe """ & sScriptDir & "\LiteTouch.wsf"" " & sArgString
88 | iRetVal = oShell.Run(sCmd, 1, true)
89 |
90 |
91 | ' All done
92 |
93 | WScript.Quit iRetVal
94 |
--------------------------------------------------------------------------------
/Scripts/MinusIcon1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/MinusIcon1.png
--------------------------------------------------------------------------------
/Scripts/NavBar.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/NavBar.png
--------------------------------------------------------------------------------
/Scripts/OSDEndTime.vbs:
--------------------------------------------------------------------------------
1 | Option Explicit
2 |
3 | Dim oTSE
4 | Dim oWSH
5 |
6 | On Error Resume Next
7 |
8 | Set oTSE = CreateObject("Microsoft.SMS.TSEnvironment")
9 | Set oWSH = CreateObject("WScript.Shell")
10 |
11 | ' ||||||||||||||||||||||||||||||||||||||||||
12 | ' || Get UTC offset
13 | ' ||||||||||||||||||||||||||||||||||||||||||
14 | Dim timeBias
15 | Dim timeOffset
16 |
17 | timeOffset = "HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\TimeZoneInformation\ActiveTimeBias"
18 | timeBias = oWSH.RegRead(timeOffset)
19 |
20 | ' ||||||||||||||||||||||||||||||||||||||||||
21 | ' || Convert 'now' to UTC
22 | ' ||||||||||||||||||||||||||||||||||||||||||
23 | Dim timeNow
24 | Dim timeUTC
25 |
26 | timeNow = Now()
27 | timeUTC = DateAdd( "n", timeBias, timeNow)
28 |
29 | ' ||||||||||||||||||||||||||||||||||||||||||
30 | ' || Standardize for Branding / OSDResults
31 | ' ||||||||||||||||||||||||||||||||||||||||||
32 | Dim timeBranding
33 | timeBranding = Year(timeUTC) & "-" &_
34 | Right( "0" & Month(timeUTC), 2) & "-" &_
35 | Right( "0" & Day(timeUTC), 2) & " " &_
36 | Right( "0" & Hour(timeUTC), 2) & ":" &_
37 | Right( "0" & Minute(timeUTC), 2) & ":" &_
38 | Right( "0" & Second(timeUTC), 2) & "Z"
39 |
40 | 'wscript.echo " Current : [" & timeNow & "]"
41 | 'wscript.echo " UTC : [" & timeUTC & "]"
42 | 'wscript.echo " Branding : [" & timeBranding & "]"
43 |
44 | oTSE("OSDEndTime") = timeBranding
--------------------------------------------------------------------------------
/Scripts/OSDLocalAdmins.vbs:
--------------------------------------------------------------------------------
1 | ' //////////////////////////////////
2 | ' // OSD Local Admins
3 | ' //////////////////////////////////////////////////////////////////////////////////////////////////////
4 | ' 1. Script will parse the TS variable "OSDAddAdmin" for a semicolon separated list of accounts.
5 | ' 2. Script will find the local administrator group name.
6 | ' 3. Script will add each account to the local administrator group
7 | ' //////////////////////////////////////////////////////////////////////////////////////////////////////
8 |
9 |
10 | Dim AdminArray
11 | Dim AdminGroup
12 | Dim TSVarAdmins
13 |
14 | wscript.echo
15 | wscript.echo "-------------------------------------"
16 | wscript.echo " Initializing TS Environment"
17 | wscript.echo "-------------------------------------"
18 | wscript.echo
19 |
20 | SET TSEnv = CreateObject("Microsoft.SMS.TSEnvironment")
21 | TSVarAdmins = TSEnv("OSDAddAdmin")
22 |
23 | wscript.echo
24 | wscript.echo "-------------------------------------"
25 | wscript.echo " Finding Administrator Group Name"
26 | wscript.echo "-------------------------------------"
27 | wscript.echo
28 |
29 | Call GetAdminGroupName( AdminGroup )
30 |
31 | wscript.echo
32 | wscript.echo "-------------------------------------"
33 | wscript.echo " Parsing/Splitting Accounts"
34 | wscript.echo "-------------------------------------"
35 | wscript.echo
36 |
37 | AdminArray = Split(TSVarAdmins, ";")
38 |
39 | For i = LBound(AdminArray) To UBound(AdminArray)
40 | Call AddUserAdmin ( Trim(AdminArray(i)), AdminGroup )
41 | Next
42 |
43 | wscript.echo
44 | wscript.echo "-------------------------------------"
45 | wscript.echo " Script End"
46 | wscript.echo "-------------------------------------"
47 | wscript.echo
48 |
49 | wscript.Quit (0)
50 |
51 |
52 |
53 | '########################################
54 | ' Add Administrator
55 | '########################################
56 | Sub AddUserAdmin(theUser, theGroup)
57 |
58 | Dim oWSH
59 | Dim oEXE
60 | Dim exeLine
61 | Dim outLine
62 |
63 | exeLine = "net localgroup " & theGroup & " /add " & Chr(34) & theUser & Chr(34)
64 |
65 | wscript.echo
66 | wscript.echo "-------------------------------------"
67 | wscript.echo " Add Administrator"
68 | wscript.echo "-------------------------------------"
69 | wscript.echo " [CMDEXE]: " & exeLine
70 |
71 | Set oWSH = CreateObject("Wscript.Shell")
72 | Set oEXE = oWSH.Exec(exeLine)
73 |
74 | outLine = oEXE.StdOut.ReadAll
75 | wscript.echo " [STDOUT]: " & outLine
76 | outLine = oEXE.StdErr.ReadAll
77 | wscript.echo " [STDERR]: " & outLine
78 |
79 | End Sub
80 |
81 |
82 | '########################################
83 | ' Get Administrator Group Name
84 | ' May vary from region-to-region
85 | '########################################
86 | Sub GetAdminGroupName( ByRef outName )
87 | Dim oWMI
88 | Dim oQRY
89 |
90 | Set oWMI = GetObject("winmgmts:\\.\root\cimv2")
91 | Set oQRY = oWMI.ExecQuery ("Select * From Win32_Group Where LocalAccount = TRUE And SID = 'S-1-5-32-544'")
92 |
93 | For Each anAccount in oQRY
94 | outName = anAccount.Name
95 | wscript.echo "Group Name Found: [" & outName & "]"
96 | Next
97 |
98 | End Sub
99 |
100 |
101 |
--------------------------------------------------------------------------------
/Scripts/PlusIcon1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/PlusIcon1.png
--------------------------------------------------------------------------------
/Scripts/Refresh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/Refresh.png
--------------------------------------------------------------------------------
/Scripts/SelectItem.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/SelectItem.jpg
--------------------------------------------------------------------------------
/Scripts/SelectItem.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/SelectItem.png
--------------------------------------------------------------------------------
/Scripts/SharesBackup/quotas_backup.vbs:
--------------------------------------------------------------------------------
1 | Const ForReading = 1
2 | Const ForWriting = 2
3 | Const bWaitOnReturn = True
4 |
5 | Set oShell = CreateObject("WScript.Shell")
6 | SysDrive=oShell.ExpandEnvironmentStrings("%SystemDrive%")
7 | Set objFSO = CreateObject("Scripting.FileSystemObject")
8 | Set colDrives = objFSO.Drives
9 | Set objFileOut = objFSO.OpenTextFile(SysDrive & "\backedup_shares\quotas_delete.bat", ForWriting, True)
10 | 'Set objFileOut1 = objFSO.OpenTextFile(SysDrive & "\backedup_shares\drives_sn.list", ForWriting, True)
11 | objFileOut.Write("@echo off" & vbCrLf)
12 | objFileOut.Write("chcp 1251" & vbCrLf)
13 |
14 | quotasexist=0
15 |
16 | 'Получаем список квот
17 | oShell.run "cmd /c chcp 1251 & dirquota q l > """ & SysDrive & "\backedup_shares\all_quotas.txt""",0,bWaitOnReturn
18 |
19 | 'Если квоты есть, то будут выгружаться щаблоны и генерироваться командный файл для удаления квот
20 | Set objFileIn = objFSO.OpenTextFile(SysDrive & "\backedup_shares\all_quotas.txt", ForReading)
21 | Do Until objFileIn.AtEndOfStream
22 | tmpline = objFileIn.ReadLine
23 | If (Len(tmpline) > 0) Then
24 | If (InStr(tmpline, "Quota Path:") = 1) Then quota_path = LTrim(Right(tmpline, Len(tmpline) - Len("Quota Path:")))
25 | If quota_path <> "" Then
26 | quotasexist=1
27 | End If
28 | End If
29 | Loop
30 |
31 | If objFSO.FileExists(SysDrive & "\Windows\System32\dirquota.exe") And (quotasexist = 1) Then
32 | 'Экспортируем шаблоны
33 | oShell.run "dirquota template export /file:" & SysDrive & "\backedup_shares\quota_templates.xml",0,bWaitOnReturn
34 |
35 | 'Генерируем командный файл для удаления квот
36 | For Each objDrive in colDrives
37 | If objDrive.DriveType = 2 Then
38 | objFileOut.Write("dirquota quota delete /Path:" & objDrive.DriveLetter & ":\* /Quiet" & vbCrLf)
39 | 'objFileOut1.Write(objDrive.DriveLetter & ": " & objDrive.SerialNumber & vbCrLf)
40 | End If
41 | Next
42 | Else
43 | Set objFileQtemplates = objFSO.OpenTextFile(SysDrive & "\backedup_shares\quota_templates.xml", ForWriting, True)
44 | objFileQtemplates.Close
45 | End If
46 |
47 | objFileOut.Close
48 | objFileIn.Close
49 | 'objFileOut1.Close
50 |
51 | 'Меняем кодировку файла с шаблонами с UCS-2 LE (UTF-16) на UTF-8
52 | ChangeCodepage SysDrive & "\backedup_shares\quota_templates.xml", "UTF-16LE", "UTF-8"
53 |
54 | 'Меняем версию базы в файле шаблонов, если сейчас указана версия 1.0
55 | Set objFileACL = objFSO.OpenTextFile(SysDrive & "\backedup_shares\quota_templates.xml", ForReading)
56 | strText = objFileACL.ReadAll
57 | objFileACL.Close
58 | strNewText = Replace(strText, "", "")
59 | Set objFileACL = objFSO.OpenTextFile(SysDrive & "\backedup_shares\quota_templates.xml", ForWriting)
60 | objFileACL.Write strNewText
61 | objFileACL.Close
62 |
63 | 'Меняем кодировку файла с шаблонами с UTF-8 на UCS-2 LE (UTF-16)
64 | ChangeCodepage SysDrive & "\backedup_shares\quota_templates.xml", "UTF-8", "UTF-16LE"
65 |
66 | Function ChangeCodepage(ByVal FileName, ByVal FromCP, ByVal ToCP)
67 | Set ADODBStream = CreateObject("ADODB.Stream")
68 | ADODBStream.Type = 2
69 | ADODBStream.Charset = FromCP
70 | ADODBStream.Open()
71 | ADODBStream.LoadFromFile(FileName)
72 | Text = ADODBStream.ReadText()
73 | ADODBStream.Close()
74 | ADODBStream.Charset = ToCP
75 | ADODBStream.Open()
76 | ADODBStream.WriteText(Text)
77 | ADODBStream.SaveToFile FileName, 2
78 | ADODBStream.Close()
79 | End Function
80 |
--------------------------------------------------------------------------------
/Scripts/SharesBackup/quotas_restore.vbs:
--------------------------------------------------------------------------------
1 | Const ForReading = 1
2 | Const ForWriting = 2
3 | Const bWaitOnReturn = True
4 |
5 | Set oShell = CreateObject("WScript.Shell")
6 | SysDrive=oShell.ExpandEnvironmentStrings("%SystemDrive%")
7 | Set objFSO = CreateObject("Scripting.FileSystemObject")
8 | Set colDrives = objFSO.Drives
9 | Set objFileIn = objFSO.OpenTextFile(SysDrive & "\backedup_shares\all_quotas.txt", ForReading)
10 | Set objFileOut = objFSO.OpenTextFile(SysDrive & "\backedup_shares\quotas_create.bat", ForWriting, True)
11 | Set filesize = objFSO.GetFile(SysDrive & "\backedup_shares\quota_templates.xml")
12 | objFileOut.Write("@echo off" & vbCrLf)
13 | objFileOut.Write("chcp 1251" & vbCrLf)
14 |
15 | Set objRegEx = CreateObject("VBScript.RegExp")
16 | objRegEx.Global = True
17 | objRegEx.IgnoreCase = True
18 | objRegEx.Pattern = "\((.*?)\)"
19 |
20 | Dim DrivesSNarray
21 |
22 | DrivesSNarray = FileToArray(SysDrive & "\backedup_shares\drives_sn.list", False)
23 |
24 | 'Импортируем шаблоны, если они были экспортированы ранее
25 | If filesize.size > 2 Then
26 | objFileOut.Write("dirquota template import /file:" & SysDrive & "\backedup_shares\quota_templates.xml /Overwrite" & vbCrLf)
27 | End If
28 |
29 | Do Until objFileIn.AtEndOfStream
30 | ProcessQuota()
31 | Loop
32 |
33 | objFileOut.Close
34 | objFileIn.Close
35 |
36 | Sub ProcessQuota()
37 |
38 | quota_path = ""
39 | quota_status = ""
40 | quota_limit = ""
41 | quota_type = ""
42 | source_template = ""
43 |
44 | Do Until objFileIn.AtEndOfStream Or ((Len(quota_path) > 0) And (Len(quota_status) > 0) And (Len(quota_limit) > 0))
45 | tmpline = objFileIn.ReadLine
46 | If (Len(tmpline) > 0) Then
47 | If (InStr(tmpline, "Quota Path:") = 1) Then quota_path = LTrim(Right(tmpline, Len(tmpline) - Len("Quota Path:")))
48 | If (InStr(tmpline, "Source Template:") = 1) Then source_template = LTrim(Right(tmpline, Len(tmpline) - Len("Source Template:")))
49 | If (InStr(tmpline, "Quota Status:") = 1) Then quota_status = LTrim(Right(tmpline, Len(tmpline) - Len("Quota Status:")))
50 | If (InStr(tmpline, "Limit:") = 1) Then quota_limit = LTrim(Right(tmpline, Len(tmpline) - Len("Limit:")))
51 | End If
52 | Loop
53 |
54 | If quota_path <> "" Then
55 |
56 | 'Удаляем "(Does not match template)" из имени шаблона, если он содержит эту надпись
57 |
58 | If (InStr(source_template, "(Does not match template)") <> 0) Then
59 | source_template = RTrim(Left(source_template, Len(source_template) - Len("(Does not match template)")))
60 | End If
61 |
62 | 'Удаляем "(Matches template)" из имени шаблона, если он содержит эту надпись
63 |
64 | If (InStr(source_template, "(Matches template)") <> 0) Then
65 | source_template = RTrim(Left(source_template, Len(source_template) - Len("(Matches template)")))
66 | End If
67 |
68 | 'Выдёргиваем тип квоты из строки с лимитом
69 | Set matches = objRegEx.Execute(quota_limit)
70 | count = matches.count
71 | For i = 0 To count - 1
72 | quota_type=matches(i).submatches(0)
73 | quota_limit = replace(left(quota_limit, Len(quota_limit) - Len(" (" & quota_type & ")"))," ","")
74 | Next
75 |
76 | 'Пересчитываем единицы измерения в единицы на порядок ниже, чтобы избавиться от разделителя в лимите
77 | delimpos = 0
78 | If (UCase(Right(quota_limit, 2)) = "GB") Then
79 | quota_limit = CStr(CLng(CDbl(Left(quota_limit, Len(quota_limit) - 2)) * 1024)) & "MB"
80 | ElseIf (UCase(Right(quota_limit, 2)) = "MB") Then
81 | quota_limit = CStr(CLng(CDbl(Left(quota_limit, Len(quota_limit) - 2)) * 1024)) & "KB"
82 | ElseIf (UCase(Right(quota_limit, 2)) = "KB") Then
83 | quota_limit = CStr(CLng(Left(quota_limit, Len(quota_limit) - 2))) & "KB"
84 | End If
85 |
86 | 'Проверяем, не изменилась ли буква системного диска и если изменилась - подставляем новую
87 | If (UCase(left(quota_path, 2)) = WScript.Arguments(0)) And (WScript.Arguments(0) <> SysDrive) Then
88 | quota_path = SysDrive & Right(quota_path, Len(quota_path) - Len("C:"))
89 | End If
90 |
91 | ' Проверяем, не изменилась ли буква диска после развёртывания
92 |
93 | drivesn = ""
94 | OldDrvLetter = Left(quota_path, 2)
95 |
96 | For Each rrtmpline in DrivesSNarray
97 | If (InStr(rrtmpline, OldDrvLetter) = 1) Then
98 | drivesn = Right(rrtmpline, Len(rrtmpline) - Len(OldDrvLetter & " "))
99 | End If
100 | Next
101 |
102 | If (Len(drivesn) > 0) Then
103 | For Each objDrive in colDrives
104 | If objDrive.DriveType = 2 Then
105 | If (CStr(objDrive.SerialNumber) = drivesn) And (objFSO.FolderExists(objDrive.DriveLetter & Right(quota_path, Len(quota_path) - 1))) Then
106 | quota_path = objDrive.DriveLetter & Right(quota_path, Len(quota_path) - 1)
107 | End If
108 | End If
109 | Next
110 | End If
111 |
112 | If source_template = "None" Then
113 | objFileOut.Write("dirquota quota add /Overwrite /Path:""" & quota_path & """ /Limit:" & quota_limit & " /Type:" & quota_type & " /Status:" & quota_status & "" & vbCrLf)
114 | Else 'Если квота была создана на основе шаблона, то используем его снова
115 | objFileOut.Write("dirquota quota add /Overwrite /Path:""" & quota_path & """ /Limit:" & quota_limit & " /Type:" & quota_type & " /Status:" & quota_status & " /SourceTemplate:""" & source_template & """" & vbCrLf)
116 | End If
117 |
118 | End If
119 | End Sub
120 |
121 | Function FileToArray(ByVal strFile, ByVal blnUNICODE)
122 | Const FOR_READING = 1
123 | Dim objFSO, objTS, strContents
124 | FileToArray = Split("")
125 | Set objFSO = CreateObject("Scripting.FileSystemObject")
126 | If objFSO.FileExists(strFile) Then
127 | On Error Resume Next
128 | Set objTS = objFSO.OpenTextFile(strFile, FOR_READING, False, blnUNICODE)
129 | If Err = 0 Then
130 | strContents = objTS.ReadAll
131 | objTS.Close
132 | FileToArray = Split(strContents, vbNewLine)
133 | End If
134 | End If
135 | End Function
136 |
--------------------------------------------------------------------------------
/Scripts/Summary_Definition_ENU.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 |
23 |
24 | Summary_Scripts.vbs
25 | true
26 |
27 |
28 |
29 | "YES" and Property("RetVal") = "0" or Property("RetVal") = "" ]]>
30 |
31 | F inish]]>
32 |
33 |
34 | Back]]>
35 |
36 |
37 | Operating system deployment completed successfully.
39 | The user state capture was completed successfully.
40 | The computer is now ready to use.
41 | During the deployment process, 0 errors and 0 warnings were reported.
42 |
43 |
44 |
45 | Details ...
46 |
47 |
48 | ]]>
49 |
50 |
51 |
52 |
53 |
54 | "0" and Property("RetVal") <> ""]]>
55 |
56 | F inish]]>
57 |
58 |
59 | Back]]>
60 |
61 |
62 | Operating system deployment did not complete successfully.
64 | The user state capture did not complete successfully.
65 | Please review the log files to determine the cause of the problem.
66 | During the deployment process, 0 errors and 0 warnings were reported.
67 |
68 |
69 |
70 | Details ...
71 |
72 |
73 | ]]>
74 |
75 |
76 |
77 |
78 |
79 |
--------------------------------------------------------------------------------
/Scripts/Summary_scripts.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: Summary_scripts.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Scripts to initialize and validate summary wizard
12 | ' //
13 | ' // ***************************************************************************
14 |
15 | Option Explicit
16 |
17 | Dim iErrors
18 | Dim iWarnings
19 | Dim sBuffer
20 | Dim sDeploymentType
21 |
22 | Function InitializeSummary
23 |
24 | Dim oResults
25 | Dim iRetVal
26 |
27 |
28 | ' Load the results
29 |
30 | If oFSO.FileExists(oEnv("TEMP") & "\Results.xml") then
31 | Set oResults = oUtility.CreateXMLDOMObjectEx(oEnv("TEMP") & "\Results.xml")
32 | iErrors = CInt(oUtility.SelectSingleNodeString(oResults, "//Errors"))
33 | iWarnings = CInt(oUtility.SelectSingleNodeString(oResults, "//Warnings"))
34 | sBuffer = oUtility.SelectSingleNodeString(oResults, "//Messages")
35 | iRetVal = oUtility.SelectSingleNodeString(oResults, "//RetVal")
36 | sDeploymentType = oUtility.SelectSingleNodeString(oResults, "//DeploymentType")
37 | Else
38 | iErrors = 0
39 | iWarnings = 1
40 | sBuffer = "Unable to locate the Results.xml file needed to determine the deployment results. "
41 | sBuffer = sBuffer & "(This may be the result of mismatched script versions. Ensure all boot images have been updated.)"
42 | End if
43 |
44 |
45 | ' If this is a replace, then modifiy the title
46 |
47 | If sDeploymentType = "REPLACE" then
48 | NormalTitle.style.display = "none"
49 | ReplaceTitle.style.display = "inline"
50 | End if
51 |
52 |
53 | ' Set the background color based on the return code
54 |
55 | If iRetVal = "0" or iRetVal = "" then
56 | If iErrors > 0 or iWarnings > 0 then
57 | MyContentArea.style.backgroundColor = "yellow"
58 | End if
59 | Else
60 | MyContentArea.style.backgroundColor = "salmon"
61 | End if
62 |
63 |
64 | ' Update the dialog
65 |
66 | ErrorCount.InnerText = CStr(iErrors)
67 | WarningCount.InnerText = CStr(iWarnings)
68 | optionalWindow1.InnerText = sBuffer
69 | buttonCancel.disabled = true
70 |
71 | End Function
72 |
--------------------------------------------------------------------------------
/Scripts/UDIWizard_Config.xml.app:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/Scripts/WelcomeBanner.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/WelcomeBanner.jpg
--------------------------------------------------------------------------------
/Scripts/WelcomeWiz_Background.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/WelcomeWiz_Background.jpg
--------------------------------------------------------------------------------
/Scripts/WelcomeWiz_Choice.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 | WelcomeWiz_Choice.vbs
22 | true
23 |
24 |
25 |
26 |
27 |
28 |
29 | Далее(N )]]>
30 |
31 |
32 | Перезагрузка(R )]]>
33 |
34 |
35 | Назад(B )]]>
36 |
37 |
38 |
39 |
40 |
41 | true
42 |
43 |
46 |
47 |
48 |
49 | Запустить мастер развёртывания для установки ОС или другой задачи.
53 |
54 |
55 | Run the Windows Recovery Wizard
59 |
60 |
61 | Run DaRT tools
65 |
66 |
67 | Выйти в командную строку
71 |
72 |
73 |
74 |
75 |
76 |
93 |
94 | ]]>
95 |
96 |
97 |
98 |
99 |
--------------------------------------------------------------------------------
/Scripts/WelcomeWiz_DeployRoot.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 |
22 |
23 | WelcomeWiz_DeployRoot.vbs
24 |
25 |
26 |
27 |
28 |
29 |
30 | N ext]]>
31 | false
32 |
33 |
34 |
38 |
39 |
40 |
41 |
42 |
43 |
44 | Specify which deployment share to use.
45 |
46 | Before this wizard can continue, it will need to know the path of a Deployment Share.
47 |
48 |
80 |
81 |
82 |
108 |
109 | ]]>
110 |
111 |
112 |
113 |
114 |
115 |
116 |
--------------------------------------------------------------------------------
/Scripts/WelcomeWiz_Initialize.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: WelcomeWiz_Initialization.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Script logic for initialization/progress display
12 | ' //
13 | ' // ***************************************************************************
14 |
15 |
16 | Option Explicit
17 |
18 |
19 | Function InitializeProgress
20 |
21 | ' Set the background image
22 |
23 | MyContentArea.style.backgroundimage = "url(WelcomeWiz_Background.jpg)"
24 |
25 |
26 | ' Set the window title
27 |
28 | If oEnvironment.Item("_SMSTSOrgName") <> "" then
29 | document.title = oEnvironment.Item("_SMSTSOrgName")
30 | Else
31 | document.title = "Microsoft Deployment Toolkit"
32 | End if
33 |
34 |
35 | ' Schedule a progress update in a half second
36 |
37 | window.SetTimeout GetRef("DisplayProgress"),500
38 |
39 | End function
40 |
41 |
42 | Function DisplayProgress
43 |
44 | Dim sPercent, sMessage
45 |
46 |
47 | ' Retrieve and display the updated progress
48 |
49 | On Error Resume Next
50 | sPercent = oShell.RegRead("HKLM\Software\Microsoft\Deployment 4\ProgressPercent")
51 | sMessage = oShell.RegRead("HKLM\Software\Microsoft\Deployment 4\ProgressText")
52 | ProgressPercent.InnerHTML = sPercent
53 | ProgressMessage.InnerHTML = sMessage
54 | MyProgress.style.width = CStr(sPercent) & "%"
55 | On Error Goto 0
56 |
57 |
58 | ' If at 100%, click next. Otherwise, schedule us again.
59 |
60 | If sPercent = 100 then
61 | window.SetTimeout GetRef("ProgressNext"),700
62 | Else
63 | window.SetTimeout GetRef("DisplayProgress"),500
64 | End if
65 |
66 | End function
67 |
68 |
69 | Function ProgressNext
70 |
71 | ' Click next
72 |
73 | ButtonNextClick
74 |
75 | End Function
76 |
--------------------------------------------------------------------------------
/Scripts/WelcomeWiz_Initialize.xml:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
21 | WelcomeWiz_Initialize.vbs
22 | true
23 |
24 |
25 |
26 |
27 |
28 |
29 | Далее(N )]]>
30 |
31 |
32 | Перезагрузка(R )]]>
33 |
34 |
35 | Назад(B )]]>
36 |
37 | true
38 |
39 |
42 |
46 |
47 | ]]>
48 |
49 | InitializeProgress
50 |
51 |
52 |
53 |
--------------------------------------------------------------------------------
/Scripts/Wizard.hta:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/Wizard.hta
--------------------------------------------------------------------------------
/Scripts/Wizard.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/Wizard.ico
--------------------------------------------------------------------------------
/Scripts/ZTIAuthorizeDHCP.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
146 |
147 |
--------------------------------------------------------------------------------
/Scripts/ZTIBIOSCheck.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
173 |
174 |
--------------------------------------------------------------------------------
/Scripts/ZTIBIOSCheck.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Insert your description here. This field will be written to the log if a match is found.
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 | The WYSIWYG Super Cool Computer 2007 has a bug in version 1.23 of the BIOS that prevents Windows Vista from installing.
21 | Version 1.24 fixes the problem, please update the BIOS. Check http://drivers.WYSIWYGComputers.com/
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
52 |
53 |
54 |
--------------------------------------------------------------------------------
/Scripts/ZTICoalesce.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
174 |
175 |
--------------------------------------------------------------------------------
/Scripts/ZTIConfirmDiskpart.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: ZTIConfFirmDiskpart.wsf
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Solution Accelerator for Business Desktop Deployment
12 | ' //
13 | ' // Usage: cscript ZTIConfirmDiskpart.vbs
14 | ' //
15 | ' // ***************************************************************************
16 |
17 |
18 | ' Hide the progress dialog
19 |
20 | Set oTSProgressUI = CreateObject("Microsoft.SMS.TSProgressUI")
21 | oTSProgressUI.CloseProgressDialog
22 | Set oTSProgressUI = Nothing
23 |
24 | iretval = msgbox ("The task sequence was unable to locate a logical drive" & VBCRLF & "The hard disk will need to be partitioned and formatted." & VBCRLF & "Click on OK to continue or Cancel to exit the task sequence", 1)
25 |
26 |
27 | If iRetVal <> 1 Then
28 | Wscript.Quit 1
29 | End If
30 |
--------------------------------------------------------------------------------
/Scripts/ZTIConnect.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
82 |
83 |
--------------------------------------------------------------------------------
/Scripts/ZTICopyLogs.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
105 |
106 |
--------------------------------------------------------------------------------
/Scripts/ZTIDone.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
29 |
30 |
--------------------------------------------------------------------------------
/Scripts/ZTIErrorMsg.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
31 |
32 |
--------------------------------------------------------------------------------
/Scripts/ZTILangPacksOnline.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
118 |
--------------------------------------------------------------------------------
/Scripts/ZTIModifyVol.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
51 |
52 |
--------------------------------------------------------------------------------
/Scripts/ZTIMoveStateStore.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
130 |
131 |
--------------------------------------------------------------------------------
/Scripts/ZTINextPhase.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
104 |
105 |
--------------------------------------------------------------------------------
/Scripts/ZTIOSRolePS.ps1:
--------------------------------------------------------------------------------
1 |
2 | # // ***************************************************************************
3 | # //
4 | # // Copyright (c) Microsoft Corporation. All rights reserved.
5 | # //
6 | # // Microsoft Deployment Toolkit Solution Accelerator
7 | # //
8 | # // File: ZTIOSRolePS.ps1
9 | # //
10 | # // Version: 6.1.2373.0
11 | # //
12 | # // Purpose: Install or remove roles and features using PowerShell
13 | # //
14 | # // ***************************************************************************
15 |
16 | [CmdletBinding()]
17 | Param(
18 | $FeatureName,
19 | $Source = "",
20 | [switch] $Uninstall,
21 | [switch] $CompletelyRemove
22 | )
23 |
24 | # Load the ZTIUtility if we are outside of the MDT Powershell Host Task Sequence (For testing).
25 |
26 | Import-Module ZTIUtility.psm1
27 |
28 |
29 | # Load the ServerManager module
30 |
31 | Import-Module ServerManager
32 |
33 |
34 | # Process the specified feature
35 |
36 | if ($Uninstall)
37 | {
38 | if ($CompletelyRemove)
39 | {
40 | Write-Host "Completely removing Windows feature $featureName"
41 | $result = Remove-WindowsFeature -Name $featureName -Remove -WarningAction SilentlyContinue
42 | }
43 | else
44 | {
45 | Write-Host "Uninstalling Windows feature $featureName"
46 | $result = Remove-WindowsFeature -Name $featureName -WarningAction SilentlyContinue
47 | }
48 | }
49 | else
50 | {
51 | Write-Host "Installing Windows feature $featureName"
52 | if ($source -eq "")
53 | {
54 | $result = Add-WindowsFeature -Name $featureName -WarningAction SilentlyContinue
55 | }
56 | else
57 | {
58 | $result = Add-WindowsFeature -Name $featureName -Source $source -WarningAction SilentlyContinue
59 | }
60 | }
61 |
62 | # Report the result
63 |
64 | if ($result.Success -eq $false)
65 | {
66 | # Report a failure
67 | if ($result.RestartNeeded -eq "Yes")
68 | {
69 | Write-Host "Failed to process Windows feature, reboot required."
70 | exit 1001
71 | }
72 | else
73 | {
74 | Write-Host "Failed to process Windows feature."
75 | exit 1000
76 | }
77 | }
78 | if ($result.RestartNeeded -eq "Yes")
79 | {
80 | # Report a reboot
81 | Write-Host "Windows feature processed, reboot required."
82 | exit 3010
83 | }
84 | Write-Host "Windows feature processed"
85 | exit 0
86 |
--------------------------------------------------------------------------------
/Scripts/ZTIOptIn.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
93 |
94 |
--------------------------------------------------------------------------------
/Scripts/ZTIPSUtility.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: ZTIPSUtility.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Execute a PowerShell script
12 | ' //
13 | ' // Usage: cscript ZTIPowerShell.wsf
14 | ' //
15 | ' // ***************************************************************************
16 |
17 |
18 | Function RunPowerShellScript(sScriptName, bNative)
19 |
20 | Dim sModules
21 | Dim sSource
22 | Dim sCmd
23 | Dim iRetVal
24 | Dim sVersion
25 | Dim bPrefix
26 | Dim sScript
27 |
28 |
29 | ' Copy modules locally if they aren't already, to avoid .NET trust issues
30 |
31 | sModules = oEnvironment.Item("DeployRoot") & "\Tools\Modules"
32 | If Left(oEnvironment.Item("DeployRoot"), 2) = "\\" then
33 |
34 | sSource = sModules
35 | sModules = oUtility.LocalRootPath & "\Modules"
36 | If not oFSO.FolderExists(sModules) then
37 | oLogging.CreateEntry "Creating " & sModules & " folder for caching PowerShell modules locally.", LogTypeInfo
38 | oFSO.CreateFolder sModules
39 | oLogging.CreateEntry "Copying " & sSource & " folder to " & sModules, LogTypeInfo
40 | oFSO.CopyFolder sSource, sModules, true
41 | End if
42 |
43 | End if
44 |
45 |
46 | ' Decide if we need to thunk for an x86 process
47 |
48 | bPrefix = false
49 | If UCase(oEnv("PROCESSOR_ARCHITEW6432")) = "AMD64" and (not bNative) then
50 | bPrefix = true
51 | End if
52 |
53 |
54 | ' Determine the appropriate PowerShell host to run
55 |
56 | sVersion = ""
57 | On Error Resume Next
58 | Err.Clear
59 | sVersion = oShell.RegRead("HKLM\SOFTWARE\Microsoft\PowerShell\3\PowerShellEngine\PowerShellVersion")
60 | If Err then
61 | sVersion = oShell.RegRead("HKLM\SOFTWARE\Microsoft\PowerShell\1\PowerShellEngine\PowerShellVersion")
62 | End if
63 | On Error Goto 0
64 | If sVersion = "" then
65 | oLogging.CreateEntry "WARNING: PowerShell was not detected.", LogTypeWarning
66 | Else
67 | oLogging.CreateEntry "PowerShell version detected: " & sVersion, LogTypeInfo
68 | End if
69 |
70 | If sVersion = "3.0" then
71 | sCmd = """" & sModules & "\Microsoft.BDD.TaskSequenceModule\Microsoft.BDD.TaskSequencePSHost40.exe"""
72 | If bPrefix then
73 | sCmd = """" & sModules & "\Microsoft.BDD.TaskSequenceModule\Microsoft.BDD.Thunk40.exe"" " & sCmd
74 | End if
75 | Else
76 | sCmd = """" & sModules & "\Microsoft.BDD.TaskSequenceModule\Microsoft.BDD.TaskSequencePSHost35.exe"""
77 | If bPrefix then
78 | sCmd = """" & sModules & "\Microsoft.BDD.TaskSequenceModule\Microsoft.BDD.Thunk35.exe"" " & sCmd
79 | End if
80 | End if
81 |
82 |
83 | ' Get the full path to the script
84 |
85 | iRetVal = oUtility.FindFile(sScriptName, sScript)
86 | If iRetVal <> Success then
87 | oLogging.CreateEntry "Unable to locate script " & sScriptName, LogTypeError
88 | RunPowerShellScript = 10901
89 | Exit Function
90 | End if
91 |
92 |
93 | ' Add the command line parameters
94 |
95 | sCmd = sCmd & " """ & sScript & """ """ & oUtility.LogPath & """ " & oEnvironment.Item("Parameters")
96 |
97 |
98 | ' Run the command line
99 |
100 | oLogging.CreateEntry "About to run: " & sCmd, LogTypeInfo
101 | iRetVal = oShell.Run(sCmd, 0, true)
102 |
103 |
104 | ' Return the exit code
105 |
106 | RunPowerShellScript = iRetVal
107 |
108 | End Function
109 |
--------------------------------------------------------------------------------
/Scripts/ZTIPowerShell.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
52 |
53 |
--------------------------------------------------------------------------------
/Scripts/ZTIPrereq.vbs:
--------------------------------------------------------------------------------
1 | ' // ***************************************************************************
2 | ' //
3 | ' // Copyright (c) Microsoft Corporation. All rights reserved.
4 | ' //
5 | ' // Microsoft Deployment Toolkit Solution Accelerator
6 | ' //
7 | ' // File: ZTIPrereq.vbs
8 | ' //
9 | ' // Version: 6.1.2373.0
10 | ' //
11 | ' // Purpose: Check to see if the machine has the prerequisite software
12 | ' // installed, and that it is functional.
13 | ' //
14 | ' // Usage: cscript ZTIPrereq.wsf
15 | ' //
16 | ' // ***************************************************************************
17 |
18 |
19 | '//----------------------------------------------------------------------------
20 | '//
21 | '// Global constant and variable declarations
22 | '//
23 | '//----------------------------------------------------------------------------
24 |
25 | Option Explicit
26 |
27 | Dim iRetVal
28 |
29 | '//----------------------------------------------------------------------------
30 | '// End declarations
31 | '//----------------------------------------------------------------------------
32 |
33 | '//----------------------------------------------------------------------------
34 | '// Main routine
35 | '//----------------------------------------------------------------------------
36 |
37 | iRetVal = ValidatePrereq
38 | WScript.Quit iRetVal
39 |
40 |
41 | '//---------------------------------------------------------------------------
42 | '//
43 | '// Function: ValidatePrereq()
44 | '//
45 | '// Input: None
46 | '//
47 | '// Return: Success - 0
48 | '// Failure - non-zero
49 | '//
50 | '// Purpose: Check that the needed software components are installed and
51 | '// functioning.
52 | '//
53 | '//---------------------------------------------------------------------------
54 | Function ValidatePrereq()
55 |
56 | Dim dVersion
57 | Dim oShell
58 | Dim oNetwork
59 | Dim oFSO
60 | Dim oEnv
61 | Dim oDoc
62 |
63 | On Error Resume Next
64 |
65 | ' Check the WSH version. It needs to be at least 5.6.
66 |
67 | dVersion = Eval(WScript.Version)
68 | If Err then
69 | ValidatePrereq = 5000 ' Report a specific return code
70 | EXIT FUNCTION
71 | ElseIf dVersion < 5.6 then
72 | ValidatePrereq = 5001 ' Report a specific return code
73 | EXIT FUNCTION
74 | End if
75 |
76 |
77 | ' Create general-purpose WSH objects. These should always succeed; if not,
78 | ' WSH is seriously broken.
79 |
80 | Set oShell = CreateObject("WScript.Shell")
81 | If Err then
82 | ValidatePrereq = 5002 ' Report a specific return code
83 | EXIT FUNCTION
84 | End if
85 |
86 | Set oNetwork = CreateObject("WScript.Network")
87 | If Err then
88 | ValidatePrereq = 5003 ' Report a specific return code
89 | EXIT FUNCTION
90 | End if
91 |
92 | Set oFSO = CreateObject("Scripting.FileSystemObject")
93 | If Err then
94 | ValidatePrereq = 5004 ' Report a specific return code
95 | EXIT FUNCTION
96 | End if
97 |
98 | Set oEnv = oShell.Environment("PROCESS")
99 | If Err then
100 | ValidatePrereq = 5005 ' Report a specific return code
101 | EXIT FUNCTION
102 | End if
103 |
104 |
105 | ' Make sure MSXML 3 is available
106 |
107 | Set oDoc = CreateObject("MSXML2.DOMDocument")
108 | If Err then
109 | ValidatePrereq = 5006 ' Report a specific return code
110 | EXIT FUNCTION
111 | End if
112 |
113 | ValidatePrereq = 0
114 |
115 | End Function
116 |
--------------------------------------------------------------------------------
/Scripts/ZTISetBackground.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
129 |
130 |
--------------------------------------------------------------------------------
/Scripts/ZTISetVariable.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
74 |
75 |
--------------------------------------------------------------------------------
/Scripts/ZTIUserState_Config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | * [*]
7 | * [*]
8 | %PROFILESFOLDER%\* [*]
9 |
10 |
11 | * [*]
12 |
13 |
14 |
15 |
16 | %PROFILESFOLDER%\* [*]
17 |
18 |
19 |
20 |
21 |
37 |
38 |
39 |
--------------------------------------------------------------------------------
/Scripts/ZTIWipeDisk.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
118 |
119 |
--------------------------------------------------------------------------------
/Scripts/btnout.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/btnout.png
--------------------------------------------------------------------------------
/Scripts/btnover.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/btnover.png
--------------------------------------------------------------------------------
/Scripts/btnsel.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/btnsel.png
--------------------------------------------------------------------------------
/Scripts/checkforservices.vbs:
--------------------------------------------------------------------------------
1 | const HKEY_LOCAL_MACHINE = &H80000002
2 | Const ForReading = 1
3 | Const ForWriting = 2
4 | Const bWaitOnReturn = True
5 | Set oShell = CreateObject("WScript.Shell")
6 | SysDrive=oShell.ExpandEnvironmentStrings("%SystemDrive%")
7 | Set objFSO = CreateObject("Scripting.FileSystemObject")
8 |
9 | SvcName = WScript.Arguments(0)
10 | RootKey = "SYSTEM\CurrentControlSet\Services\"
11 | SrvKey = RootKey & SvcName
12 |
13 | Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\default:StdRegProv")
14 | If oReg.EnumKey(HKEY_LOCAL_MACHINE, SrvKey, arrSubKeys) = 0 Then
15 | If (oShell.RegRead("HKEY_LOCAL_MACHINE\" & SrvKey & "\Start") = 2) Then
16 | Set objFileOut = objFSO.OpenTextFile(SysDrive & "\backedup_shares\" & SvcName, ForWriting, True)
17 | objFileOut.Write(SvcName)
18 | objFileOut.Close
19 | End If
20 | End If
21 |
--------------------------------------------------------------------------------
/Scripts/header-image.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/header-image.png
--------------------------------------------------------------------------------
/Scripts/minusico.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/minusico.gif
--------------------------------------------------------------------------------
/Scripts/plusicon.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/monosoul/MS-Deployment-toolkit-scripts/e134707f1c43699275990fc10088d2f56b7be83a/Scripts/plusicon.gif
--------------------------------------------------------------------------------
/Scripts/ztiRunCommandHidden.wsf:
--------------------------------------------------------------------------------
1 |
2 |
3 |
28 |
29 |
--------------------------------------------------------------------------------