├── Configs
├── .gitkeep
├── .gitkeep_1
├── unattend
│ ├── .gitkeep
│ ├── unattend.win2008R2_regularboot.xml
│ ├── unattend.win2016_regularboot.xml
│ ├── unattend.win2012R2_regularboot.xml
│ ├── unattend.win2016.xml
│ ├── unattend.win2012R2.xml
│ ├── unattend.win2008R2.xml
│ ├── unattend.win7_regularboot.xml
│ ├── unattend.win10_regularboot.xml
│ ├── unattend.win8.1_regularboot.xml
│ ├── unattend.win10.xml
│ ├── unattend.win7.xml
│ └── unattend.win8.1.xml
└── labs_config.xml
├── Disks
├── .gitkeep
└── parentdisks
│ └── .gitkeep
├── SoftwareInstallers
├── .gitkeep
├── Office14x86
│ ├── .gitkeep
│ └── config.xml
├── Office15x64
│ ├── .gitkeep
│ └── config.xml
├── Office15x86
│ ├── .gitkeep
│ └── config.xml
├── Office16x64
│ ├── .gitkeep
│ └── Config.xml
├── Office16x86
│ ├── .gitkeep
│ └── Config.xml
└── Office14x64_notrecommendbyMSFT
│ ├── .gitkeep
│ └── config.xml
├── .gitattributes
├── LICENSE
├── Invoke-ADLabDeployer_consoleoutput_CheckConfigOnly.txt
└── README.md
/Configs/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Configs/.gitkeep_1:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Disks/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Configs/unattend/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Disks/parentdisks/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/SoftwareInstallers/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office14x86/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office15x64/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office15x86/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office16x64/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office16x86/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office14x64_notrecommendbyMSFT/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Auto detect text files and perform LF normalization
2 | * text=auto
3 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office16x86/Config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office16x64/Config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office14x86/config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office15x64/config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office15x86/config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/SoftwareInstallers/Office14x64_notrecommendbyMSFT/config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | BSD 3-Clause License
2 |
3 | Copyright (c) 2018, Marc Smeets
4 | All rights reserved.
5 |
6 | Redistribution and use in source and binary forms, with or without
7 | modification, are permitted provided that the following conditions are met:
8 |
9 | * Redistributions of source code must retain the above copyright notice, this
10 | list of conditions and the following disclaimer.
11 |
12 | * Redistributions in binary form must reproduce the above copyright notice,
13 | this list of conditions and the following disclaimer in the documentation
14 | and/or other materials provided with the distribution.
15 |
16 | * Neither the name of the copyright holder nor the names of its
17 | contributors may be used to endorse or promote products derived from
18 | this software without specific prior written permission.
19 |
20 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
23 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
24 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
26 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
27 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
--------------------------------------------------------------------------------
/Invoke-ADLabDeployer_consoleoutput_CheckConfigOnly.txt:
--------------------------------------------------------------------------------
1 | PS D:\ADLabDeployer> $return_net,$return_sys,$return_ads = Invoke-ADLabDeployer -LabConfigFile configs\labs_config.xml -Name FooBar -CheckConfigOnly
2 | PS D:\ADLabDeployer> $return_net
3 |
4 | Name Value
5 | ---- -----
6 | net2 {NetName, Subnet, GW}
7 | net1 {NetName, Subnet, GW}
8 |
9 |
10 | PS D:\ADLabDeployer> $return_net.values
11 |
12 | Name Value
13 | ---- -----
14 | NetName net2
15 | Subnet 10.202.2.0/24
16 | GW 10.202.2.1
17 | NetName net1
18 | Subnet 10.202.1.0/24
19 | GW 10.202.1.1
20 |
21 |
22 | PS D:\ADLabDeployer> $return_ads
23 |
24 | Name Value
25 | ---- -----
26 | BreakMe.local {PDC_LocalPass, SafeModeAdminPass, ADDSName, PDC...}
27 |
28 |
29 | PS D:\ADLabDeployer> $return_ads.Values
30 |
31 | Name Value
32 | ---- -----
33 | PDC_LocalPass Outflank123
34 | SafeModeAdminPass Outflank123
35 | ADDSName BreakMe.local
36 | PDC server1
37 | PDC_IP 10.202.1.11
38 | ParentDomain .
39 | PDC_LocalUser ted
40 |
41 |
42 | PS D:\ADLabDeployer> $return_sys
43 |
44 | Name Value
45 | ---- -----
46 | client8 {VMName, OfficeInstaller, Mem, Net1_GW...}
47 | server4 {VMName, Mem, Net1_GW, OS...}
48 | server5 {VMName, Mem, Net1_GW, OS...}
49 | server2 {VMName, Mem, Net1_GW, OS...}
50 | client6 {VMName, OfficeInstaller, Mem, Net1_GW...}
51 | client7 {VMName, OfficeInstaller, Mem, Net1_GW...}
52 | server1 {VMName, Mem, Net1_GW, OS...}
53 | client5 {VMName, OfficeInstaller, Mem, Net1_GW...}
54 | client2 {VMName, OfficeInstaller, Mem, Net1_GW...}
55 | client3 {VMName, OfficeInstaller, Mem, Net1_GW...}
56 | client1 {VMName, OfficeInstaller, Mem, Net1_GW...}
57 | client4 {VMName, OfficeInstaller, Mem, Net1_GW...}
58 | server3 {VMName, Mem, Net1_GW, OS...}
59 |
60 |
61 | PS D:\ADLabDeployer> $return_sys.client1
62 |
63 | Name Value
64 | ---- -----
65 | VMName FooBar_client1_10.202.2.11_windows10x86_Office16x86
66 | OfficeInstaller Office16x86\setup.exe
67 | Mem 4GB
68 | Net1_GW 10.202.2.1
69 | OS windows10x86
70 | UnattendFile unattend\unattend.win10.xml
71 | SW_Install {Chrome\googlechromestandaloneenterprise.msi, 7z\7z1801-x86.msi, npp\npp.7.5.0.installer.x86.msi}
72 | Pass Outflank123
73 | User ted
74 | Net1_IP 10.202.2.11/24
75 | Hostname client1
76 | Win_Update True
77 | Net1_MAC 06-59-6a-31-a5-e8
78 | Net1_DNS 10.202.1.11
79 | Net1_Name net2
80 | RDP_Allow True
81 | Domain BreakMe.local
82 | ParentDisk parent-en_windows_10_enterprise_version_1709_updated_dec_2017_x86_dvd_100406182-updated201801
83 | OfficeConfig Office16x86\config.xml
84 | Type Client
85 |
86 |
87 | PS D:\ADLabDeployer>
88 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win2008R2_regularboot.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0409:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 |
17 |
18 |
19 | 1
20 | Primary
21 | 100
22 |
23 |
24 | true
25 | 2
26 | Primary
27 |
28 |
29 |
30 |
31 | true
32 | NTFS
33 |
34 | 1
35 | 1
36 | 0x27
37 |
38 |
39 | true
40 | NTFS
41 |
42 | C
43 | 2
44 | 2
45 |
46 |
47 | 0
48 | true
49 |
50 |
51 |
52 |
53 |
54 | 0
55 | 2
56 |
57 | false
58 |
59 |
60 |
61 | true
62 | Outflank
63 | Outflank
64 |
65 | false
66 |
67 |
68 |
69 |
70 | false
71 |
72 |
73 |
74 |
75 | 1
76 |
77 |
78 |
79 |
80 | 0409:00000409
81 | en-US
82 | en-US
83 | en-US
84 | en-US
85 |
86 |
87 | true
88 |
89 |
90 | 0
91 |
92 |
93 | UNATTEND2008R2
94 | 489J6-VHDMP-X63PK-3K798-CPX3Y
95 |
96 |
97 |
98 |
99 |
100 |
101 | Outflank123
102 | true
103 |
104 | true
105 | Outflank
106 |
107 |
108 | true
109 | true
110 | Work
111 | 3
112 | true
113 | true
114 |
115 |
116 |
117 | 1
118 | true
119 | cmd.exe /c "netsh advfirewall set allprofiles state off"
120 | Disable Windows Firewall
121 |
122 |
123 | 2
124 | true
125 | powershell -Command "Enable-PSRemoting -Force"
126 | Enable PowerShell Remoting
127 |
128 |
129 |
130 |
131 |
132 |
133 | Outflank123
134 | true
135 |
136 |
137 | Outflank
138 | Administrators
139 | Outflank
140 |
141 |
142 |
143 | Outflank
144 | Outflank
145 | false
146 | W. Europe Standard Time
147 |
148 |
149 | true
150 |
151 |
152 | true
153 |
154 |
155 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win2016_regularboot.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0c09:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 |
17 |
18 | 0
19 | 2
20 |
21 |
22 |
23 |
24 | true
25 | outflank
26 |
27 |
28 | WC2BQ-8NRM3-FDDYY-2BFGV-KHKQY
29 |
30 |
31 | false
32 |
33 |
34 |
35 |
36 | 1
37 | 350
38 | Primary
39 |
40 |
41 | true
42 | 2
43 | Primary
44 |
45 |
46 |
47 |
48 | NTFS
49 |
50 | 1
51 | 1
52 | 0x27
53 |
54 |
55 | 2
56 | 2
57 | C
58 |
59 | NTFS
60 |
61 |
62 | 0
63 | true
64 |
65 |
66 |
67 |
68 |
69 |
70 | false
71 |
72 |
73 |
74 |
75 | 1
76 |
77 |
78 |
79 |
80 | 0409:00000409
81 | en-US
82 | en-US
83 | en-US
84 | en-US
85 |
86 |
87 | true
88 |
89 |
90 | 0
91 |
92 |
93 | UNATTEND2016
94 |
95 |
96 |
97 |
98 |
99 |
100 | Outflank123
101 | true
102 |
103 | true
104 | outflank
105 |
106 |
107 | true
108 | true
109 | true
110 | true
111 | true
112 | Work
113 | 3
114 | true
115 | true
116 |
117 |
118 |
119 |
120 |
121 | Outflank123
122 | true
123 |
124 |
125 | Outflank
126 | Administrators
127 | Outflank
128 |
129 |
130 |
131 |
132 | outflank
133 | false
134 |
135 |
136 | 1
137 | true
138 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
139 | Change network type to Private
140 |
141 |
142 | 2
143 | true
144 | cmd.exe /c "netsh advfirewall set allprofiles state off"
145 | Disable Windows Firewall
146 |
147 |
148 | 3
149 | true
150 | powershell -Command "Set-WsManQuickConfig -Force"
151 | Enable WsMan
152 |
153 |
154 | 4
155 | true
156 | powershell -Command "Enable-PSRemoting -Force"
157 | Enable PowerShell Remoting
158 |
159 |
160 | W. Europe Standard Time
161 |
162 |
163 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win2012R2_regularboot.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0409:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 |
17 |
18 |
19 | 1
20 | Primary
21 | 100
22 |
23 |
24 | true
25 | 2
26 | Primary
27 |
28 |
29 |
30 |
31 | true
32 | NTFS
33 |
34 | 1
35 | 1
36 | 0x27
37 |
38 |
39 | true
40 | NTFS
41 |
42 | C
43 | 2
44 | 2
45 |
46 |
47 | 0
48 | true
49 |
50 |
51 |
52 |
53 |
54 | 0
55 | 2
56 |
57 | false
58 |
59 |
60 |
61 | true
62 | Outflank
63 | Outflank
64 |
65 | false
66 |
67 |
68 |
69 |
70 | false
71 |
72 |
73 |
74 |
75 | 1
76 |
77 |
78 |
79 |
80 | 0409:00000409
81 | en-US
82 | en-US
83 | en-US
84 | en-US
85 |
86 |
87 | true
88 |
89 |
90 | 0
91 |
92 |
93 | UNATTEND2012R2
94 | KNC87-3J2TX-XB4WP-VCPJV-M4FWM
95 |
96 |
97 |
98 |
99 |
100 |
101 | Outflank123
102 | true
103 |
104 | true
105 | Outflank
106 |
107 |
108 | true
109 | true
110 | true
111 | true
112 | Work
113 | 3
114 | true
115 | true
116 |
117 |
118 |
119 | 1
120 | true
121 | cmd.exe /c "netsh advfirewall set allprofiles state off"
122 | Disable Windows Firewall
123 |
124 |
125 | 2
126 | true
127 | powershell -Command "Enable-PSRemoting -Force"
128 | Enable PowerShell Remoting
129 |
130 |
131 |
132 |
133 |
134 |
135 | Outflank123
136 | true
137 |
138 |
139 | Outflank
140 | Administrators
141 | Outflank
142 |
143 |
144 |
145 | Outflank
146 | Outflank
147 | false
148 | W. Europe Standard Time
149 |
150 | 2
151 |
152 |
153 |
154 | true
155 |
156 |
157 | true
158 |
159 |
160 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win2016.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0c09:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 |
17 |
18 | 0
19 | 2
20 |
21 |
22 |
23 |
24 | true
25 | @@User@@
26 |
27 |
28 | WC2BQ-8NRM3-FDDYY-2BFGV-KHKQY
29 |
30 |
31 | true
32 |
33 |
34 |
35 |
36 | 1
37 | 350
38 | Primary
39 |
40 |
41 | true
42 | 2
43 | Primary
44 |
45 |
46 |
47 |
48 | NTFS
49 |
50 | 1
51 | 1
52 | 0x27
53 |
54 |
55 | 2
56 | 2
57 | C
58 |
59 | NTFS
60 |
61 |
62 | 0
63 | false
64 |
65 |
66 |
67 |
68 |
69 |
70 | false
71 |
72 |
73 |
74 |
75 | 1
76 |
77 |
78 |
79 |
80 | 0809:00000809
81 | nl-NL
82 | nl-NL
83 | nl-NL
84 | nl-NL
85 |
86 |
87 | true
88 |
89 |
90 | 0
91 |
92 |
93 | @@hostname@@
94 |
95 |
96 |
97 |
98 |
99 | False
100 |
101 |
102 | @@Net1_IP@@
103 |
104 | @@Net1_MAC@@
105 |
106 |
107 | 0
108 | 0.0.0.0/0
109 | @@Net1_GW@@
110 |
111 |
112 |
113 |
114 |
115 |
116 | @@DNS_SUFFIX@@
117 |
118 |
119 |
120 | @@Net1_DNS@@
121 |
122 | @@Net1_MAC@@
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 | @@Pass@@
132 | true
133 |
134 | true
135 | 2
136 | @@User@@
137 |
138 |
139 | true
140 | true
141 | true
142 | true
143 | true
144 | Work
145 | 1
146 | true
147 | true
148 |
149 |
150 |
151 | @@Pass@@
152 | true
153 |
154 |
155 |
156 | @@User@@
157 | @@User@@
158 | Administrators
159 | @@User@@
160 |
161 |
162 |
163 |
164 | @@User@@
165 | false
166 | W. Europe Standard Time
167 |
168 |
169 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win2012R2.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0409:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 |
17 |
18 |
19 | 1
20 | Primary
21 | 100
22 |
23 |
24 | true
25 | 2
26 | Primary
27 |
28 |
29 |
30 |
31 | true
32 | NTFS
33 |
34 | 1
35 | 1
36 | 0x27
37 |
38 |
39 | true
40 | NTFS
41 |
42 | C
43 | 2
44 | 2
45 |
46 |
47 | 0
48 | true
49 |
50 |
51 |
52 |
53 |
54 | 0
55 | 2
56 |
57 | false
58 |
59 |
60 |
61 | true
62 | @@User@@
63 |
64 |
65 | false
66 |
67 |
68 |
69 |
70 | false
71 |
72 |
73 |
74 |
75 | 1
76 |
77 |
78 |
79 |
80 | 0409:00000409
81 | en-US
82 | en-US
83 | en-US
84 | en-US
85 |
86 |
87 | true
88 |
89 |
90 | 0
91 |
92 |
93 | @@Hostname@@
94 | 2W8JV-NTQG3-MGGX4-VYF7D-974WJ
95 |
96 |
97 |
98 |
99 |
100 | False
101 |
102 |
103 | @@Net1_IP@@
104 |
105 | @@Net1_MAC@@
106 |
107 |
108 | 0
109 | 0.0.0.0/0
110 | @@Net1_GW@@
111 |
112 |
113 |
114 |
115 |
116 |
117 | @@DNS_SUFFIX@@
118 |
119 |
120 |
121 | @@Net1_DNS@@
122 |
123 | @@Net1_MAC@@
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 | @@Pass@@
133 | true
134 |
135 | true
136 | 1
137 | @@User@@
138 |
139 |
140 | true
141 | true
142 | true
143 | true
144 | Work
145 | 3
146 | true
147 | true
148 |
149 |
150 |
151 | 1
152 | true
153 | cmd.exe /c "netsh advfirewall set allprofiles state off"
154 | Disable Windows Firewall
155 |
156 |
157 | 2
158 | true
159 | powershell -Command "Enable-PSRemoting -Force"
160 | Enable PowerShell Remoting
161 |
162 |
163 |
164 |
165 |
166 |
167 | @@Pass@@
168 | true
169 |
170 |
171 | @@User@@
172 | Administrators
173 | @@User@@
174 |
175 |
176 |
177 |
178 | @@User@@
179 | false
180 | W. Europe Standard Time
181 |
182 | 2
183 |
184 |
185 |
186 | true
187 |
188 |
189 | true
190 |
191 |
192 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win2008R2.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0409:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 |
17 |
18 |
19 | 1
20 | Primary
21 | 100
22 |
23 |
24 | true
25 | 2
26 | Primary
27 |
28 |
29 |
30 |
31 | true
32 | NTFS
33 |
34 | 1
35 | 1
36 | 0x27
37 |
38 |
39 | true
40 | NTFS
41 |
42 | C
43 | 2
44 | 2
45 |
46 |
47 | 0
48 | true
49 |
50 |
51 |
52 |
53 |
54 | 0
55 | 2
56 |
57 | false
58 |
59 |
60 |
61 | true
62 | @@User@@
63 |
64 |
65 | false
66 |
67 |
68 |
69 |
70 | false
71 |
72 |
73 |
74 |
75 | 1
76 |
77 |
78 |
79 |
80 | 0409:00000409
81 | en-US
82 | en-US
83 | en-US
84 | en-US
85 |
86 |
87 | true
88 |
89 |
90 | 0
91 |
92 |
93 | @@hostname@@
94 | 489J6-VHDMP-X63PK-3K798-CPX3Y
95 |
96 |
97 |
98 |
99 |
100 | False
101 |
102 |
103 | @@Net1_IP@@
104 |
105 | @@Net1_MAC@@
106 |
107 |
108 | 0
109 | 0.0.0.0/0
110 | @@Net1_GW@@
111 |
112 |
113 |
114 |
115 |
116 |
117 | @@DNS_SUFFIX@@
118 |
119 |
120 |
121 | @@Net1_DNS@@
122 |
123 | @@Net1_MAC@@
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 | @@Pass@@
133 | true
134 |
135 | true
136 | 1
137 | @@User@@
138 |
139 |
140 | true
141 | true
142 | Work
143 | 3
144 | true
145 | true
146 |
147 |
148 |
149 | 1
150 | true
151 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
152 | Change network type to Private
153 |
154 |
155 | 2
156 | true
157 | cmd.exe /c "netsh advfirewall set allprofiles state off"
158 | Disable Windows Firewall
159 |
160 |
161 | 3
162 | true
163 | powershell -Command "Set-WsManQuickConfig -Force"
164 | Enable WsMan
165 |
166 |
167 | 4
168 | true
169 | powershell -Command "Enable-PSRemoting -Force"
170 | Enable PowerShell Remoting
171 |
172 |
173 |
174 |
175 |
176 |
177 | @@Pass@@
178 | true
179 |
180 |
181 | @@User@@
182 | Administrators
183 | @@User@@
184 |
185 |
186 |
187 |
188 | @@User@@
189 | false
190 | W. Europe Standard Time
191 |
192 |
193 | true
194 |
195 |
196 | true
197 |
198 |
199 |
--------------------------------------------------------------------------------
/Configs/labs_config.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | 10.202.1.0/24
5 | 10.202.1.1
6 |
7 |
8 | 10.202.2.0/24
9 | 10.202.2.1
10 |
11 |
12 | .
13 | server1
14 | Outflank123
15 |
16 |
17 | windows2012R2x64
18 | unattend\unattend.win2012R2.xml
19 | ted:Outflank123
20 | parent-en_windows_server_2012_r2_essentials_with_update_x64_dvd_6052824-updated201704
21 | net1
22 | 10.202.1.11/24
23 | BreakMe.local
24 | True
25 | Chrome\googlechromestandaloneenterprise.msi
26 | 7z\7z1801-x86.msi
27 | npp\npp.7.5.0.installer.x86.msi
28 |
29 |
30 | windows2016x64
31 | unattend\unattend.win2016.xml
32 | 4GB
33 | ted:Outflank123
34 | parent-en_windows_server_2016_x64_dvd_9718492-updated201801
35 | net1
36 | 10.202.1.12/24
37 | True
38 | mu_advanced_threat_analytics_ata_version_1.8_x64_dvd_10911683.iso
39 | True
40 | Chrome\googlechromestandaloneenterprise.msi
41 | 7z\7z1801-x86.msi
42 | npp\npp.7.5.0.installer.x86.msi
43 |
44 |
45 | True
46 | windows2016x64
47 | unattend\unattend.win2016.xml
48 | ted:Outflank123
49 | parent-en_windows_server_2016_x64_dvd_9718492-updated201801
50 | net1
51 | 10.202.1.13/24
52 | True
53 | BreakMe.local
54 | True
55 | Chrome\googlechromestandaloneenterprise.msi
56 | 7z\7z1801-x86.msi
57 | npp\npp.7.5.0.installer.x86.msi
58 |
59 |
60 | windows2008R2x64
61 | unattend\unattend.win2008R2.xml
62 | ted:Outflank123
63 | parent-en_windows_server_2008_r2_with_sp1_vl_build_x64_dvd_617403-updated201801
64 | net1
65 | 10.202.1.14/24
66 | True
67 | BreakMe.local
68 | True
69 | Chrome\googlechromestandaloneenterprise.msi
70 | 7z\7z1801-x86.msi
71 | npp\npp.7.5.0.installer.x86.msi
72 |
73 |
74 | windows2012R2x64
75 | unattend\unattend.win2012R2.xml
76 | ted:Outflank123
77 | parent-en_windows_server_2012_r2_essentials_with_update_x64_dvd_6052824-updated201704
78 | net1
79 | 10.202.1.15/24
80 | True
81 | BreakMe.local
82 | True
83 | Chrome\googlechromestandaloneenterprise.msi
84 | 7z\7z1801-x86.msi
85 | npp\npp.7.5.0.installer.x86.msi
86 |
87 |
88 | windows10x86
89 | unattend\unattend.win10.xml
90 | ted:Outflank123
91 | parent-en_windows_10_enterprise_version_1709_updated_dec_2017_x86_dvd_100406182-updated201801
92 | net2
93 | 10.202.2.11/24
94 | True
95 | BreakMe.local
96 | True
97 | Office16x86\setup.exe
98 | Office16x86\config.xml
99 | Chrome\googlechromestandaloneenterprise.msi
100 | 7z\7z1801-x86.msi
101 | npp\npp.7.5.0.installer.x86.msi
102 |
103 |
104 | windows10x64
105 | unattend\unattend.win10.xml
106 | ted:Outflank123
107 | parent-en_windows_10_enterprise_version_1709_updated_dec_2017_x64_dvd_100406172-updated201801
108 | net2
109 | 10.202.2.12/24
110 | True
111 | BreakMe.local
112 | True
113 | Office16x64\setup.exe
114 | Office16x64\config.xml
115 | Chrome\googlechromestandaloneenterprise.msi
116 | 7z\7z1801-x86.msi
117 | npp\npp.7.5.0.installer.x86.msi
118 |
119 |
120 | windows10x86
121 | unattend\unattend.win10.xml
122 | ted:Outflank123
123 | parent-en_windows_10_enterprise_2016_ltsb_n_x86_dvd_9058202-updated201704
124 | net2
125 | 10.202.2.13/24
126 | 10.202.1.11
127 | True
128 | BreakMe.local
129 | True
130 | Office16x86\setup.exe
131 | Office16x86\config.xml
132 | Chrome\googlechromestandaloneenterprise.msi
133 | 7z\7z1801-x86.msi
134 | npp\npp.7.5.0.installer.x86.msi
135 |
136 |
137 | windows10x64
138 | unattend\unattend.win10.xml
139 | ted:Outflank123
140 | parent-en_windows_10_enterprise_2016_ltsb_n_x64_dvd_9057894-updated201801
141 | net2
142 | 10.202.2.14/24
143 | True
144 | BreakMe.local
145 | True
146 | Office16x64\setup.exe
147 | Office16x64\config.xml
148 | Chrome\googlechromestandaloneenterprise.msi
149 | 7z\7z1801-x86.msi
150 | npp\npp.7.5.0.installer.x86.msi
151 |
152 |
153 | windows7x64
154 | unattend\unattend.win7.xml
155 | ted:Outflank123
156 | parent-en_windows_7_enterprise_n_with_sp1_x64_dvd_u_677704-updated201801
157 | net2
158 | 10.202.2.15/24
159 | True
160 | BreakMe.local
161 | True
162 | Office16x64\setup.exe
163 | Office16x64\config.xml
164 | Chrome\googlechromestandaloneenterprise.msi
165 | 7z\7z1801-x86.msi
166 | npp\npp.7.5.0.installer.x86.msi
167 |
168 |
169 | windows7x86
170 | unattend\unattend.win7.xml
171 | ted:Outflank123
172 | parent-en_windows_7_enterprise_n_with_sp1_x86_dvd_u_677703-updated201801
173 | net2
174 | 10.202.2.16/24
175 | True
176 | BreakMe.local
177 | True
178 | Office14x86\setup.exe
179 | Office14x86\config.xml
180 | Chrome\googlechromestandaloneenterprise.msi
181 | 7z\7z1801-x86.msi
182 | npp\npp.7.5.0.installer.x86.msi
183 |
184 |
185 | windows8.1x64
186 | unattend\unattend.win8.1.xml
187 | ted:Outflank123
188 | parent-en_windows_8.1_enterprise_n_with_update_x64_dvd_6050225-updated201801
189 | net2
190 | 10.202.2.17/24
191 | True
192 | BreakMe.local
193 | True
194 | Office15x86\setup.exe
195 | Office15x86\config.xml
196 | Chrome\googlechromestandaloneenterprise.msi
197 | 7z\7z1801-x86.msi
198 | npp\npp.7.5.0.installer.x86.msi
199 |
200 |
201 | windows8.1x86
202 | unattend\unattend.win8.1.xml
203 | ted:Outflank123
204 | parent-en_windows_8.1_enterprise_n_with_update_x86_dvd_6050217-updated201801
205 | net2
206 | 10.202.2.18/24
207 | True
208 | BreakMe.local
209 | True
210 | Office15x86\setup.exe
211 | Office15x86\config.xml
212 | Chrome\googlechromestandaloneenterprise.msi
213 | 7z\7z1801-x86.msi
214 | npp\npp.7.5.0.installer.x86.msi
215 |
216 |
217 |
218 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win7_regularboot.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 1033:00000409
9 | en-US
10 | en-US
11 | en-US
12 |
13 |
14 |
15 | en-US
16 |
17 | 1033:00000409
18 | en-US
19 | en-US
20 | en-US
21 |
22 |
23 |
24 | false
25 |
26 |
27 | true
28 | Outflank
29 |
30 |
31 |
32 | false
33 |
34 |
35 |
36 | false
37 |
38 |
39 | true
40 | Outflank
41 |
42 |
43 |
44 | false
45 |
46 |
47 |
48 |
49 | 1
50 |
51 |
52 | 1
53 |
54 |
55 |
56 |
57 | false
58 |
59 |
60 | false
61 |
62 |
63 | UNATTENDWIN7
64 | YDRBP-3D83W-TY26F-D46B2-XCKRJ
65 | W. Europe Standard Time
66 |
67 |
68 | UNATTENDWIN7
69 | YDRBP-3D83W-TY26F-D46B2-XCKRJ
70 | W. Europe Standard Time
71 |
72 |
73 |
74 |
75 | 1033:00000409
76 | en-US
77 | en-US
78 |
79 |
80 | 1033:00000409
81 | en-US
82 | en-US
83 |
84 |
85 |
86 |
87 | Outflank123
88 | true
89 |
90 | true
91 | 3
92 | outflank
93 |
94 | Outflank
95 |
96 | true
97 | Work
98 | 3
99 | false
100 | true
101 | true
102 |
103 | false
104 |
105 |
106 | false
107 | 1
108 | Disable Auto Updates
109 | reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
110 |
111 |
112 | Control Panel View
113 | 2
114 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
115 | true
116 |
117 |
118 | 3
119 | Control Panel Icon Size
120 | false
121 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
122 |
123 |
124 | 4
125 | true
126 | cmd /c reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v EnableLUA /t REG_DWORD /d 0 /f
127 | Disable LUA
128 |
129 |
130 | 5
131 | true
132 | cmd /c reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v ConsentPromptBehaviorAdmin /t REG_DWORD /d 0 /f
133 | Disable LUA2
134 |
135 |
136 | 6
137 | true
138 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
139 | Change network type to Private
140 |
141 |
142 | 7
143 | true
144 | cmd.exe /c "netsh advfirewall set allprofiles state off"
145 | Disable Windows Firewall
146 |
147 |
148 | 8
149 | true
150 | powershell -Command "Set-WsManQuickConfig -Force"
151 | Enable WsMan
152 |
153 |
154 | 9
155 | true
156 | powershell -Command "Enable-PSRemoting -Force"
157 | Enable PowerShell Remoting
158 |
159 |
160 |
161 |
162 |
163 |
164 | Outflank123
165 | true
166 |
167 |
168 |
169 | outflank
170 | Administrators
171 | outflank
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 | Outflank123
180 | true
181 |
182 | true
183 | 3
184 | outflank
185 |
186 | Outflank
187 |
188 | true
189 | Work
190 | 3
191 | false
192 | true
193 | true
194 |
195 | false
196 |
197 |
198 | false
199 | 1
200 | Disable Auto Updates
201 | reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
202 |
203 |
204 | Control Panel View
205 | 2
206 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
207 | true
208 |
209 |
210 | 3
211 | Control Panel Icon Size
212 | false
213 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
214 |
215 |
216 | 4
217 | true
218 | cmd /c reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v EnableLUA /t REG_DWORD /d 0 /f
219 | Disable LUA
220 |
221 |
222 | 5
223 | true
224 | cmd /c reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v ConsentPromptBehaviorAdmin /t REG_DWORD /d 0 /f
225 | Disable LUA2
226 |
227 |
228 | 6
229 | true
230 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
231 | Change network type to Private
232 |
233 |
234 | 7
235 | true
236 | cmd.exe /c "netsh advfirewall set allprofiles state off"
237 | Disable Windows Firewall
238 |
239 |
240 | 8
241 | true
242 | powershell -Command "Set-WsManQuickConfig -Force"
243 | Enable WsMan
244 |
245 |
246 | 9
247 | true
248 | powershell -Command "Enable-PSRemoting -Force"
249 | Enable PowerShell Remoting
250 |
251 |
252 |
253 |
254 |
255 |
256 | Outflank123
257 | true
258 |
259 |
260 |
261 | outflank
262 | Administrators
263 | outflank
264 |
265 |
266 |
267 |
268 |
269 |
270 |
271 | false
272 |
273 |
274 | false
275 |
276 |
277 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win10_regularboot.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0409:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 | en-US
17 |
18 | 0409:00000409
19 | en-US
20 | en-US
21 | en-US
22 | en-US
23 |
24 |
25 |
26 |
27 |
28 |
29 | 1
30 | Primary
31 | 100
32 |
33 |
34 | true
35 | 2
36 | Primary
37 |
38 |
39 |
40 |
41 | true
42 | NTFS
43 |
44 | 1
45 | 1
46 | 0x27
47 |
48 |
49 | true
50 | NTFS
51 |
52 | C
53 | 2
54 | 2
55 |
56 |
57 | 0
58 | true
59 |
60 |
61 |
62 |
63 |
64 | 0
65 | 2
66 |
67 | false
68 |
69 |
70 |
71 | true
72 | Outflank
73 | Outflank
74 |
75 | false
76 |
77 |
78 |
79 |
80 |
81 |
82 | 1
83 | Primary
84 | 100
85 |
86 |
87 | true
88 | 2
89 | Primary
90 |
91 |
92 |
93 |
94 | true
95 | NTFS
96 |
97 | 1
98 | 1
99 | 0x27
100 |
101 |
102 | true
103 | NTFS
104 |
105 | C
106 | 2
107 | 2
108 |
109 |
110 | 0
111 | true
112 |
113 |
114 |
115 |
116 |
117 | 0
118 | 2
119 |
120 | false
121 |
122 |
123 |
124 | true
125 | Outflank
126 | Outflank
127 |
128 | false
129 |
130 |
131 |
132 |
133 | false
134 |
135 |
136 |
137 |
138 | false
139 |
140 |
141 |
142 |
143 | 1
144 |
145 |
146 |
147 |
148 | 1
149 |
150 |
151 |
152 |
153 | 0409:00000409
154 | en-US
155 | en-US
156 | en-US
157 | en-US
158 |
159 |
160 | 0409:00000409
161 | en-US
162 | en-US
163 | en-US
164 | en-US
165 |
166 |
167 | true
168 |
169 |
170 | true
171 |
172 |
173 | 0
174 |
175 |
176 | 0
177 |
178 |
179 | UNATTENDWIN10
180 | W269N-WFGWX-YVC9B-4J6C9-T83GX
181 |
182 |
183 | UNATTENDWIN10
184 | W269N-WFGWX-YVC9B-4J6C9-T83GX
185 |
186 |
187 |
188 |
189 |
190 |
191 | Outflank123
192 | true
193 |
194 | true
195 | outflank
196 |
197 |
198 | true
199 | true
200 | true
201 | true
202 | Work
203 | true
204 | true
205 | 3
206 |
207 |
208 |
209 |
210 |
211 | Outflank123
212 | true
213 |
214 |
215 | outflank
216 | Administrators
217 | outflank
218 |
219 |
220 |
221 | Outflank
222 | Outflank
223 | false
224 |
225 |
226 | Control Panel View
227 | 1
228 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
229 | true
230 |
231 |
232 | 2
233 | Control Panel Icon Size
234 | false
235 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
236 |
237 |
238 | 3
239 | true
240 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
241 | Change network type to Private
242 |
243 |
244 | 4
245 | true
246 | cmd.exe /c "netsh advfirewall set allprofiles state off"
247 | Disable Windows Firewall
248 |
249 |
250 | 5
251 | true
252 | powershell -Command "Set-WsManQuickConfig -Force"
253 | Enable WsMan
254 |
255 |
256 | 6
257 | true
258 | powershell -Command "Enable-PSRemoting -Force"
259 | Enable PowerShell Remoting
260 |
261 |
262 | W. Europe Standard Time
263 |
264 |
265 |
266 |
267 | Outflank123
268 | true
269 |
270 | true
271 | outflank
272 |
273 |
274 | true
275 | true
276 | true
277 | true
278 | Work
279 | true
280 | true
281 | 3
282 |
283 |
284 |
285 |
286 |
287 | Outflank123
288 | true
289 |
290 |
291 | outflank
292 | Administrators
293 | outflank
294 |
295 |
296 |
297 | Outflank
298 | Outflank
299 | false
300 |
301 |
302 | Control Panel View
303 | 1
304 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
305 | true
306 |
307 |
308 | 2
309 | Control Panel Icon Size
310 | false
311 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
312 |
313 |
314 | 3
315 | true
316 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
317 | Change network type to Private
318 |
319 |
320 | 4
321 | true
322 | cmd.exe /c "netsh advfirewall set allprofiles state off"
323 | Disable Windows Firewall
324 |
325 |
326 | 5
327 | true
328 | powershell -Command "Set-WsManQuickConfig -Force"
329 | Enable WsMan
330 |
331 |
332 | 6
333 | true
334 | powershell -Command "Enable-PSRemoting -Force"
335 | Enable PowerShell Remoting
336 |
337 |
338 | W. Europe Standard Time
339 |
340 |
341 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win8.1_regularboot.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0409:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 | en-US
17 |
18 | 0409:00000409
19 | en-US
20 | en-US
21 | en-US
22 | en-US
23 |
24 |
25 |
26 |
27 |
28 |
29 | 1
30 | Primary
31 | 100
32 |
33 |
34 | true
35 | 2
36 | Primary
37 |
38 |
39 |
40 |
41 | true
42 | NTFS
43 |
44 | 1
45 | 1
46 | 0x27
47 |
48 |
49 | true
50 | NTFS
51 |
52 | C
53 | 2
54 | 2
55 |
56 |
57 | 0
58 | true
59 |
60 |
61 |
62 |
63 |
64 | 0
65 | 2
66 |
67 | false
68 |
69 |
70 |
71 | true
72 | Outflank
73 | Outflank
74 |
75 | false
76 |
77 |
78 |
79 |
80 |
81 |
82 | 1
83 | Primary
84 | 100
85 |
86 |
87 | true
88 | 2
89 | Primary
90 |
91 |
92 |
93 |
94 | true
95 | NTFS
96 |
97 | 1
98 | 1
99 | 0x27
100 |
101 |
102 | true
103 | NTFS
104 |
105 | C
106 | 2
107 | 2
108 |
109 |
110 | 0
111 | true
112 |
113 |
114 |
115 |
116 |
117 | 0
118 | 2
119 |
120 | false
121 |
122 |
123 |
124 | true
125 | Outflank
126 |
127 |
128 | false
129 |
130 |
131 |
132 |
133 | false
134 |
135 |
136 |
137 |
138 | false
139 |
140 |
141 |
142 |
143 | 1
144 |
145 |
146 |
147 |
148 | 1
149 |
150 |
151 |
152 |
153 | 0409:00000409
154 | en-US
155 | en-US
156 | en-US
157 | en-US
158 |
159 |
160 | 0409:00000409
161 | en-US
162 | en-US
163 | en-US
164 | en-US
165 |
166 |
167 | true
168 |
169 |
170 | true
171 |
172 |
173 | 0
174 |
175 |
176 | 0
177 |
178 |
179 | UNATTENDWIN81
180 | GCRJD-8NW9H-F2CDX-CCM8D-9D6T9
181 |
182 |
183 | UNATTENDWIN81
184 | GCRJD-8NW9H-F2CDX-CCM8D-9D6T9
185 |
186 |
187 |
188 |
189 |
190 |
191 | Outflank123
192 | true
193 |
194 | true
195 | outflank
196 |
197 |
198 | true
199 | true
200 | true
201 | true
202 | Work
203 | 3
204 | true
205 | true
206 |
207 |
208 |
209 |
210 |
211 | Outflank123
212 | true
213 |
214 |
215 | outflank
216 | Administrators
217 | outflank
218 |
219 |
220 |
221 |
222 | Outflank
223 | false
224 |
225 |
226 | false
227 | 1
228 | Disable Auto Updates
229 | reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
230 |
231 |
232 | Control Panel View
233 | 2
234 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
235 | true
236 |
237 |
238 | 3
239 | Control Panel Icon Size
240 | false
241 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
242 |
243 |
244 | 4
245 | true
246 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
247 | Change network type to Private
248 |
249 |
250 | 5
251 | true
252 | cmd.exe /c "netsh advfirewall set allprofiles state off"
253 | Disable Windows Firewall
254 |
255 |
256 | 6
257 | true
258 | powershell -Command "Set-WsManQuickConfig -Force"
259 | Enable WsMan
260 |
261 |
262 | 7
263 | true
264 | powershell -Command "Enable-PSRemoting -Force"
265 | Enable PowerShell Remoting
266 |
267 |
268 | W. Europe Standard Time
269 |
270 | 2
271 |
272 |
273 |
274 |
275 |
276 | Outflank123
277 | true
278 |
279 | true
280 | Outflank
281 |
282 |
283 | true
284 | true
285 | true
286 | true
287 | Work
288 | 3
289 | true
290 | true
291 |
292 |
293 |
294 |
295 |
296 | Outflank123
297 | true
298 |
299 |
300 | Outflank
301 | Administrators
302 | Outflank
303 |
304 |
305 |
306 |
307 | Outflank
308 | false
309 |
310 |
311 | false
312 | 1
313 | Disable Auto Updates
314 | reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
315 |
316 |
317 | Control Panel View
318 | 2
319 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
320 | true
321 |
322 |
323 | 3
324 | Control Panel Icon Size
325 | false
326 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
327 |
328 |
329 | 4
330 | true
331 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
332 | Change network type to Private
333 |
334 |
335 | 5
336 | true
337 | cmd.exe /c "netsh advfirewall set allprofiles state off"
338 | Disable Windows Firewall
339 |
340 |
341 | 6
342 | true
343 | powershell -Command "Set-WsManQuickConfig -Force"
344 | Enable WsMan
345 |
346 |
347 | 7
348 | true
349 | powershell -Command "Enable-PSRemoting -Force"
350 | Enable PowerShell Remoting
351 |
352 |
353 | W. Europe Standard Time
354 |
355 | 2
356 |
357 |
358 |
359 | true
360 |
361 |
362 | true
363 |
364 |
365 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win10.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0409:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 | en-US
17 |
18 | 0409:00000409
19 | en-US
20 | en-US
21 | en-US
22 | en-US
23 |
24 |
25 |
26 |
27 |
28 |
29 | 1
30 | Primary
31 | 100
32 |
33 |
34 | true
35 | 2
36 | Primary
37 |
38 |
39 |
40 |
41 | true
42 | NTFS
43 |
44 | 1
45 | 1
46 | 0x27
47 |
48 |
49 | true
50 | NTFS
51 |
52 | C
53 | 2
54 | 2
55 |
56 |
57 | 0
58 | true
59 |
60 |
61 |
62 |
63 |
64 | 0
65 | 2
66 |
67 | false
68 |
69 |
70 |
71 | true
72 | @@User@@
73 | @@User@@
74 |
75 | false
76 |
77 |
78 |
79 |
80 |
81 |
82 | 1
83 | Primary
84 | 100
85 |
86 |
87 | true
88 | 2
89 | Primary
90 |
91 |
92 |
93 |
94 | true
95 | NTFS
96 |
97 | 1
98 | 1
99 | 0x27
100 |
101 |
102 | true
103 | NTFS
104 |
105 | C
106 | 2
107 | 2
108 |
109 |
110 | 0
111 | true
112 |
113 |
114 |
115 |
116 |
117 | 0
118 | 2
119 |
120 | false
121 |
122 |
123 |
124 | true
125 | @@User@@
126 | @@User@@
127 |
128 | false
129 |
130 |
131 |
132 |
133 | false
134 |
135 |
136 |
137 |
138 | false
139 |
140 |
141 |
142 |
143 | 1
144 |
145 |
146 |
147 |
148 | 1
149 |
150 |
151 |
152 |
153 | 0409:00000409
154 | en-US
155 | en-US
156 | en-US
157 | en-US
158 |
159 |
160 | 0409:00000409
161 | en-US
162 | en-US
163 | en-US
164 | en-US
165 |
166 |
167 | true
168 |
169 |
170 | true
171 |
172 |
173 | 0
174 |
175 |
176 | 0
177 |
178 |
179 | @@Hostname@@
180 | W269N-WFGWX-YVC9B-4J6C9-T83GX
181 |
182 |
183 | @@Hostname@@
184 | W269N-WFGWX-YVC9B-4J6C9-T83GX
185 |
186 |
187 |
188 |
189 |
190 | False
191 |
192 | @@Net1_MAC@@
193 |
194 | @@Net1_IP@@
195 |
196 |
197 |
198 | 0
199 | 0.0.0.0/0
200 | @@Net1_GW@@
201 |
202 |
203 |
204 |
205 |
206 |
207 |
208 |
209 |
210 | False
211 |
212 | @@Net1_MAC@@
213 |
214 | @@Net1_IP@@
215 |
216 |
217 |
218 | 0
219 | 0.0.0.0/0
220 | @@Net1_GW@@
221 |
222 |
223 |
224 |
225 |
226 |
227 | @@DNS_SUFFIX@@
228 |
229 |
230 |
231 | @@Net1_DNS@@
232 |
233 | @@Net1_MAC@@
234 |
235 |
236 |
237 |
238 | @@DNS_SUFFIX@@
239 |
240 |
241 |
242 | @@Net1_DNS@@
243 |
244 | @@Net1_MAC@@
245 |
246 |
247 |
248 |
249 |
250 |
251 |
252 |
253 | @@Pass@@
254 | true
255 |
256 | true
257 | 1
258 | @@User@@
259 |
260 |
261 | true
262 | true
263 | true
264 | true
265 | Work
266 | true
267 | true
268 | 3
269 |
270 |
271 |
272 |
273 |
274 | @@Pass@@
275 | true
276 |
277 |
278 | @@User@@
279 | Administrators
280 | @@User@@
281 |
282 |
283 |
284 |
285 | @@User@@
286 | false
287 |
288 |
289 | Control Panel View
290 | 1
291 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
292 | true
293 |
294 |
295 | 2
296 | Control Panel Icon Size
297 | false
298 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
299 |
300 |
301 | 3
302 | true
303 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
304 | Change network type to Private
305 |
306 |
307 | 4
308 | true
309 | cmd.exe /c "netsh advfirewall set allprofiles state off"
310 | Disable Windows Firewall
311 |
312 |
313 | 5
314 | true
315 | powershell -Command "Set-WsManQuickConfig -Force"
316 | Enable WsMan
317 |
318 |
319 | 6
320 | true
321 | powershell -Command "Enable-PSRemoting -Force"
322 | Enable PowerShell Remoting
323 |
324 |
325 | W. Europe Standard Time
326 |
327 |
328 |
329 |
330 | @@Pass@@
331 | true
332 |
333 | true
334 | 1
335 | @@User@@
336 |
337 |
338 | true
339 | true
340 | true
341 | true
342 | Work
343 | true
344 | true
345 | 3
346 |
347 |
348 |
349 |
350 |
351 | @@Pass@@
352 | true
353 |
354 |
355 | @@User@@
356 | Administrators
357 | @@User@@
358 |
359 |
360 |
361 |
362 | @@User@@
363 | false
364 |
365 |
366 | Control Panel View
367 | 1
368 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
369 | true
370 |
371 |
372 | 2
373 | Control Panel Icon Size
374 | false
375 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
376 |
377 |
378 | 3
379 | true
380 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
381 | Change network type to Private
382 |
383 |
384 | 4
385 | true
386 | cmd.exe /c "netsh advfirewall set allprofiles state off"
387 | Disable Windows Firewall
388 |
389 |
390 | 5
391 | true
392 | powershell -Command "Set-WsManQuickConfig -Force"
393 | Enable WsMan
394 |
395 |
396 | 6
397 | true
398 | powershell -Command "Enable-PSRemoting -Force"
399 | Enable PowerShell Remoting
400 |
401 |
402 | W. Europe Standard Time
403 |
404 |
405 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win7.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 1033:00000409
9 | en-US
10 | en-US
11 | en-US
12 |
13 |
14 |
15 | en-US
16 |
17 | 1033:00000409
18 | en-US
19 | en-US
20 | en-US
21 |
22 |
23 |
24 | false
25 |
26 |
27 | true
28 | @@User@@
29 |
30 |
31 |
32 | false
33 |
34 |
35 |
36 | false
37 |
38 |
39 | true
40 | @@User@@
41 |
42 |
43 |
44 | false
45 |
46 |
47 |
48 |
49 | 1
50 |
51 |
52 | 1
53 |
54 |
55 |
56 |
57 | false
58 |
59 |
60 | false
61 |
62 |
63 | @@Hostname@@
64 | YDRBP-3D83W-TY26F-D46B2-XCKRJ
65 | W. Europe Standard Time
66 |
67 |
68 | @@Hostname@@
69 | YDRBP-3D83W-TY26F-D46B2-XCKRJ
70 | W. Europe Standard Time
71 |
72 |
73 |
74 |
75 |
76 | False
77 |
78 | @@Net1_MAC@@
79 |
80 | @@Net1_IP@@
81 |
82 |
83 |
84 | 0
85 | 0.0.0.0/0
86 | @@Net1_GW@@
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 | False
97 |
98 | @@Net1_MAC@@
99 |
100 | @@Net1_IP@@
101 |
102 |
103 |
104 | 0
105 | 0.0.0.0/0
106 | @@Net1_GW@@
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 | @@Net1_DNS@@
117 |
118 | @@Net1_MAC@@
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 | @@Net1_DNS@@
127 |
128 | @@Net1_MAC@@
129 |
130 |
131 |
132 |
133 |
134 |
135 | 1033:00000409
136 | en-US
137 | en-US
138 |
139 |
140 | 1033:00000409
141 | en-US
142 | en-US
143 |
144 |
145 |
146 |
147 | @@Pass@@
148 | true
149 |
150 | true
151 | 1
152 | @@User@@
153 |
154 | @@User@@
155 |
156 | true
157 | Work
158 | 3
159 | false
160 | true
161 | true
162 |
163 | false
164 |
165 |
166 | false
167 | 1
168 | Disable Auto Updates
169 | reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
170 |
171 |
172 | Control Panel View
173 | 2
174 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
175 | true
176 |
177 |
178 | 3
179 | Control Panel Icon Size
180 | false
181 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
182 |
183 |
184 | 4
185 | true
186 | cmd /c reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v EnableLUA /t REG_DWORD /d 0 /f
187 | Disable LUA
188 |
189 |
190 | 5
191 | true
192 | cmd /c reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v ConsentPromptBehaviorAdmin /t REG_DWORD /d 0 /f
193 | Disable LUA2
194 |
195 |
196 | 6
197 | true
198 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
199 | Change network type to Private
200 |
201 |
202 | 7
203 | true
204 | cmd.exe /c "netsh advfirewall set allprofiles state off"
205 | Disable Windows Firewall
206 |
207 |
208 | 8
209 | true
210 | powershell -Command "Set-WsManQuickConfig -Force"
211 | Enable WsMan
212 |
213 |
214 | 9
215 | true
216 | powershell -Command "Enable-PSRemoting -Force"
217 | Enable PowerShell Remoting
218 |
219 |
220 |
221 |
222 |
223 |
224 | @@Pass@@
225 | true
226 |
227 |
228 |
229 | @@User@@
230 | Administrators
231 | @@User@@
232 |
233 |
234 |
235 |
236 |
237 |
238 |
239 | @@Pass@@
240 | true
241 |
242 | true
243 | 1
244 | @@User@@
245 |
246 | @@User@@
247 |
248 | true
249 | Work
250 | 3
251 | false
252 | true
253 | true
254 |
255 | false
256 |
257 |
258 | false
259 | 1
260 | Disable Auto Updates
261 | reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
262 |
263 |
264 | Control Panel View
265 | 2
266 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
267 | true
268 |
269 |
270 | 3
271 | Control Panel Icon Size
272 | false
273 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
274 |
275 |
276 | 4
277 | true
278 | cmd /c reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v EnableLUA /t REG_DWORD /d 0 /f
279 | Disable LUA
280 |
281 |
282 | 5
283 | true
284 | cmd /c reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v ConsentPromptBehaviorAdmin /t REG_DWORD /d 0 /f
285 | Disable LUA2
286 |
287 |
288 | 6
289 | true
290 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
291 | Change network type to Private
292 |
293 |
294 | 7
295 | true
296 | cmd.exe /c "netsh advfirewall set allprofiles state off"
297 | Disable Windows Firewall
298 |
299 |
300 | 8
301 | true
302 | powershell -Command "Set-WsManQuickConfig -Force"
303 | Enable WsMan
304 |
305 |
306 | 9
307 | true
308 | powershell -Command "Enable-PSRemoting -Force"
309 | Enable PowerShell Remoting
310 |
311 |
312 |
313 |
314 |
315 |
316 | @@Pass@@
317 | true
318 |
319 |
320 |
321 | @@User@@
322 | Administrators
323 | @@User@@
324 |
325 |
326 |
327 |
328 |
329 |
330 |
331 | false
332 |
333 |
334 | false
335 |
336 |
337 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Goal of the project #
2 | Automated deployment of Windows and Active Directory test lab networks. Useful for red and blue teams.
3 |
4 | During red teaming gigs we encounter many different setups at our clients. To test our payloads and to review our artefacts we need a lab that allows us to quickly deploy Windows OS version X with Office version Y, in a fully working AD and a network setup that has separate broadcast segments.
5 | Invoke-ADLabDeployer does the heavy lifting. From there on you can easily tune to your exact liking, e.g. create specific GPO’s, install extra software, and make any other final tuning for the setup that you need.
6 |
7 | Invoke-ADLabDeployer relies heavily on techniques like Hyper-V, sysprep and (remote) Powershell for the deployment and configuration.
8 |
9 | There are other projects out there that do similar things. But Invoke-ADLabDeployer has support for all Windows OS versions currently encountered at clients, specifically support for Win7 and Server2008R2, while keeping resource usage low by using smart Hyper-V tricks like differencing disks, dynamic memory, etc.
10 | More background info and reasoning why this script has added value over others as well as over Azure [here](https://outflank.nl/blog/2018/03/30/automated-ad-and-windows-test-lab-deployments-with-invoke-adlabdeployer/)
11 |
12 | ## Running the script ##
13 | **There is no quick starting with this script. You really need to have parent images pre-created.**
14 |
15 | If you are sure you meet all the requirements and have done all the preparations, you can run it using:
16 |
17 | Import: `Import-Module .\Invoke-ADLabDeployer.ps1`
18 |
19 | Start deployment: `Invoke-ADLabDeployer -LabConfigFile configs\labs_config.xml -Name demolab -Verbose`
20 |
21 | The `-Verbose` tag will give you handy status reports.
22 |
23 | Example output can be found [here](./Invoke-ADLabDeployer_consoleoutput_fullrun.txt).
24 |
25 |
26 | Test the config file: `Invoke-ADLabDeployer -LabConfigFile configs\labs_config.xml -Name demolab -CheckConfigOnly`
27 |
28 | Have the config returned into local hashtables: `$return_net,$return_sys,$return_adds = Invoke-ADLabDeployer -LabConfigFile configs\labs_config.xml -Name demolab -CheckConfigOnly`
29 |
30 | Example output can be found [here](./Invoke-ADLabDeployer_consoleoutput_CheckConfigOnly.txt)
31 |
32 |
33 | ## Flow of script ##
34 | On a generic level, the following tasks are performed:
35 | - Read the configuration file and perform syntax checks
36 | - Basic check on host OS network setup, i.e. required packages, enable routing and set WSMan trustedhosts
37 | - Virtual network setup.
38 | - Make linked copies (differencing disks) to the parent VHDs.
39 | - Mount the linked disks and edit the unattend file to inject hostname, IP address, local user, etc.
40 | - Unmount the disks and create the new virtual guests from the linked VHDs.
41 | - Power on, wait some time for sysprep to complete.
42 | - Install and configure the Active Directory Domain Controller.
43 | - Have clients join the new domain.
44 | - Install Office and other software packages.
45 | - Perform final configs of local settings, e.g. RDP, Windows Update, some performance tuning, etc.
46 |
47 |
48 |
49 | ## Requirements ##
50 | You need the following:
51 | - Required licenses for Microsoft software you are deploying. We use our own licenses. To get you started quickly, Ive included evaluation license keys in the Windows unattend files. The Office unattend files have "XXX" as license key, so you need to change that to be able to install Office. The Windows license keys are [EVAL licenses](https://docs.microsoft.com/en-us/windows-server/get-started/kmsclientkeys) and should work on all Windows versions whatever the install ISO is. There is one exception: 2008R2. The 2008R2 setup installer is very picky on the exact install ISO you used. The supplied license in the unattend file is for en_windows_server_2008_r2_with_sp1_vl_build_x64_dvd_617403.iso **You may or may not be in violation with Microsoft license agreements. Use at your own risk.**
52 | - Local server that is capable of running multiple virtual machines. Intel VT-x or AMD/V capable CPU and a SSD disk is highly recommended. I'm using an Intel Skull NUC, solely for this purpose. It runs perfect and is able to deploy and host dozens of systems.
53 | - A base Windows server OS that will host the lab using Hyper-V. Im running Server 2016. While I believe this will also work on other systems while WMF 5.0 is installed, I have not tested this.
54 | - Parent images: virtual hard drives with the parent images prepared of what you want to deploy. Ive got Win7, Win8.1, Win10, 2016 LTSB, Win10 1709, Server 2008r2, 2012R2 and 2016. For each desktop OS I have a x86 and an x64 version, servers just x64 but there is no reason why x86 shouldn't work. More info on this below. The systems need to run powershell 2.0. So in theory it could also deploy Windows XP and 2003, but this is not tested.
55 | - Config file: a XML file that defines the layout of the lab that you want to deploy. More info on this below.
56 | - As the lab will dohave multiple subnets, we need to have RRAS (Routing and Remote Access) service installed, and the routing package. But they dont need to be configured as you would normally do, the script does this for you. This is probably against MSFT guidelines, but it works. The script does some checking and will help you to some degree with this. But if you encounter any issues, run Install-WindowsFeature RSAT-RemoteAccess –IncludeManagementTools; Install-WindowsFeature Routing -IncludeManagementTools
57 | - Base installation files for the Office versions if you want to install Office. This repository includes config files for unattended Office installs. You do need to add your own license key, and perhaps go through the exact Office applications you want to install as defined in the office config files.
58 |
59 |
60 | ## Creating the parent images ##
61 | - Create a new virtual machine in Hyper-V as you normally would. Have the disk stored in the `\disks\parentdsisks\` directory. Generation 2 virtual machines are preferred, but Hyper-V only supports this if 64bit desktop OS is Win8 or later, or server OS is win2012 or later (32 and 64bit). More info [here](https://docs.microsoft.com/en-us/windows-server/virtualization/hyper-v/plan/should-i-create-a-generation-1-or-2-virtual-machine-in-hyper-v#BKMK_Windows)
62 | - Power on, install Windows and update to the level you want.
63 | - Post install **required** changes:
64 | - Enable WSMan: in powershell: `Set-WsManQuickConfig -Force`
65 | - Enable RemotePowershell: in powershell: `Enable-PSRemoting -Force`
66 | - Reset the NIC connection profile setting: in powershell: `$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) } `
67 | this sets the connection profile to Private in a powershell version that Win7 also can handle.
68 | - Disable the firewall: in a command prompt: `netsh advfirewall set allprofiles state off`
69 | - _Optional:_ you can poweroff and make a backup of the vhd if you want. I recommend this as it makes troubleshooting and restoring after sysprep issues easier.
70 | - Copy the `unattend_regularboot.xml` file for that OS version to the guest.
71 | - Start sysprep: `cmd: c:\windows\system32\sysprep\sysprep.exe /generalize /oobe /shutdown /unattend:c:\unattend_regularboot.xml`
72 | - Recommended: boot the system once to test sysprep finalises OK. In case of any error, I recommend to poweroff the machine and mount the disk using your host machine. This allows for easier debugging of sysprep images. You want to check `c:\windows\panther\UnattendGC\setuperror.log` for troubleshooting. You can easily check that file by simply mounting the vhd of the guest vm.
73 | - **Important**: the parent image needs to be in a sysprepped and powerd off state. So if you did a test run to see if sysprep worked ok, make sure to power if off again using the sysprep command with the ‘regularboot’ unattend file.
74 |
75 |
76 | ## Lab config file ##
77 | The script needs a config file to know what it needs to deploy. Ive included an example lab_config.xml file. It should be rather self explanatory, but you can find more detailed info below.
78 |
79 | The config file can have multiple labs defined. The `-Name` parameter to Invoke-ADLabDeployer defines the actual lab to deploy. Also, the `-CheckConfigOnly` parameter can help you with, well, checking the config. Per lab name you define the other sections you can find below. But on a general level you can have a config like:
80 | ```
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 | ```
90 | ### Config file parameters - Network ###
91 | This defined the network sections. This is mandatory. You can have multiple sections of this.
92 | Example:
93 | ```
94 |
95 | 10.202.1.0/24
96 | 10.202.1.1
97 |
98 | ```
99 | - `NetName`: the name
100 | - `Subnet`: network address of the subnet, requires a subnet mask defintion in form of `/XX`
101 | - `GW`: IP address of the gateway of this subnet. The virtual switch on your host system will get this address.
102 |
103 | ### Config file parameters - Active Directory ###
104 | This defines the Active Directory section. This is not mandatory. You can have multiple sections of this.
105 | Example:
106 | ```
107 |
108 | .
109 | server1
110 | Outflank123
111 |
112 | ```
113 | - _Optional_ `ParentDomain`: doesnt do anything at this moment
114 | - `ADDSName`: the name
115 | - `PDC`: the name of the system that will be the first domain controller. This name needs to correspond with a Hostname in the `System` section.
116 | - `SafeModeAdminPass`: password required by Active Directory as the safe mode password for the local administrator account.
117 |
118 |
119 | ### Config file parameters - System ###
120 | This defines a system. This is mandatory. You can have multiple sections of this.
121 | Example:
122 | ```
123 |
124 | windows2012R2x64
125 | unattend\unattend.win2012R2.xml
126 | outflank:Outflank123
127 | parent-en_windows_server_2012_r2_essentials_with_update_x64_dvd_6052824-updated201704
128 | net1
129 | 10.202.1.11/24
130 |
131 |
132 | windows7x64
133 | unattend\unattend.win7.xml
134 | ted:Outflank123
135 | parent-en_windows_7_enterprise_n_with_sp1_x64_dvd_u_677704-updated201801
136 | net2
137 | 10.202.2.13/24
138 | 4GB
139 | True
140 | BreakMe.local
141 | True
142 | Office16x64\setup.exe
143 | Office16x64\config.xml
144 | somefile.bin
145 | Chrome\googlechromestandaloneenterprise.msi
146 | 7z\7z1801-x86.msi
147 | npp\npp.7.5.0.installer.x86.msi
148 |
149 | ```
150 | - `Hostname`: the hostname
151 | - `OS`: Specific Windows version of the system. Allowed values at this moment are:
152 | - `Windows7x86`
153 | - `Windows7x64`
154 | - `Windows8.1x86`
155 | - `Windows8.1x64`
156 | - `Windows10x86`
157 | - `Windows10x64`
158 | - `Windows2008R2x64`
159 | - `Windows2012R2x64`
160 | - `Windows2016x64`
161 | - `UnattendFile`: the path of the unattend file
162 | - `LocalCred`: username:password of a local administrator account.
163 | - `ParentDisk`: the filename of the parent image VHD disk. ".VHDX" is automatically added.
164 | - `Net1_Name`: the name of the network as defined in the Network section.
165 | - `Net1_IP`: the IP address+subnet mask you give to this host.
166 | - _optional_ `Mem`: the amount of memory you want the system to have. If not specified, server OSes will get 1GB and client OSes will get 2GB.
167 | - _optional_ `Net1_GW`: manually define a default gateway for this NIC. This will not influence the setup of the virtual network, only the deployed system's routing table. So unless you've manually created a router somewhere, this parameter will likely break routing for this system.
168 | - _optional_ `SkipDeploy`: set to `True` if you do not want this system to be deployed but still keep its config in the config file.
169 | - _optional_ `Net1_DNS`: The DNS server address you want this machine to have. If not set, it will pick the IP address of the PDC if the system is domain joined, or 9.9.9.9 for non domain joined machines. If you want 2 DNS servers configured, make them comma separated.
170 | - _optional_ `Domain`: the Active Directory domain name to join as defined in the ADDS section.
171 | - _optional_ `RDP_Allow`: When set to `True` RDP will be enabled. Also, the local users group, and domain users if domain joined, are added to the 'Remote Desktop Users' group.
172 | - _optional_ `OfficeInstaller`: path to Office installer executable. Also requires OfficeConfig to be set.
173 | - _optional_ `OfficeConfig`: path to the office config file. Also requires OfficeInstaller to be set.
174 | - _optional_ `SW_JustCopy`: path to a file you just want to be copied. Can be multiple. Will be copied to c:\SoftwareInstallers.
175 | - _optional_ `SW_Install`: path to a msi installer file that you want to be installed. Can be multiple. A log of the msiexec installation output is placed in c:\SoftwareInstallers.
176 |
177 |
178 | ## Directory structure ##
179 | This repo and script uses the following directory structure, which is recommended to adhere to as some paths may be hardcoded:
180 | - `.\configs`: here are lab config files
181 | - `.\configs\unattend\`: here are the unattend files
182 | - `.\disks`: the VHDs of your deployed lab be put in a subdirectory per labname.
183 | - `.\disks\parentdisks\`: here you need to store the parent VHDs.
184 | - `.\SoftwareInstallers`: home for extra software packages that you want to deploy.
185 | - `.\SoftwareInstallers\Office14x86\`: example of Office folder, in this folder is the config.xml and the setup binary - basically just copy the entire contents of the install ISO to this folder.
186 |
187 |
188 | ## Known bugs and caveats ##
189 | - You need to prepare the base images yourself, this script does not do this for you. Im open for ideas to automate this.
190 | - Only supports English versions of Windows. Main reason is hardcoded commands like 'net localgroup "Remote Desktop Users"'. This is a result of a design choice to support systems with that only run PowerShell v2. Later PowerShell versions have fancy commands to alter local groups, but v2 doesnt. This is likely not going change in future versions, unless there is a way to keep support for PowerShell v2.
191 | - The server OS unattend files in this repository do not have support for 32 bit versions. This is not a hard change to do as it only required x86 sections of settings in the unattend files. I simply havent had the time nor demand for it.
192 | - Error and state checking is not really structured. If a system can't complete a specific task its simply reported in the output, but the script continues with its flow. Depending tasks will fail as well.
193 | - Timeouts are tuned to my hardware. If you have slower hardware (or deploy huge networks) its possible deployment will not go as smooth as hoped.
194 | - The script makes use of native routing instead of NAT on the Hyper-V host. This is an explicit choice as it allows you to remotely connect to the deployed guests using their lab IP address from any other remote system. However, unless your Hyper-V machine is also your core router, or unless you only connect to your deployed guests from your Hyper-V machine, your network might not know how to reach the deployed subnet. Depending on your network setup, this may also prevent your lab systems from reaching the internet. There is an easy fix for this: manual static routes on your core router pointing to the deployed subnets. Reading this line of text takes longer than setting the static route in your network.
195 | - XML tags are case sensitive. If the config check fails, check the case of the tags in your config file.
196 | - System computername can't exceed 15 characters and can't contain dots. This is a native Windows issue that I cant fix, but I just want to warn you as you may encounter this.
197 | - Server 2008(R2) can't be running the PDC. There are no Powershell commands for this, so this would need dcpromo commands in order to work. But this is a very specific situation that I haven't seen in a live environment anymore in years. 2008R2 Can install the mngt tools using `Import-Module Servermanager; Add-WindowsFeature -Name "RSAT-AD-PowerShell" -IncludeAllSubFeature` but the initial domain still needs to be done using dcpromo.
198 | - Auto updates, if configured using the `` tag, may start many hours after your deployment. Im open to ideas for instant deployment that works on all Windows vesions.
199 | - Auto updates on some 2012R2 (and up) and 8.1 (and up) versions don't seem to work completely. They require you to manually hit 'check for updates now' inside the guest the 1st time.
200 | - The progress bar of the installation of Active Directory Domain Services keeps on top even after successful installation of ADDS; it never finishes.
201 |
202 |
203 | ## Features on todo-list ##
204 | - Windows 10: disable background scanning of defender, defrag etc to safe CPU resources when idle.
205 | - Windows 10: control detailed Defender settings from config file.
206 | - Have a function for automated monthly updates of the base images. This is about 80% done.
207 | - Automate the installation of sysmon+WEC+ELK per lab. This is about 50% done.
208 | - Incremental updates of deployed labs: have the script check if a lab already exists, and if so let it check if there are hosts in the new config that arent deployed yet and only deploy these.
209 | - Support for AD subdomains, domains in same forest and domains in separate forests.
210 | - Add users, groups, OU to the AD domain based on an input file. This is about 50% done.
211 | - Include 32bit support in the unattend files for server Windows versions.
212 | - make IP address of system optional: have the script auto pick an IP address in the network.
213 | - Support for multiple NICs per system.
214 | - More advanced networking setup, where lab config file can be used to determine detailed routing setup. Preferably using true Hyper-V Network Virtualization (RRIDs, CA, PA, etc.).
215 |
216 |
217 | ## Author ##
218 | This project is developed and maintained by Marc Smeets (@smeetsie on github, and @mramsmeets on Twitter).
219 |
220 | ## License ##
221 | This project is made available uner the BSD 3.0 license. This means:
222 | Copyright 2018 Outflank B.V.
223 |
224 | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
225 |
226 | 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
227 |
228 | 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
229 |
230 | 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
231 |
232 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
233 |
--------------------------------------------------------------------------------
/Configs/unattend/unattend.win8.1.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | en-US
7 |
8 | 0409:00000409
9 | en-US
10 | en-US
11 | en-US
12 | en-US
13 |
14 |
15 |
16 | en-US
17 |
18 | 0409:00000409
19 | en-US
20 | en-US
21 | en-US
22 | en-US
23 |
24 |
25 |
26 |
27 |
28 |
29 | 1
30 | Primary
31 | 100
32 |
33 |
34 | true
35 | 2
36 | Primary
37 |
38 |
39 |
40 |
41 | true
42 | NTFS
43 |
44 | 1
45 | 1
46 | 0x27
47 |
48 |
49 | true
50 | NTFS
51 |
52 | C
53 | 2
54 | 2
55 |
56 |
57 | 0
58 | true
59 |
60 |
61 |
62 |
63 |
64 | 0
65 | 2
66 |
67 | false
68 |
69 |
70 |
71 | true
72 | @@User@@
73 |
74 |
75 | false
76 |
77 |
78 |
79 |
80 |
81 |
82 | 1
83 | Primary
84 | 100
85 |
86 |
87 | true
88 | 2
89 | Primary
90 |
91 |
92 |
93 |
94 | true
95 | NTFS
96 |
97 | 1
98 | 1
99 | 0x27
100 |
101 |
102 | true
103 | NTFS
104 |
105 | C
106 | 2
107 | 2
108 |
109 |
110 | 0
111 | true
112 |
113 |
114 |
115 |
116 |
117 | 0
118 | 2
119 |
120 | false
121 |
122 |
123 |
124 | true
125 | @@User@@
126 |
127 |
128 | false
129 |
130 |
131 |
132 |
133 | false
134 |
135 |
136 |
137 |
138 | false
139 |
140 |
141 |
142 |
143 | 1
144 |
145 |
146 |
147 |
148 | 1
149 |
150 |
151 |
152 |
153 | 0409:00000409
154 | en-US
155 | en-US
156 | en-US
157 | en-US
158 |
159 |
160 | 0409:00000409
161 | en-US
162 | en-US
163 | en-US
164 | en-US
165 |
166 |
167 | true
168 |
169 |
170 | true
171 |
172 |
173 | 0
174 |
175 |
176 | 0
177 |
178 |
179 | @@hostname@@
180 | GCRJD-8NW9H-F2CDX-CCM8D-9D6T9
181 |
182 |
183 | @@hostname@@
184 | GCRJD-8NW9H-F2CDX-CCM8D-9D6T9
185 |
186 |
187 |
188 |
189 |
190 | False
191 |
192 | @@Net1_MAC@@
193 |
194 | @@Net1_IP@@
195 |
196 |
197 |
198 | 0
199 | 0.0.0.0/0
200 | @@Net1_GW@@
201 |
202 |
203 |
204 |
205 |
206 |
207 |
208 |
209 |
210 | False
211 |
212 | @@Net1_MAC@@
213 |
214 | @@Net1_IP@@
215 |
216 |
217 |
218 | 0
219 | 0.0.0.0/0
220 | @@Net1_GW@@
221 |
222 |
223 |
224 |
225 |
226 |
227 |
228 |
229 |
230 | @@Net1_DNS@@
231 |
232 | @@Net1_MAC@@
233 |
234 |
235 |
236 |
237 |
238 |
239 |
240 | @@Net1_DNS@@
241 |
242 | @@Net1_MAC@@
243 |
244 |
245 |
246 |
247 |
248 |
249 |
250 |
251 | @@Pass@@
252 | true
253 |
254 | true
255 | 1
256 | @@User@@
257 |
258 |
259 | true
260 | true
261 | true
262 | true
263 | Work
264 | 3
265 | true
266 | true
267 |
268 |
269 |
270 |
271 |
272 | @@Pass@@
273 | true
274 |
275 |
276 | @@User@@
277 | Administrators
278 | @@User@@
279 |
280 |
281 |
282 |
283 | @@User@@
284 | false
285 |
286 |
287 | false
288 | 1
289 | Disable Auto Updates
290 | reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
291 |
292 |
293 | Control Panel View
294 | 2
295 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
296 | true
297 |
298 |
299 | 3
300 | Control Panel Icon Size
301 | false
302 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
303 |
304 |
305 | 4
306 | true
307 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
308 | Change network type to Private
309 |
310 |
311 | 5
312 | true
313 | cmd.exe /c "netsh advfirewall set allprofiles state off"
314 | Disable Windows Firewall
315 |
316 |
317 | 6
318 | true
319 | powershell -Command "Set-WsManQuickConfig -Force"
320 | Enable WsMan
321 |
322 |
323 | 7
324 | true
325 | powershell -Command "Enable-PSRemoting -Force"
326 | Enable PowerShell Remoting
327 |
328 |
329 | W. Europe Standard Time
330 |
331 | 2
332 |
333 |
334 |
335 |
336 |
337 | @@Pass@@
338 | true
339 |
340 | true
341 | 1
342 | @@User@@
343 |
344 |
345 | true
346 | true
347 | true
348 | true
349 | Work
350 | 3
351 | true
352 | true
353 |
354 |
355 |
356 |
357 |
358 | @@Pass@@
359 | true
360 |
361 |
362 | @@User@@
363 | Administrators
364 | @@User@@
365 |
366 |
367 |
368 |
369 | @@User@@
370 | false
371 |
372 |
373 | false
374 | 1
375 | Disable Auto Updates
376 | reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update" /v AUOptions /t REG_DWORD /d 1 /f
377 |
378 |
379 | Control Panel View
380 | 2
381 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v StartupPage /t REG_DWORD /d 1 /f
382 | true
383 |
384 |
385 | 3
386 | Control Panel Icon Size
387 | false
388 | reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel" /v AllItemsIconView /t REG_DWORD /d 0 /f
389 |
390 |
391 | 4
392 | true
393 | powershell -Command "$NLMType = [Type]::GetTypeFromCLSID('DCB00C01-570F-4A9B-8D69-199FDBA5723B');$INetworkListManager = [Activator]::CreateInstance($NLMType);$INetworks = $INetworkListManager.GetNetworks(1);foreach ($INetwork in $INetworks) { $INetwork.SetCategory(0x01) }"
394 | Change network type to Private
395 |
396 |
397 | 5
398 | true
399 | cmd.exe /c "netsh advfirewall set allprofiles state off"
400 | Disable Windows Firewall
401 |
402 |
403 | 6
404 | true
405 | powershell -Command "Set-WsManQuickConfig -Force"
406 | Enable WsMan
407 |
408 |
409 | 7
410 | true
411 | powershell -Command "Enable-PSRemoting -Force"
412 | Enable PowerShell Remoting
413 |
414 |
415 | W. Europe Standard Time
416 |
417 | 2
418 |
419 |
420 |
421 | true
422 |
423 |
424 | true
425 |
426 |
427 |
--------------------------------------------------------------------------------