Skip to content

Commit

Permalink
Added a new SG rule to allow attackbox to reach the target
Browse files Browse the repository at this point in the history
  • Loading branch information
Frichetten committed Mar 6, 2022
1 parent 15d013d commit ba2d0d5
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions aws/cicdont/target_service.tf
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,15 @@ resource "aws_security_group_rule" "allow_local_http_rule" {
cidr_blocks = ["${aws_instance.target_service.public_ip}/32"]
}

resource "aws_security_group_rule" "allow_attackbox_inbound_rule" {
security_group_id = aws_security_group.allow_http.id
from_port = 0
to_port = 0
protocol = "-1"
type = "ingress"
cidr_blocks = ["${aws_instance.attackbox.public_ip}/32"]
}

data "template_file" "target_user_data" {
template = file("target_service_user_data.sh")
vars = {
Expand Down

0 comments on commit ba2d0d5

Please sign in to comment.