From bd82193cc5b59a870b8f9dcd7dd37b8cf71c025a Mon Sep 17 00:00:00 2001 From: Kripa Sreedevi Date: Mon, 4 Oct 2021 10:54:45 +0530 Subject: [PATCH] Modified the remediation logic to check for protocol udp instead of tcp as the remediation is for closing the open udp port for memcache --- .../jobs/aws_ec2_close_port_11211/aws_ec2_close_port_11211.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/remediation_worker/jobs/aws_ec2_close_port_11211/aws_ec2_close_port_11211.py b/remediation_worker/jobs/aws_ec2_close_port_11211/aws_ec2_close_port_11211.py index 8c63dba..89c5578 100644 --- a/remediation_worker/jobs/aws_ec2_close_port_11211/aws_ec2_close_port_11211.py +++ b/remediation_worker/jobs/aws_ec2_close_port_11211/aws_ec2_close_port_11211.py @@ -84,7 +84,7 @@ def remediate(self, client, instance_id): ) for rule in security_group_rules["SecurityGroupRules"]: if ( - rule["IpProtocol"] == "tcp" + rule["IpProtocol"] == "udp" and rule["IsEgress"] is False and rule["FromPort"] <= port and rule["ToPort"] >= port