Module ngx_http_realip_module and how to set_real_ip_from

I have a very basic question about Module ngx_http_realip_module. I checked the documentation and I saw this example:

set_real_ip_from  192.168.1.0/24;
set_real_ip_from  192.168.2.1;
set_real_ip_from  2001:0db8::/32;
real_ip_header    X-Forwarded-For;
real_ip_recursive on;

I also understand that these are:

real_ip_header X-Forwarded-For;
real_ip_recursive on;
set_real_ip_from <your VPC IPV4 CIDR here>;
set_real_ip_from <your VPC IPV6 CIDR here>;

My question is this: If my IPV4 that I use to connect to the server is: 123.12.12.123. Where do I get the number(s) /24 after that to make it: 123.12.12.123/24? The same question applies to IPV6.


The 192.168.1.0/24 is the CIDR notation. /24 indicates the number of bits in your network mask. /24 corresponds to the network mask 255.255.255.0. See CIDR Notation article for details.