1
1
AWSTemplateFormatVersion : 2010-09-09
2
- Description : This template creates a VPC for Kali Linux Purple SOC Lab
2
+ Description : This template creates a VPC with it's subnets for the Kali Linux Purple SOC Lab.
3
3
Metadata :
4
4
' AWS::CloudFormation::Interface ' :
5
5
ParameterGroups :
@@ -12,6 +12,7 @@ Metadata:
12
12
Parameters :
13
13
- PublicSubnetCIDR
14
14
- LANSubnetCIDR
15
+ - SOCSubnetCIDR
15
16
- Label :
16
17
default : SSH
17
18
Parameters :
@@ -32,11 +33,15 @@ Parameters:
32
33
Type : String
33
34
PublicSubnetCIDR :
34
35
Default : 192.168.0.0/24
35
- Description : Please Enter the IP Range of the Private Subnet
36
+ Description : Please Enter the IP Range of the Public Subnet
36
37
Type : String
37
38
LANSubnetCIDR :
38
39
Default : 192.168.1.0/24
39
- Description : Please Enter the IP Range of the Public Subnet
40
+ Description : Please Enter the IP Range of the LAN Subnet
41
+ Type : String
42
+ SOCSubnetCIDR :
43
+ Default : 192.168.253.0/24
44
+ Description : Please Enter the IP Range of the SOC Subnet
40
45
Type : String
41
46
42
47
@@ -50,7 +55,7 @@ Resources:
50
55
InstanceTenancy : default
51
56
Tags :
52
57
- Key : Name
53
- Value : KaliVPC
58
+ Value : Kali VPC | KaliVPC
54
59
55
60
PublicSubnet :
56
61
Type : ' AWS::EC2::Subnet'
@@ -62,7 +67,7 @@ Resources:
62
67
MapPublicIpOnLaunch : true
63
68
Tags :
64
69
- Key : Name
65
- Value : Public
70
+ Value : Kali VPC | Public Subnet
66
71
VpcId : !Ref KaliVPC
67
72
68
73
LANSubnet :
@@ -75,15 +80,28 @@ Resources:
75
80
MapPublicIpOnLaunch : false
76
81
Tags :
77
82
- Key : Name
78
- Value : LAN Subnet
83
+ Value : Kali VPC | LAN Subnet
84
+ VpcId : !Ref KaliVPC
85
+
86
+ SOCSubnet :
87
+ Type : ' AWS::EC2::Subnet'
88
+ Properties :
89
+ AvailabilityZone : !Select
90
+ - 0
91
+ - !GetAZs ' '
92
+ CidrBlock : !Ref SOCSubnetCIDR
93
+ MapPublicIpOnLaunch : false
94
+ Tags :
95
+ - Key : Name
96
+ Value : Kali VPC | SOC Subnet
79
97
VpcId : !Ref KaliVPC
80
98
81
99
IGW :
82
100
Type : ' AWS::EC2::InternetGateway'
83
101
Properties :
84
102
Tags :
85
103
- Key : Name
86
- Value : InternetGateway
104
+ Value : Kali VPC | InternetGateway
87
105
88
106
IGWAttacment :
89
107
Type : ' AWS::EC2::VPCGatewayAttachment'
@@ -96,7 +114,7 @@ Resources:
96
114
Properties :
97
115
Tags :
98
116
- Key : Name
99
- Value : PublicRouteTable
117
+ Value : Kali VPC | PublicRouteTable
100
118
VpcId : !Ref KaliVPC
101
119
102
120
PublicRoute :
@@ -112,10 +130,11 @@ Resources:
112
130
RouteTableId : !Ref PublicRouteTable
113
131
SubnetId : !Ref PublicSubnet
114
132
115
- SSHSecurityGroup :
133
+
134
+ OpenSecurityGroup :
116
135
Type : ' AWS::EC2::SecurityGroup'
117
136
Properties :
118
- GroupDescription : SSH Security Group
137
+ GroupDescription : Open Security Group
119
138
SecurityGroupIngress :
120
139
- IpProtocol : tcp
121
140
FromPort : 80
@@ -169,7 +188,7 @@ Resources:
169
188
FromPort : 465
170
189
ToPort : 465
171
190
CidrIp : !Ref SSHLocation
172
- - IpProtocol : tcp
191
+ - IpProtocol : tcp
173
192
FromPort : 587
174
193
ToPort : 587
175
194
CidrIp : !Ref SSHLocation
@@ -189,25 +208,89 @@ Resources:
189
208
FromPort : 8220
190
209
ToPort : 8220
191
210
CidrIp : !Ref SSHLocation
192
-
193
211
Tags :
194
212
- Key : Name
195
- Value : SSH Security Group
213
+ Value : Open Security Group
196
214
VpcId : !Ref KaliVPC
197
215
198
216
LANNI :
199
217
Type : ' AWS::EC2::NetworkInterface'
200
218
Properties :
201
- Description : Network Interface for LAN
219
+ Description : Bizantium Network Interface for LAN
202
220
SourceDestCheck : false
203
221
SubnetId : !Ref LANSubnet
204
222
GroupSet :
205
- - !Ref SSHSecurityGroup
223
+ - !Ref OpenSecurityGroup
206
224
PrivateIpAddress : 192.168.1.10
207
225
Tags :
208
226
- Key : Name
209
- Value : Byzantium | LAN Subnet
210
-
227
+ Value : Kali SOC | Bizantium LAN Network Interface
228
+
229
+ SOCNI :
230
+ Type : ' AWS::EC2::NetworkInterface'
231
+ Properties :
232
+ Description : Bizantium Network Interface for SOC
233
+ SourceDestCheck : false
234
+ SubnetId : !Ref SOCSubnet
235
+ GroupSet :
236
+ - !Ref OpenSecurityGroup
237
+ PrivateIpAddress : 192.168.253.101
238
+ Tags :
239
+ - Key : Name
240
+ Value : Kali SOC | Bizantium SOC Network Interface
241
+
242
+ HelioNI :
243
+ Type : ' AWS::EC2::NetworkInterface'
244
+ Properties :
245
+ Description : Heliotrope Network Interface for LAN
246
+ SourceDestCheck : false
247
+ SubnetId : !Ref LANSubnet
248
+ GroupSet :
249
+ - !Ref OpenSecurityGroup
250
+ PrivateIpAddress : 192.168.1.20
251
+ Tags :
252
+ - Key : Name
253
+ Value : Kali SOC | Heliotrope LAN Network Interface
254
+
255
+ PurpleNI :
256
+ Type : ' AWS::EC2::NetworkInterface'
257
+ Properties :
258
+ Description : Kali-Purple Network Interface for SOC
259
+ SourceDestCheck : false
260
+ SubnetId : !Ref SOCSubnet
261
+ GroupSet :
262
+ - !Ref OpenSecurityGroup
263
+ PrivateIpAddress : 192.168.253.105
264
+ Tags :
265
+ - Key : Name
266
+ Value : Kali SOC | Kali-Purple SOC Network Interface
267
+
268
+ VioletNI :
269
+ Type : ' AWS::EC2::NetworkInterface'
270
+ Properties :
271
+ Description : Kali-Violet Network Interface for SOC
272
+ SourceDestCheck : false
273
+ SubnetId : !Ref SOCSubnet
274
+ GroupSet :
275
+ - !Ref OpenSecurityGroup
276
+ PrivateIpAddress : 192.168.253.107
277
+ Tags :
278
+ - Key : Name
279
+ Value : Kali SOC | Kali-Violet SOC Network Interface
280
+
281
+ EminenceNI :
282
+ Type : ' AWS::EC2::NetworkInterface'
283
+ Properties :
284
+ Description : Eminence Network Interface for SOC
285
+ SourceDestCheck : false
286
+ SubnetId : !Ref SOCSubnet
287
+ GroupSet :
288
+ - !Ref OpenSecurityGroup
289
+ PrivateIpAddress : 192.168.253.103
290
+ Tags :
291
+ - Key : Name
292
+ Value : Kali SOC | Eminence SOC Network Interface
293
+
211
294
Outputs :
212
295
KaliVPC :
213
296
Description : KaliVPC ID
@@ -224,15 +307,44 @@ Outputs:
224
307
Export :
225
308
Name : !Sub '${AWS::StackName}-LANSubnet'
226
309
Value : !Ref LANSubnet
310
+ SOCSubnet :
311
+ Description : Public ID
312
+ Export :
313
+ Name : !Sub '${AWS::StackName}-SOCSubnet'
314
+ Value : !Ref SOCSubnet
227
315
LANNI :
228
316
Description : Network Interface for LAN
229
317
Export :
230
318
Name : !Sub '${AWS::StackName}-LANNI'
231
319
Value : !Ref LANNI
232
-
233
- SSHSecurityGroup :
234
- Description : SSHSecurityGroup ID
320
+ SOCNI :
321
+ Description : Network Interface for SOC
322
+ Export :
323
+ Name : !Sub '${AWS::StackName}-SOCNI'
324
+ Value : !Ref SOCNI
325
+ HelioNI :
326
+ Description : Network Interface for Heliotrope
327
+ Export :
328
+ Name : !Sub '${AWS::StackName}-HelioNI'
329
+ Value : !Ref HelioNI
330
+ PurpleNI :
331
+ Description : Network Interface for Kali-Purple
332
+ Export :
333
+ Name : !Sub '${AWS::StackName}-PurpleNI'
334
+ Value : !Ref PurpleNI
335
+ VioletNI :
336
+ Description : Network Interface for Kali-Violet
337
+ Export :
338
+ Name : !Sub '${AWS::StackName}-VioletNI'
339
+ Value : !Ref VioletNI
340
+ EminenceNI :
341
+ Description : Network Interface for Kali-Eminence
342
+ Export :
343
+ Name : !Sub '${AWS::StackName}-EminenceNI'
344
+ Value : !Ref EminenceNI
345
+ OpenSecurityGroup :
346
+ Description : OpenSecurityGroup ID
235
347
Export :
236
- Name : !Sub '${AWS::StackName}-SSHSecurityGroup '
237
- Value : !Ref SSHSecurityGroup
348
+ Name : !Sub '${AWS::StackName}-OpenSecurityGroup '
349
+ Value : !Ref OpenSecurityGroup
238
350
0 commit comments