Thread: Range of IP address specification in pg_hba.conf

Range of IP address specification in pg_hba.conf

From
"Solaimurugan V."
Date:
         could you please tell me how can i specify range of IP
 address in pg_hba.conf file, not by network i.e 192.168.31.0/24, i need
to
 specify ip address range like 192.168.31.101-125 (client from 101 to 125
 can connect to server) is it possible?

 regards,
 solai v







--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.


Re: Range of IP address specification in pg_hba.conf

From
Josh Kupershmidt
Date:
On Mon, Oct 11, 2010 at 3:29 AM, Solaimurugan V. <solaimuruganv@cdac.in> wrote:
>
>         could you please tell me how can i specify range of IP
>  address in pg_hba.conf file, not by network i.e 192.168.31.0/24, i need
> to
>  specify ip address range like 192.168.31.101-125 (client from 101 to 125
>  can connect to server) is it possible?

I think you can convert that IP address range to CIDR format for your
pg_hba.conf file like this:

192.168.31.101/32
192.168.31.102/31
192.168.31.104/29
192.168.31.112/29
192.168.31.120/30
192.168.31.124/31

Josh