Questions tagged [aws-security-group]

Amazon EC2 Security Groups

Amazon EC2 Security Groups for EC2. A security group acts as a virtual firewall that controls the traffic for one or more instances. When you launch an instance, you associate one or more security groups with the instance.

See Amazon EC2 Security Groups

820 questions
1
vote
1 answer

Using SQS as EventSource for Lambda in private VPC - do I need SQS VPC Endpoints?

I've been trying to read up on this, but the info I'm getting is either conflicting or I just don't understand well enough to see why there's no conflict. I'm using CDK to set up a lambda in a vpc with an SQS queue as an event source. The SQS queue…
1
vote
1 answer

Lambda can't access HTTP endpoint in the same security group

I'm trying to figure out the following: I have an API service deployed in the default VPC, and I have a ELB configured to access the service. The ELB is attached to a security group sg-XXXXXXXX1 to restrict inbound traffic (open to all for…
1
vote
2 answers

How do I add security group for google data studio to access my amayon RDS?

So I have my database and I don't want it to be publicly accessed. I want to be able to access it through Google Data Studio. Which type of connection should I allow for that? I want to use EC2 security groups interface, not SSL.
1
vote
1 answer

Unable to connect to server local PgAdmin4 to RDS Server VPC

I am unable to connect to the RDS from local postgres pgAdmin4. I have my RDS publicly accessible. I have also configured inbound security group rule from my Ip and any Ips. I have also turned off Windows Defender firewall. Hostname is all correct…
Ziv
  • 95
  • 7
1
vote
1 answer

AWS EC2 can't access my ec2 public domain, tried many web solutions none worked

I don't this is a very common question, I'm only asking it because I've already started some ec2 instances using the method I'll explain bellow and I succed, maybe EC2 changed something the right away to connect it by HTTP using public dns. Here are…
1
vote
1 answer

Allow AWS lambda function to access SAAS from inside

I have a full AWS HTTPS web service, with all needed components i.e. a VPC containing: private ec2 instances autoscaling groups a load balancer (with a public domain xxxxx.eu-west-1.elb.amazonaws.com , and even an official public domain xxxxx.com…
1
vote
2 answers

How to automate modify security groups inbound rules in aws ec2 using java sdk?

I am trying to find the documentation to update aws ec2 security groups using aws java sdk since 2 days, I am able to find the documentation for creating and deleting the security groups using aws java sdk, but not able to find the same for…
1
vote
2 answers

AWS Network Load Balancer Cannot attach Security Groups

I am having a bit of trouble fixing this network issue in AWS. Before going into more details, I will start off by this: I have a Network Load Balancer with a listener 8243 There's a target group attached to that 8243 listener, where the target…
Jananath Banuka
  • 2,951
  • 8
  • 57
  • 105
1
vote
2 answers

Add a list of IP as Source IP in Security Group

I have a list of IP addresses. I want to allow tcp/22 traffic from them and block any other IP address. The list is long and contains about 50-60 IP addresses. How can I add this to a Security Group without manually adding them one by…
rooni
  • 1,036
  • 3
  • 17
  • 33
1
vote
2 answers

What does it mean to "link" AWS security groups?

In my studies of AWS, multiple times I have seen references to "linking" security groups. I do not understand what this means in practice. My current understanding is that when rules are defined in security groups, they are defined in terms of ports…
1
vote
1 answer

Terraform - Automatically create SGs for CloudFront IPs

I am trying to automatically create SGs for CloudFront IPs so I can associate them my ALB. This article has a very good insight on how to achieve it, but unfortunately it didn't work on my environment. This is the code: data "aws_ip_ranges"…
1
vote
1 answer

How do I assign a new security group to an EC2 instance without removing the currently attached security groups using AWS CLI?

The AWS CLI command to attach a security group to running EC2 instance is as below. aws ec2 modify-instance-attribute --instance-id i-12345 --groups sg-12345 sg-67890 But the above command will remove the currently attached security groups and…
Piyush Patil
  • 14,512
  • 6
  • 35
  • 54
1
vote
0 answers

Locals, for each and module security group

Im trying to learn terraform on my own to use it on one of my projects, so sorry if this is a basic misunderstanding, i’m a totally noob here. I would like to create multiple security groups and inside of them, some specific rules for each security…
1
vote
1 answer

AWS RDS can't connect security group

This is question is related to an earlier one I asked, but more specific and hopefully easier to answer. Essentially, I can't connect to my RDS instance. I tried in my SQL editor (datagrips) and also by pinging the server on the console. Comments on…
1
vote
1 answer

Removing security group from ec2 instance using aws cli or python

As there is already a way to remove (not deleting) the security group from an ec2 instance from aws console, i am looking for a way to do it programatically by using python or aws cli. but not able to find any such offering. Please let me know if it…
jayendra bhatt
  • 1,337
  • 2
  • 19
  • 41