Questions tagged [subnet]

A part of the IP address identifying the whole local network (high bits as defined by netmask). The remainder of the IP address (host id) identifies devices that are connected to this network. Can also mean the local network itself, if addressed by IP address in a described way.

Read more on wikipedia: https://en.wikipedia.org/wiki/Subnetwork

893 questions
5
votes
1 answer

AWS RDS "Publicly Accessible = No" vs instance in private subnet

I am creating infrastructure for one of my web application on AWS. That app needs Mysql RDS instance. Now I am wondering that whether I should simply create RDS instance in public subnet and just change its settings to Publicly Accessible=No, or I…
5
votes
1 answer

How to determine subnet IPv4 CIDR address in AWS?

How to determine subnet IPv4 CIDR address in AWS. Suppose my VPC CIDR block is 172.31.0.0/16 and I want to create a subnet with 172.31.1.0/16 but it says " *** is not within the range of ****/*. Please explain me how to determine CIDR?
Kamakshya
  • 61
  • 1
  • 5
5
votes
4 answers

Is IP address on the same subnet as the local machine (with IPv6 support)

Does anyone have some code that will determine if an IP address (IPv4 or IPv6) is on the same subnet as the machine running the application? I've seen numerous examples of code that does this with IPv4 but I can't find any that support…
Spencer Ruport
  • 34,865
  • 12
  • 85
  • 147
5
votes
1 answer

CIDR Block Overlapping in AWS VPC

Can someone please explain Subnet Overlapping with an example ? I'm preparing for AWS CSA and I came across this term. I tried few resources but it's not 100 % clear to me. Thanks a lot in advance.
ANT
  • 87
  • 1
  • 4
5
votes
3 answers

Access AWS RDS from Private Subnet

I created an AWS VPC with public and private subnet. I created an RDS(MySQL) inside private subnet. I want to access the RDS from internet (From my home machine). I have kept the flag Publicly Accessible Yes. Also in the RDS security group, I tried…
Tarun Dave
  • 61
  • 1
  • 1
  • 2
5
votes
2 answers

algorithm to find IPv4 networks in CIDR notation between two IPv4 addresses

I would like to find out all the IPv4 networks in CIDR notation between those two networks: 10.11.3.64-10.11.3.127 10.11.52.0-10.11.52.255 IPv4 networks should have as short subnet-mask as possible. It's fairly easy to convert 10.11.3.127 into…
Martin
  • 957
  • 7
  • 25
  • 38
5
votes
5 answers

What is the most efficient way to match the IP addresses to huge route entries?

Imagining there is a firewall, and the system administrator blocked many subnets, perhaps all subnets of a specific country. For example: 192.168.2.0 / 255.255.255.0 223.201.0.0 / 255.255.0.0 223.202.0.0 / 255.254.0.0 223.208.0.0 /…
比尔盖子
  • 2,693
  • 5
  • 37
  • 53
5
votes
2 answers

How do I manually transform an IPv4 address into an IPv6 address?

I would like to know if there is any manual method in transforming an IPv4 address to an IPv6 address without the use of an conversion calculator or tool. For example: I have an IPv4 address and it is given as: 129.130.100.11 and when it is…
blobs
  • 88
  • 1
  • 8
5
votes
1 answer

Commons-net 3.3 SubnetUtils does not allow 0.0.0.0/0

I want to make an all-inclusive ip range in commons-net, but when I try SubnetUtils subnetUtils = new SubnetUtils("0.0.0.0", "0.0.0.0"); or the same: SubnetUtils subnetUtils = new SubnetUtils("0.0.0.0/0"); I get an…
kavai77
  • 6,282
  • 7
  • 33
  • 48
5
votes
1 answer

Multiple Ethernet Interfaces - How to create a separate network and access from C code

I have a Linux device (actually a BeagleBoard for the prototype) with two Ethernet adapters. What I want is this: Primary ethernet interface (eth0) connects to a client's network (may be DHCP or assigned a static IP). Second ethernet interface…
Jeremy
  • 1,083
  • 3
  • 13
  • 25
5
votes
3 answers

Obtaining SubnetMask in C

I wanted to get the IP address and the subnet mask. Now the IP part is done, however I couldn't find any socket function that would return a structure with the subnet mask in it. Does a socket function exist, that returns it in a structure? Thanks!
StephenOSx
  • 53
  • 1
  • 3
4
votes
2 answers

Optimal IP subnet matching

The following code appears to be the hottest spot in my program. JAVA_OPTS=-Xprof output: Compiled + native Method 5.7% 173 + 0 scala.collection.IndexedSeqOptimized$class.slice 5.1% 156 + 0 …
Basilevs
  • 22,440
  • 15
  • 57
  • 102
4
votes
1 answer

How to create NACL for private subnets?

I have two public subnets with CIDR - 10.100.0.0/24 and 10.100.3.0/24. I am trying to add NACL for private subnets but I am unable to access the private subnet with the below configuration. Can anyone help me to resolve this issue? I have created…
HMT
  • 2,093
  • 1
  • 19
  • 51
4
votes
5 answers

How to get gateway address when subnetting?

I have to subnet a network from a single class C IP address. I have figured out the subnet mask and the broadcast address (I'm using subnet mask /28) but don't understand how to get the gateway address. Can anyone help me?
toby
  • 51
  • 1
  • 2
  • 3
4
votes
2 answers

Restricting access via IP-ranges (PHP)

Basically, I aim to allow my user to specify an ip range for access to a test. So lets say these values are stored in my database: from: 148.197.34.112 To: 148.197.34.255 Are there any functions of which I can use to convert these ip addresses into…
dapperwaterbuffalo
  • 2,672
  • 5
  • 35
  • 48